History log of /build/core/clear_vars.mk
Revision Date Author Comments
2408479cf9cf9cfe87e464e9b5d2f36143818d37 25-Sep-2013 Ying Wang <wangying@google.com> Allow module to specify LOCAL_INSTALLED_MODULE_STEM

With this change, you can install a shared library with module name foo
as bar.so to the system.img with:
LOCAL_INSTALLED_MODULE_STEM := bar.so
Note that we in general still disallow a static/shared library to
specify LOCAL_MODULE_STEM or LOCAL_BUILT_MODULE_STEM, because the build
system uses LOCAL_MODULE to compute build time dependencies, such as
export_includes, the -l linker flag etc.
Also, if you use LOCAL_INSTALLED_MODULE_STEM to change the installed
file name and if any other module links against this library, you may
run into runtime error: the library name baked in to the binary is not
the same as file name in the system image.

Change-Id: I55b571c8139c3bda07a4a0e50cea0f20d8d6c168
7311a344bed507062e781ba70331d85652c217d8 22-Aug-2013 Ying Wang <wangying@google.com> Make it easier to enable obfuscation and optimization.

With this change, use:
* LOCAL_PROGUARD_ENABLED := obfuscation # to enable obfuscation
* LOCAL_PROGUARD_ENABLED := optimization # to enable optimization
* LOCAL_PROGUARD_ENABLED := obfuscation optimization # to enable both

Now the meaning of the LOCAL_PROGUARD_ENABLED options:
* full:
Use the build system's default configurations:
with shrink but no obfuscation or optimization,
global proguard flags in build/core/proguard.flags
are applied.
* custom:
The same as "full" except no aapt-generated resource-related
proguard flags.
* nosystem:
Don't use any build system's default configurations; but
aapt-generated proguard flags are still applied. You are
responsible for any other flags.
* disabled:
Disable proguard.
* obfuscation:
The same as "full" but with obfuscation enabled.
* optimization:
The same as "full" but with optimization enabled.
* no value (the default):
The build system chooses the proper value: "full" if it's an
app; "disabled" if it's a library.

You can use more than 1 of them in a meaningful combination,
for example:
LOCAL_PROGUARD_ENABLED := obfuscation optimization

Bug: 10307372
Change-Id: Id248caca3048e99547f16559fae74f4afe85c354
285045bd83548196aa3695423c6cd500ebe6d6c1 13-Aug-2013 Ying Wang <wangying@google.com> Support for LOCAL_HAL_STATIC_LIBRARIES

Now you can have a board config variable BOARD_HAL_STATIC_LIBRARIES,
which is a list of board-specific HAL static library names with pattern
"lib<library_name>.<board_specific_suffix>". LOCAL_HAL_STATIC_LIBRARIES
is a list of "lib<library_name>" and any matched
BOARD_HAL_STATIC_LIBRARIES will be added to the LOCAL_STATIC_LIBRARIES;
if no match is found, lib<library_name>.default will be used.

Bug: 10262105
Change-Id: Ic89d8d417d1dd65a227e4187a157fd3b77c4af34
6e485b545adc2476fed23eedaec8f121fad191b2 25-Jul-2013 Ulas Kirazci <ulas@google.com> Allow proto builds to pass in java proto params.

Change-Id: I65fe0cd96f818f59267da6159e6bd2ad28f07a11
24c7289d242254545785c7cab237fc369b9072f9 25-Jul-2013 Ulas Kirazci <ulas@google.com> Revert "Allow proto builds to pass in java proto params."

This reverts commit 28b46fc16c026365378909f1cc88fad0d3b2395c.

Change-Id: Iaca9fa749c6f460911cc46e08e6b3ae2555b8bcc
fc2bad5c36c72f8c2f0bfb869e642b85ccd1b2a1 25-Jul-2013 Ben Murdoch <benm@google.com> Revert "Allow proto builds to pass in java proto params."

This reverts commit 28b46fc16c026365378909f1cc88fad0d3b2395c.

Speculative fix for master builds. I cannot repro the break the bots
are seeing locally, but it seems related to building protobufs and this
CL was in the first broken build.
28b46fc16c026365378909f1cc88fad0d3b2395c 24-Jul-2013 Ulas Kirazci <ulas@google.com> Allow proto builds to pass in java proto params.

Also source files which have dependencies need to be bundled together
(at least the way the build system is set up now). Move
--proto_path=$(TOP) to the end so that it does not take precedence
over user-supplied --proto_path flags.

Change-Id: Ia532647fe8811d39230a23ba3671685b0388cbe0
ae859f9b64fd1740471e94f3417f63f4082a2e02 18-Jul-2013 Jeff Brown <jeffbrown@google.com> Split framework jar.

Change-Id: I38c68ac169a4ea10e4640b5d8e24298a6caaf441
5338fbfaca6b21ab3178469241641e23eac79d9d 09-May-2013 Ying Wang <wangying@google.com> Install to TARGET_OUT_APPS_PRIVILEGED if LOCAL_PRIVILEGED_MODULE is true

Change-Id: I268b8652f18034aa3fdd3126ebf6196f78c4bbb2
3e55609134381cadfc3b69657a5598dc3d8f2e35 11-Apr-2013 Ying Wang <wangying@google.com> Support to dist unbundled files for bundled build

Usage:
LOCAL_DIST_BUNDLED_BINARIES := true
The dist files will include the jni shared libraries and the apk with
jni libraries stripped.

Bug: 8181626
Change-Id: I4a047d786ad35b948b4ad7a51adf37321dbe395c
bde274ef83b9e22365205a7cd320e13bc53ae625 28-Mar-2013 Ulas Kirazci <ulas@google.com> Add a "nano" option to LOCAL_PROTOC_OPTIMIZE_TYPE.

Change-Id: I7429015b3c5f7f38b7be01eb2d4927f7a9999c80
76e3a3906116dcd57bfdffade0f27631ab0001aa 28-Mar-2013 Ulas Kirazci <ulas@google.com> Add a "nano" option to LOCAL_PROTOC_OPTIMIZE_TYPE.

Change-Id: I7429015b3c5f7f38b7be01eb2d4927f7a9999c80
a1fece009f2e93250b2d3bc8ee4a296d100da6dc 12-Mar-2013 Dianne Hackborn <hackbod@google.com> Add LOCAL_APK_LIBRARIES argument.

This allows you to build apks that link against other
apks using the framework's new shared library apk feature.

Also if you are using LOCAL_APK_LIBRARIES, then LOCAL_DEX_PREOPT
will not be allowed. This is because using preopt means the
apk is stripped of its dex file, so the pre-installed apk can't
be redexed if its associated library changes. (Even if the build
system didn't strip the dex, Dalvik still has issues because it
assumes a pre-odex file is always valid.)

Change-Id: I952c0d24f8975f75aff67f78b5faeec91144c3e7
9fdf671d7f8fb96c1a8d3b41aaf4478e7274e45f 09-Feb-2013 Dirk Dougherty <ddougherty@google.com> Add LOCAL_ADDITIONAL_HTML_DIR to clear_vars for devsite docs builds.

Change-Id: Ib75e776d0220a86a08ddd5d7e09edd069af05da1
985375222f4817836d0c87248647f4b9ca27f7f2 07-Feb-2013 Stephen Hines <srhines@google.com> Copy RS compatibility libraries to /system/lib/ for bundled builds.

Bug: 8138884
Change-Id: I74fb0c5835974af3c6e34fcd2d9ebfc2e7b08b4d
3b0fa1083e8c24bafe50af6e4386a83edddc4f26 07-Feb-2013 Stephen Hines <srhines@google.com> Copy RS compatibility libraries to /system/lib/ for bundled builds.

Bug: 8138884
Change-Id: I74fb0c5835974af3c6e34fcd2d9ebfc2e7b08b4d
e56605ada23ff5a52e3aa8f76d383671859a7c91 06-Feb-2013 Ying Wang <wangying@google.com> Add LOCAL_POST_INSTALL_CMD

With this support, you can piggy-back some symlinks when a module gets
installed.
This is especially helpful if the target of the symlink doesn't exist on
the build machine.

Change-Id: I48af7a90ce67475bc49b72f94a8753b94da98edd
2ce71aa0622d8b2caf7d9dc8274e7a29902b28aa 12-Jan-2013 Ying Wang <wangying@google.com> Add new LOCAL_PROGUARD_ENABLED option "nosystem"

With which we don't include proguard flags defined by the build system.
Bug: 7990659

Change-Id: I78384d2fbaccdd714d646e1b648417195bbd8dde
63d94fa3056066ba7be6754356975af6a1c82981 14-Dec-2012 Ying Wang <wangying@google.com> Build from source or prebuilt

With this change, you can easily switch between building from source
code and prebuilt.
Set LOCAL_PREBUILT_MODULE_FILE to the path of the prebuilt file,
relative to the top of the source tree, in the usual module definition.
The prebuilt will be used unless any of the followings satisfied:
1) ANDROID_BUILD_FROM_SOURCE is "true", which disable prebuilt globally;
2) The module name is in ANDROID_NO_PREBUILT_MODULES;
3) The LOCAL_PATH is prefixed by any of ANDROID_NO_PREBUILT_PATHS.
A developer can set ANDROID_NO_PREBUILT_MODULES or
ANDROID_NO_PREBUILT_PATHS to build only his own module(s) from source,
while build other modules from prebuilts.
You can set ANDROID_BUILD_FROM_SOURCE to true to build everything from
source.
Those variables can be set with shell environmental variable or in your
buildspec.mk.

Sometimes module B is able to be built from source only if module A is
also
built from source, for example, if B is the test apk of A.
In that case, you can use the macro include-if-build-from-source to
include B's Android.mk only if A is built from source too, or
if-build-from-source to conditionally include the definition of module
B,
if their module definitions are in the same Android.mk.

Support host-executable-hook and host-shared-library-hook.

Change-Id: Icab7cf028c87eaba0dd7efc2a7749fd6f32b44e4
e719f28d938d3290ac591769a15b0b5e9e64fabb 29-Nov-2012 Stephen Hines <srhines@google.com> Build rules for Renderscript compatibility library.

Bug: 7419958
Change-Id: I2e0f0bb632e6ff22b2cf1a1b96b28364637995cc
31df068b38729c5bc04a859b9216f539bc22c29e 13-Nov-2012 Ying Wang <wangying@google.com> Additional certificates support for an apk.

Change-Id: I5b35d5728ba9d65f7ece956127270a9ca2ea0efe
8858d2a731f432786b7548b5f63ac93be81eb986 31-Oct-2011 Joe Onorato <joeo@google.com> Add a tool to let you enforce layering between packages in a java module.

And build system support for it too.

Change-Id: I4dd5ed0b9edab6e8884b0d00cfeeae5fa38d967a
0eccce99d7c23b403c6047738d88c616213ad7d7 31-Oct-2011 Joe Onorato <joeo@google.com> Add a tool to let you enforce layering between packages in a java module.

And build system support for it too.

Change-Id: I4dd5ed0b9edab6e8884b0d00cfeeae5fa38d967a
c58b194e786372102512537dfe08ee2a907d9647 12-Oct-2012 Ying Wang <wangying@google.com> Delete the unused LOCAL_POST_PROCESS_COMMAND.

Change-Id: I77785dff6c7b2236880232522d6ed5bc01d5f0ce
3a6f7589e8fcc691ec768b1fdcbf0364ff4596f2 30-Aug-2012 Ying Wang <wangying@google.com> Add LOCAL_DONT_DELETE_JAR_META_INF

To support to not delete META_INF directory from the static Java
libraries.

Change-Id: I720bfa059c43dd457a74a0c60bb6797aa408ecaf
af4800c8a6a9266ceb7269bd2c6b0bb2f0965bea 22-Aug-2012 Ying Wang <wangying@google.com> Support EMMA_INSTRUMENT in both full and unbundled builds.

Bug: 6987838
- With this change, use "EMMA_INSTRUMENT=true" to enable emma in full or
unbundled build.
- You don't need to add "LOCAL_STATIC_JAVA_LIBRARIES += emma" any more for
unbundled apps.
- Now a single var LOCAL_EMMA_INSTRUMENT replaces the previous
LOCAL_NO_EMMA_INSTRUMENT and LOCAL_NO_EMMA_COMPILE.
- By default, if EMMA_INSTRUMENT is true, emma is enabled for only
non-test apps.
- A new global var EMMA_INSTRUMENT_STATIC. It enables EMMA_INSTRUMENT
and builds emma into apk/jar as static library, instead of using emma
as part of shared library core.jar.

Change-Id: I0aa219e83074879ececc159b5b07c39eb07ccc00
7429e21c2e64c1b27787e3768c30207532b56296 15-Aug-2012 Ying Wang <wangying@google.com> Add LOCAL_CONLYFLAGS.

To pass compiler flags
LOCAL_CFLAGS: to both C and C++ files;
LOCAL_CONLYFLAGS: to only C files but not C++ files;
LOCAL_CPPFLAGS: to only C++ file.
LOCAL_CPPFLAGS and LOCAL_CONLYFLAGS can override flags in LOCAL_CFLAGS.

Bug: 6967573
Change-Id: I88d9de0980e451b94bc7ae8c741ea2030eada3e1
54fdb473b656544c75ad06497ecf20a1e8d6b539 14-Aug-2012 Ying Wang <wangying@google.com> Retire LOCAL_NDK_VERSION.

We are now unifying the NDK versions of unbundled native code to always
use the latest NDK.
We don't need the variable LOCAL_NDK_VERSION now.
To build native code with NDK, you need set just LOCAL_SDK_VERSION.

Bug: 6932421
Change-Id: I86f05a264249cda6bae97b4b1616f03700cd9dfa
848020f22a5e305ddf8814942e71d8120509a4ec 14-Aug-2012 Ying Wang <wangying@google.com> Retire LOCAL_NDK_VERSION.

We are now unifying the NDK versions of unbundled native code to always
use the latest NDK.
We don't need the variable LOCAL_NDK_VERSION now.
To build native code with NDK, you need set just LOCAL_SDK_VERSION.

Bug: 6932421
Change-Id: I86f05a264249cda6bae97b4b1616f03700cd9dfa
28437aac999eb04d1698d9a6de87a25b5b772da6 19-Jul-2012 Ying Wang <wangying@google.com> Add LOCAL_SOURCE_FILES_ALL_GENERATED support

Set "LOCAL_SOURCE_FILES_ALL_GENERATED := true" if you want to build a
Java library from only generated source files, without any static
source files. Previously this is not allowed.
This is needed by building api stub libraries, which have only source
files of generated stub files.

Bug: 6814443
Change-Id: Idb2ae9c71a473b796154a03ef07a3403461c4f3c
ae25ec1bcdeb028a2db3103abdf1f22768928f0a 19-Jun-2012 Ying Wang <wangying@google.com> More flexibility to keep/remove R.class in static Java library

- Usually you don't need to set LOCAL_JAR_EXCLUDE_FILES in your
Android.mk, if your static library is directly used by an app.
- If your library will be included by another library that need
reference the R/Manifest class, you can set
LOCAL_JAR_EXCLUDE_FILES := none
to keep the generated classes.
- If your library includes another static library that has Android
resource and you want to remove the generated classes carried by
the static library, set:
LOCAL_JAR_EXCLUDE_FILES := $(ANDROID_RESOURCE_GENERATED_CLASSES)

With the LOCAL_JAR_EXCLUDE_FILES value "none", deprecate the old
long variable LOCAL_KEEP_R_CLASS_IN_STATIC_JAVA_LIBRARY.

Change-Id: I3b9ad5d66f0262f784feb09bc1537c5b01256258
0d570a71630d70a80e838f068d413f1c1a5f55af 19-Jun-2012 Ying Wang <wangying@google.com> lint support.

Bug: 6167394
$make lint-<app-name> # to lint on a single module
$make lintall # to lint on all packages in the source
tree.

Change-Id: I4decc76fb75793ce44809232b0ec72b766fbb434
70dc3e1d3d58647a7c9e4173d7a7fefd28ad81e3 15-Jun-2012 Kito Cheng <kito@0xlab.org> Profiling use aprof, enable by LOCAL_ENABLE_APROF or LOCAL_ENABLE_APROF_JNI

Change-Id: Ia95dc7318e17c0804867b22e239edccc5cbec0af
83dbd2f158169c41c0ec9809ae5c3a9b87ec15cb 26-Apr-2012 Ying Wang <wangying@google.com> Option to keep the generated R class in static Java libarry

Bug: 6404748
Set LOCAL_KEEP_R_CLASS_IN_STATIC_JAVA_LIBRARY to true to do that.

Change-Id: Ieee3cae431e3b1484ec598312729f2c871db2315
6c703628c54275797caf2b524686d3dd2e34385c 12-Apr-2012 Kevin Hester <khester@google.com> Allow packages to place manifest files in any directory

via a new definition LOCAL_ABS_MANIFEST_FILE. The existing
LOCAL_MANIFEST_FILE variable will also be supported.

(Necessary if manifests are being programmatically generated in the
intermediates directory)

Change-Id: I77a8eb1b8040b966b944464281d00c161ff34d3c
6cc9c06854f0e847bdf93d65947c306a83900851 29-Mar-2012 Evgeniy Stepanov <eugenis@google.com> Add support for building with AddressSanitizer.

Change-Id: I559d21bbeb9f869f51e48ce18247ceaf766768b4
dfbe79b803dbbf0fd4c863200e10bedd69510aa3 22-Mar-2012 Ying Wang <wangying@google.com> Don't expose the compiler dependency.

Change-Id: Ia472eaab3e8e883a32e8b441a2480562db278e45
b71e2df30a2a24d5566734b3c41716bee9351fd1 20-Mar-2012 Evgeniy Stepanov <eugenis@google.com> Add LOCAL_CLANG variable to switch C/C++ build environment to Clang.

Change-Id: I8ca1c24f51aa5546ac9618d31566a52e4fdb1436

Conflicts:

core/clear_vars.mk
49932f1edb5570e47d35716fc8e3440b72d9aaa9 13-Mar-2012 Svetoslav Ganov <svetoslavganov@google.com> Adding clean variables for some variables used in CTS.

1. A CTS package can specify the test runner used to launch
its tests from the device. This is useful for preparing
and cleaning the device through some shell commands if
necessary.

bug:5946699

Change-Id: Ib1d6454c4274b1c37323235c9b3a195f3b9d8131
237fa073392127a7ba1cfff1b2010191a5343e1f 13-Dec-2011 Brian Muramatsu <btmura@google.com> Build Support for CTS Native Tests

Bug 4970300

Adds two new variables, CTS_TEST_CASES and CTS_TEST_XMLS, to be read
from CtsTestCaseList.mk. The CTS_TEST_CASES variable can be used to
copy any sort of file to the repository/testcases CTS directory.
The CTS_TEST_XMLS variable can be used to inject test package xmls
from any source rather than relying upon the monolithic and
mostly serial buildCts.py script.

The existing CTS_CORE_CASE_LIST is coded to only support APKs, so
it could not be retrofitted to support native tests. However, the
two new variables can do even more than CTS_CORE_CASE_LIST due to
their generality. In the future, the idea is move away from
CTS_CORE_CASE_LIST and also generate XMLs using separate tools
rather than just buildCts.py.

Change-Id: Ib52722861c37e0f4d511f9041928395bcaba5dea
dbb31be41302aa4426006685e9c652de8074906a 10-Dec-2011 Ying Wang <wangying@google.com> Restrict vendor modules to help AOSP product distribution.

Bug: 5692177

If you set "PRODUCT_RESTRICT_VENDOR_FILES := true" in a product
configuration, this changes restricts that:
- No overlays in the vendor tree.
- No PRODUCT_COPY_FILES coming from the vendor tree.
- Any referenced package with Android.mk in the vendor tree must have
LOCAL_MODULE_OWNER set to a value that's compared against a whitelist
stored in the core build system.

Change-Id: I172b84c7c853e9a04bf9879ea8dec90bd5054230
914f7a2990ef0e02d4632dd77076c6c7bb11e6dd 07-Dec-2011 Stephen Hines <srhines@google.com> Enable -Wall/-Werror with LOCAL_RENDERSCRIPT_FLAGS.

Change-Id: Ia2a058e6711839d89072c2e96f0c60aa4cedda6b
5f074803fbc14d091fb83208b81b3ffa10f54f90 08-Nov-2011 Ying Wang <wangying@google.com> Build system support to export include paths

Bug: 5573756
With this change, we can set LOCAL_EXPORT_C_INCLUDE_DIRS in the module
definition to export include dir paths.
Paths in LOCAL_EXPORT_C_INCLUDE_DIRS should be relative to the top dir
of the source tree.
If a library (shared or static) exports some include paths, any module
using it will import the include paths and add them to the compiler
command line.

Change-Id: I49aabc589d2cf214044d13ccd5532ef68209adf0
c72b1403e43884dc7dc9f749be51a8d890d62e27 31-Oct-2011 Joe Onorato <joeo@google.com> Add a tool to let you enforce layering between packages in a java module.

And build system support for it too.

Change-Id: I4dd5ed0b9edab6e8884b0d00cfeeae5fa38d967a
79e3dec83ee012e94e34ed092cea5b9d60040e9d 24-Oct-2011 Ying Wang <wangying@google.com> new LOCAL_DEX_PREOPT option "nostripping"

Set "LOCAL_DEX_PREOPT := nostripping" to do dex-preopt while not strip
the classes.dex.

Bug: 5396625 5502338
Change-Id: Ie8dea4414ebeefeae89c6433b246faea27baa5e7
43e18e0d7ba8c83335a4e782f0f3be737322f209 13-Sep-2011 Ying Wang <wangying@google.com> Install path support for vendor modules.

Bug: 5284764
Set "LOCAL_PROPRIETARY_MODULE := true" to install module to vendor
partition.

Change-Id: I9acdda6b2ff3142628b9849ea534b3ec288545a0
14169bcea813b2f6c5aa6993b7f154d9c03f5b18 19-Sep-2011 Dianne Hackborn <hackbod@google.com> New LOCAL_SDK_RES_VERSION config var.

This allows an app to target a different SDK level for its resources
than it uses for its Java code. This is useful because it is generally
safe to use various newer symbols like attribute names, as older versions
of the platform will simply ignore them.

Change-Id: Ida19ec9f259c4ea70de846e9a63546e263b1c91e
8f77936dd808ef77e0f1f02b0e0f648dc94b79a8 13-Sep-2011 Ying Wang <wangying@google.com> Install path support for vendor modules.

Bug: 5284764
Set "LOCAL_PROPRIETARY_MODULE := true" to install module to vendor
partition.

Change-Id: I1301acc10664a12e313f3b868d9fd6400ac8b133
a941d137faa59acc7c80e7d263c97d8676859a12 30-Aug-2011 Stephen Hines <srhines@google.com> Provide LOCAL_RENDERSCRIPT_TARGET_API override.

BUG=5206223

This allows us to set the RS API level independent of the other SDK
versions that a developer might choose.

Change-Id: Id8b476abcbbbdaa86e04ba0ea16414cb2fa5bd15
d4136c0fc67d4330194ea4e612117e84be110d8b 24-Aug-2011 Stephen Hines <srhines@google.com> Provide mechanism to override llvm-rs-cc headers.

Change-Id: I87fd496069a9dfde633e2d232e436fa5d7315cc0
e3c3c6d4fecf12e725dbf0f5bb9967787149c457 07-Jun-2011 Doug Kwan <dougkwan@google.com> Allow per module RTTI setting. This fixes a bug in previous check-ins.

Change-Id: I5fcac192a7945720fd7667f7497078d310370bc5
6f937973ff9738d37e3ef9dce551a1877dca98a6 06-Jun-2011 Doug Kwan <dougkwan@google.com> Revert "Clear LOCAL_RTTI_FLAG."

This reverts commit f524df7ce1a5e276607563272fa1838967a4a239.
f524df7ce1a5e276607563272fa1838967a4a239 04-Jun-2011 Doug Kwan <dougkwan@google.com> Clear LOCAL_RTTI_FLAG.

Change-Id: I0f1388e76af1ce0592cd3271a689fbb6c0ea3eba
7d83ef8ff7679239063bb8484f0c1fdcf31abf8b 26-May-2011 Ying Wang <wangying@google.com> Support custom RenderScript compiler

Change-Id: I85e38e84565e04f99dd26217f280274883dc322d
fcdabd4bdbb347399e77d2fd4b1aefd6281d75f8 25-Apr-2011 Ying Wang <wangying@google.com> Add LOCAL_GROUP_STATIC_LIBRARIES

Set LOCAL_GROUP_STATIC_LIBRARIES := true to group the static libraries,
in case we need gcc flags "-Wl,--start-group" and "-Wl,--end-group" to
fix circular references.

Change-Id: I03c4901670112fcdd2bb0fe660b6924e5776fcf8
b375e71d306f2fd356b9b356b636e568c4581fa1 09-Mar-2011 Iliyan Malchev <malchev@google.com> build: remove prelinker build build system

This patch removes support for prelinking from the build system. By now, the
prelinker has outlived its usefulness for several reasons. Firstly, the
speedup that it afforded in the early days of Android is now nullified by the
speed of hardware, as well as by the presence of Zygote. Secondly, the space
savings that come with prelinking (measued at 17MB on a recent honeycomb
stingray build) are no longer important either. Thirdly, prelinking reduces
the effectiveness of Address-Space-Layout Randomization. Finally, since it is
not part of the gcc suite, the prelinker needs to be maintained separately.

The patch deletes apriori, soslim, lsd, isprelinked, and iself from the source
tree. It also removes the prelink map.

LOCAL_PRELINK_MODULE becomes a no-op. Individual Android.mk will get cleaned
separately. Support for prelinking will have to be removed from the recovery
code and from the dynamic loader as well.

Change-Id: I5839c9c25f7772d5183eedfe20ab924f2a7cd411
cce4c973e42a5a2f4256eb2792858b27ea15f375 04-Mar-2011 Ying Wang <wangying@google.com> Support stl variants when LOCAL_NDK_VERSION is set.

LOCAL_NDK_STL_VARIANT can be set to system, stlport_static, stlport_shared
or gnustl_static. It defaults to system.

Change-Id: I2840d30ff732a00bc0ea70eab8a8179aea0abbdf
bd528a82a24e2230ea797ffc7d9a20d4d917747e 16-Feb-2011 Jeff Brown <jeffbrown@google.com> Build system tweaks for Valgrind.

Added LOCAL_NO_CRT to enable building executables that do not link
to the C runtime library.

Removed support for LOCAL_MODULE_SUBDIR since it was broken
and unused. (Was going to use it but ended up using LOCAL_MODULE_PATH
instead.)

Change-Id: Ifed4ffe17003d90370c711ea6606e2b75e841dee
703e7c6d50a5bddf0fb057a1a26618e2f7138c31 05-Feb-2011 Jeff Brown <jeffbrown@google.com> Build system tweaks for Valgrind.

Added LOCAL_NO_CRT to enable building executables that do not link
to the C runtime library.

Removed support for LOCAL_MODULE_SUBDIR since it was broken
and unused. (Was going to use it but ended up using LOCAL_MODULE_PATH
instead.)

Change-Id: I3b6f5ab7e5ae6aaa7119899adccece2b4ab1cbb3
c61d4c91b6b31776665be3fcc7e4733b53e6c6e8 27-Jan-2011 Jean-Baptiste Queru <jbq@google.com> Extra protobuf-related support

Change-Id: I375d32f0bcb695ccb0603743133034941d584163
79ee7bf896cb03c9c05df9aac644fdb055a37898 27-Jan-2011 Jean-Baptiste Queru <jbq@google.com> Protobuf compiler support in the build system
8b07ed87fac07337f82f96613aa4e3f6170b279b 28-Dec-2010 Ying Wang <wangying@google.com> LOCAL_AAPT_INCLUDE_ALL_RESOURCES

Set this flag to include all the resources in the given dirs.
Bug: 3313179

Change-Id: I68c02b24174bebe41a5948810cc2f49cc916e51c
33c0d952fcba713f00c1cafc8213274e642aee4c 05-Nov-2010 Ying Wang <wangying@google.com> Allow module-specific protoc flags.

You can add local protoc flags via LOCAL_PROTOC_FLAGS.

Change-Id: If246a4edafe1edcec6a7f193bde8ce3c83de745b
a5fc87a93713b1976c5bfdd602d1c6bd285e7533 03-Nov-2010 Ying Wang <wangying@google.com> Integrate protocol buffer compiler into the build system.

Bug: 3152546
Change-Id: Ida3ca3d633ce45704dc8e80d044cdbd3ca69aca5
0b9382c792c303a93f5805adf4eba377dac01950 29-Sep-2010 Ying Wang <wangying@google.com> Separate out Proguard flag files to fix dependency.

Bug: 3048005
Change-Id: I3e77ca1082cf7c92a43b249e5c887e3fbdf4ba11
e7874c430895b9a4e631c89f1e7729da9264d167 18-Sep-2010 Ying Wang <wangying@google.com> Integrate dexpreopt into the build system.

Change-Id: Id67f85d0f5c8674f5bc22e431114ca73625811ef
f7912e4ee0ceb014117c66369485f0aa9ea7cf08 11-Sep-2010 Ying Wang <wangying@google.com> Support to build host dex.

Change-Id: I55df5e4051dbeb89a70d6d7b89fb6110f133d9d7
3dae0ee46cf5fcde6eb424f9ab0c69f2d901a671 03-Sep-2010 Ying Wang <wangying@google.com> Fix inherited dependency when instrmentation.

It turns out we should also LOCAL_INSTRUMENTATION_FOR.
To disambiguate LOCAL_INSTRUMENTATION_FOR_PACKAGE_NAME is renamed to LOCAL_MANIFEST_INSTRUMENTATION_FOR.

Bug: 2902591
Change-Id: I6cb893c135736fc4170aa2259105b4c5eea798a1
512802772a2516b817ab463659b62c2e6fa7442c 01-Sep-2010 Ying Wang <wangying@google.com> Now slang supports "-I" options.

Change-Id: I32aef6c913d9d30f9982a593397145f1562aecf9
121a78733a9ff105efabbff3314548f973a9105b 23-Jul-2010 Evan Charlton <evanc@google.com> Packages can specify where to find AndroidManifest.xml

By overriding LOCAL_MANIFEST_FILE, a package can now specify which
AndroidManifest.xml file to use. This also allows for AndroidManifest.xml to
be in a non-standard location, though that's not recommended.

Change-Id: Ib6d1baeef7601e5a93d4ce64d18883d45373fc12
7adbf97d110ebe137579e1078e3846aa4f3c6c2c 07-Jul-2010 Jeffrey Chyan <jeffrey.chyan@garmin.com> Allow explicit warnings for projects

Enabled compiler warnings by default and then modified javac
command to include warnings only if a project's warning flag,
LOCAL_WARNINGS_ENABLE, is set to true.

Change-Id: I5111d16a862f3afaaf1dcba2f2c2b7fc072613f1
1a08100fa9d92c25de32ba4d13fd3958bbcab894 13-Jul-2010 Ying Wang <wangying@google.com> Support to build native libraries with prebuilt NDK

Bug: http://b/issue?id=2811253
Change-Id: Iabd4ab8b3d7236dffe89f1939e1142e882944026
a0ab29b986af30351efc2983faaf93bcbf040303 18-Jun-2010 Jack Palevich <jackpal@google.com> Add LOCAL_JNI_SHARED_LIBRARIES_ABI build variable.

LOCAL_JNI_SHARED_LIBRARIES_ABI allows individual APKs to specify
specify the path where JNI shared libraries are stored in the APK. This
is useful if you want to build an APK that supports a generic version of
an ABI (e.g. armeabi) from a device configuration where
TARGET_CPU_ABI is set to a more specific version of an ABI (e.g.
armeabi-v7a.)

Note that specifying the LOCAL_JNI_SHARED_LIBRARIES_ABI does not
affect how the local JNI shared libraries are built. It just controls
where the local JNI shared libraries are placed within the APK.

Defaults to TARGET_CPU_ABI.

Change-Id: I1cbb293e0c953688945fc147c7fc367421cf860b
18b75566429107b147368f8e392f6b25f975f5ee 14-May-2010 Guang Zhu <guangzhu@google.com> Squashed commit of the following (DO NOT MERGE):

commit 7401608f3b9b52b3348e32ec9fefe7583d6c2fa4
Author: Guang Zhu <guangzhu@google.com>
Date: Fri Apr 23 11:54:37 2010 -0700

collect emm meta files for emma instrumented build

when doing 'make dist', with EMMA_INSTRUMENT on the coverage.em files
generated for each module will be collected into one emma_meta.zip file

Change-Id: I382c39a97005e6cae5c79ad7eaef1c8857f658af

commit 8376d70938f6507d54b66fe5832a637aa883974e
Author: Guang Zhu <guangzhu@google.com>
Date: Wed Mar 10 15:48:03 2010 -0800

enhancement for building app with emma code coverage

* global filter to avoid applying instrumentation on emma classes
* remove local variable information at dex step instead of compile time

Change-Id: If04c27bc717f34816077a98ead9ceb0dbcbb0d2f

Change-Id: I971bd0f291bede2568b21347247d37a7d035c661
4f9c20529e6c38aa29ed5c1f3f39e9de5980d6e6 18-May-2010 Joe Onorato <joeo@android.com> fix typo

Change-Id: Ic00f82ea7bbe570ef30f52b353ba147664d755d7
77dc0a58e27fe7c3fcdb67bbee71010c59dd4344 18-May-2010 Joe Onorato <joeo@android.com> Add a rule that builds an eclipse project file for an app.

Type make ECLIPSE-<app1>-<app2>... with the apps as listed in LOCAL_PACKAGE_NAME.

Change-Id: Ieb96dfc9dfc13bdf1b3be53572092fc7bc695869
155afe393faa0aae47d517fa687a7e4ab3cae91b 11-Mar-2010 Guang Zhu <guangzhu@google.com> enhancement for building app with emma code coverage

* global filter to avoid applying instrumentation on emma classes
* remove local variable information at dex step instead of compile time

Change-Id: If04c27bc717f34816077a98ead9ceb0dbcbb0d2f
bb67d21337f8d87628fbc09585be6cfe6ab0336c 06-Feb-2010 Jeff Hamilton <jham@android.com> Get LOCAL_MANIFEST_PACKAGE_NAME working.

Change-Id: Ieafbf2596252ee3a2fe5d1ad433e8863fbf84601
f184a0f26db350693902ab623c414974978f4ac4 01-Feb-2010 Brian Carlstrom <bdc@google.com> Add support for LOCAL_JAVACFLAGS

The Dalvik core libraries team would like to start making warnings
errors in certain packages by definition LOCAL_JAVACFLAGS. This will
allow easier debuging of warnings in other packages by supplying
"-Xlint:..." options.
899e62a841bebefe6d9ab37ddc682e72fcb0f92b 05-Feb-2010 Joe Onorato <joeo@android.com> Add an inherit-package macro to the build system.

This lets you use the source code from one apk to build a new one
with a new module name, a new android package name and optionally,
a new certificate.

To use this, in a makefile, add this:

$(call inherit-package, \
packages/apps/Music/Android.mk, \
Music, \
MusicFork, \
my_cert, \
com.example.music)

You don't need the LOCAL_PATH and CLEAR_VARS stuff. It will override
only the packages that are defined in the makefile name you give, but
if other modules of other types are defined, you will get an error
saying that it's defined twice. In that case, you need to move the
duplicate library (for example a .so) out into a different makefile.

A LOCAL_OVERRIDES_PACKAGES entry is automatically created for the
forked app.
e6b4e5b20ac8a3b01f1a99dd877a98c92036ce5e 13-Nov-2009 Jean-Baptiste Queru <jbq@google.com> eclair snapshot
2dcc806af56351dca462225be7ecfad7da5aa8f1 22-Sep-2009 Jing Yu <jingyu@google.com> Add FDO options to Android make system.
2daa2b3b059ac755e8280741b23d65360ae233bc 30-Aug-2009 Joe Onorato <joeo@android.com> Add the ability to turn on proguard for java targets, and to call aapt
to generate a rules file for proguard for stuff from the manifest and
other resources that need to be kept.
d0a44722be82319e45b6616267011d4dd17e767b 07-Aug-2009 Doug Zongker <dougz@android.com> add LOCAL_PREBUILT_STRIP_COMMENTS to clear_vars.mk
e334d255dc8f85d610f4d0339227a0b985494811 17-Jul-2009 Joe Onorato <joeo@android.com> Speed up the full build.

Now, by default, instead of fully building everything,
we skip dexing the modules that aren't going to be included
in the current build.

This will slow down some of the incremental builds (like tests),
but it improves the regular eng build from 27.5 minutes on my
Mac Pro to 25 minutes. That's not as much of an improvement
as I had hoped for, but it's still better.

There is also a change in here that puts the java-source-list
file which is used to get around limited command line lengths
in the proper directory. Before this change, it was an
accident that the directory for that file existed!
214a42bbb6e60f1231aa178c114a55dbe363c845 10-Apr-2009 Joe Onorato <> AI 145655: am: CL 145618 am: CL 145333 Cloned from CL 144759 by 'g4 patch'.
Original change by joeo@abreu on 2009/04/06 19:54:13.
Implement SDK add-ons in the build system.
- Add an option to use the standard javadoc doclet instead
of droiddoc, since droiddocs non-sdk templates aren't
ready for prime time.
- Add the notion of a stubs for a library. It's only
implemented for java libraries, but when we do native
libraries in the NDK or sdk-addons, it will work there too.
Original author: joeo
Merged from: //branches/cupcake/...
Original author: android-build

Automated import of CL 145655
64d85d0d827489c514f6aec075482563c80cda73 10-Apr-2009 Joe Onorato <> AI 145618: am: CL 145333 Cloned from CL 144759 by 'g4 patch'.
Original change by joeo@abreu on 2009/04/06 19:54:13.
Implement SDK add-ons in the build system.
- Add an option to use the standard javadoc doclet instead
of droiddoc, since droiddocs non-sdk templates aren't
ready for prime time.
- Add the notion of a stubs for a library. It's only
implemented for java libraries, but when we do native
libraries in the NDK or sdk-addons, it will work there too.
Original author: joeo
Merged from: //branches/cupcake/...

Automated import of CL 145618
8bbfe659d76266a8d45e19793d22e34dccfe6610 09-Apr-2009 Joe Onorato <> AI 145333: Cloned from CL 144759 by 'g4 patch'.
Original change by joeo@abreu on 2009/04/06 19:54:13.
Implement SDK add-ons in the build system.
- Add an option to use the standard javadoc doclet instead
of droiddoc, since droiddocs non-sdk templates aren't
ready for prime time.
- Add the notion of a stubs for a library. It's only
implemented for java libraries, but when we do native
libraries in the NDK or sdk-addons, it will work there too.

Automated import of CL 145333
88b607994a148f4af5bffee163e39ce8296750c6 04-Mar-2009 The Android Open Source Project <initial-contribution@android.com> auto import from //depot/cupcake/@135843
05806d7af62e07c6225b2e7103a1b115ecf6c9ad 04-Mar-2009 The Android Open Source Project <initial-contribution@android.com> auto import from //depot/cupcake/@135843
66339ad5cebeae8f4cbf7e335c67368abbb91223 16-Jan-2009 The Android Open Source Project <initial-contribution@android.com> auto import from //branches/cupcake/...@126645
dcc08f073b6873c69ab891d4f69f7c568e282df7 18-Dec-2008 The Android Open Source Project <initial-contribution@android.com> Code drop from //branches/cupcake/...@124589
b6c1cf6de79035f58b512f4400db458c8401379a 21-Oct-2008 The Android Open Source Project <initial-contribution@android.com> Initial Contribution