remove unused BOARD_USES_COMBINED_RECOVERY

Change-Id: I79520c510488d63d469b0d1a3a099420f7de1fe6

Conflicts:
	core/Makefile
ota: Fix inclusion of the backup script

Conflicts:
	core/Makefile
create a target for utilities
Fix up the autoinclusion rules for the utilities and recoveryimage target.
Include the primary bootloader and ramdisk in the BOOT/

This will copy over the primary bootloader (if it exists and defined)
over to the zip_root/BOOT.

This is required by encore as we need to make sure we have the correct
primary bootloader to go with the kernel.

Change-Id: I3fef417011b9c7a63109d10fc8e6794e58f73c31
Require signapk.jar for Flakeflash images

Build signapk.jar which is required to sign the recovery flakeflash image.

Change-Id: I6db422199c8afd3a3f43919980d0893f8d3efc6e
Colors: add more colors to final build steps

also fix releasetool echo and visible recovery echos

Change-Id: Icf5d88468572f935610c544bf1d5d356ec9870d3

Conflicts:
	core/Makefile
new variable TARGET_RECOVERY_FSTAB

Currently the source file recovery.fstab has to be located
in $(TARGET_DEVICE_DIR)/recovery.fstab).

To allow multiple similar CM products to share one recovery.fstab
file this patch introduces the variable TARGET_RECOVERY_FSTAB.

Change-Id: I51961f5a1665023001c9857e13008a2ca44529ee

Conflicts:
	core/Makefile
add unpackbootimg to otatools

Change-Id: I4e294c05eacc8bef8273247bcf1bf382291a3d31
Make the recovery ramdisk target depend on $(MKBOOTIMG) $(INTERNAL_BOOTIMAGE_FILES) rather than $(INSTALLED_BOOTIMAGE_TARGET). This fixes the circular dependency for when the kernel depends on the recovery ramdisk, which depends on the boot image, which depends on the kernel.

Change-Id: I658bedc329f2ea0170ac0012f80ca7d779b1c242
 build: Pass OTAPACKAGE location to squisher

Pass the OTAPACKAGE location so we don't have to guess what
the package name will be. This fixes an issue when
BUILD_NUMBER is defined in an environment with automated
builds.

Change-Id: Iab18b541de37c99d237aabc3cb7b2e9ab076617b

by bekriebel (Credit CM)
 build: Don't build the recovery-from-boot patch on CM

* We don't use this, and I am running into a weird bug where imgdiff is
   hanging on a specific target. Just disable it for now.

Change-Id: I25ee666136e25994528eaa32b6f787626cd288ed

by steve kondik (Credit CM)
Fix building when OUT_DIR is out of ANDROID_BUILD_TOP

This broke in http://review.cyanogenmod.com/#/c/23686/ / http://review.cyanogenmod.com/#/c/23687/

Change-Id: I9dc77a1fb465a30c833262ba3b1de3d2f0f968f0

Conflicts:
	core/Makefile
envsetup: set OUT_DIR to an absolute path always

OUT_DIR was set to $(TOPDIR)out previously,
but $(TOPDIR) was null, so it was a relative path.
This broke releasetools, inline kernel building, etc
since they require absolute paths.
Fix it so that it is set to $(shell readlink -f .)/out
if $(TOPDIR) is null.

Also remove hacks which checked if (OUT_DIR) was out
and changed it to $(ANDROID_BUILD_TOP)/out to workaround
the aforementioned problem.

Change-Id: I459a3b1325a1bbea0565cd73f6acf160d4ed9b39

Conflicts:
	core/envsetup.mk
core/Makefile: avoid exceeding MAX_ARG_STRLEN

The current method of generating the apkcerts file can fail with
a "make: execvp: /bin/bash: Argument list too long" when the path
to the toplevel directory is long enough.

In my case, the MAX_ARG_STRLEN of 131072 was exceeded with a toplevel
directory length of 52 (with 427 apkcerts).

This reduces the length of the command-line string generated by not
repeating the output path for each entry (it cd's there first).

Change-Id: I9739f9aefdf5e0febed66517c7b418a4041f49f6

Conflicts:
	core/Makefile
build: Use newline at the end of echo to apkcerts file

Revert "core/Makefile: avoid exceeding MAX_ARG_STRLEN"
This reverts commit 2eb4ca0fefd32a8eb3280139f3a91d5675c2c9f2.

If a newline is not used, the echo commands are strung
together in one large command. In environments with long
pathnames, this can cause the error:
  "make: execvp: /bin/bash: Argument list too long"

This splits the echo commands up into individual commands
to avoid the argument limit.

Change-Id: Id2e5033ad51a9746e2b6cd88f9d53d5b7c93bc1b
build-with-colors: moar colors

- rename CL_PFX and CL_INS to better match the
  colors they show.
- add more colors.

Output of:
- most host stuff is yellow
- most target stuff is green
- installing/copying files is cyan
- import/export includes and notice files is cyan
- bootimage/recoveryimage is cyan
- and some more colors in many places ;)

Change-Id: I5532afa4ba608e0a7c408516dc9f912f9ca389f7

Conflicts:
	core/Makefile
	core/tasks/apicheck.mk
unpackbootimg: add a target specifically for unpackbootimg.
for some reason, and I am guessing this is a bug in the Android build, I can no longer run the following:
make -j32 out/host/darwin-x86/bin/unpackbootimg

It works if the build has been built, but not if it is clean. Somewhere within the bowels of AOSP
something broken in 4.1.2.

Change-Id: I4f8c434f3fce9ddaee4f54febba02efac07a31a3
fix sdk target with absolute OUT_DIR

Add / to atree's search path.

since I459a3b13 OUT_DIR is absolute. atree uses these variables and
due to "-I ." tries to resolve these paths as relative paths.

Change-Id: Ic9fbc84acdd9f438dfc813f6496e2c5e0d761976
build: don't clear recovery ramdisk

Clearing recovery ramdisk removes all files place there by the
device tree and all busybox symlinks placed there by recovery

Change-Id: I19e6164856a01a83a6e2c50ef96742edcb9f570f