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
This reverts commit 28b46fc16c.
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.
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
$(built_odex) depends on $(LOCAL_BUILT_MODULE) but doesn't have any build
recipe. It is built by the rules of $(LOCAL_BUILT_MODULE) that results in
a subtle bug: $(built_odex) is always newer than $(LOCAL_BUILT_MODULE)
if $(LOCAL_BUILT_MODULE) rebuilt. Therefore 'make' thinks the targets
(/system/app/$app.odex) depending on $(built_odex) don't need to be updated.
It seems an allegedly optimization bug of 'make'.
The simple fix is to explicitly add $(LOCAL_BUILT_MODULE) as a dependency
of $(installed_odex).
If we use +=, the right side may be deferred to evaluate,
if that target-specific variable is not defined yet.
That's a mistke.
Change-Id: I1635ee4791473f407866e010d612948c02cdebf6
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
Instead we should explicitly set up the dependency, if the module will
be used in the build process; Use LOCAL_MODULE_TAGS with eng, debug or
tests if the module is for testing; or add to PRODUCT_PACKAGES if it's
required by a product.
Change-Id: Ic26319c26c1166bc1062dfbcfb4e006af185249a
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
With this change, by choosing the right build target, you can reduce
significant verification build time:
If you are working on the framework, "make target-java" sounds enough;
if you are working on native target code, "make target-native" saves
your time by not building the Java code.
This will help reduce uncaught breakges for by default not everything
is built now.
Change-Id: I5a7c82d3f6372db03bea76155c8d6cc63d988eae
# Via Android Git Automerger (2) and others
* commit '46fa45ad76ff63978bd35a07aa5e1d743657bf55':
Use += to append to target-specific PRIVATE_CLEAN_FILES
To pick up a NOTICE file in LOCAL_PATH and attach it to
/system/lib/libfoo.so, use the following syntax:
include $(CLEAR_VARS)
LOCAL_MODULE_CLASS := NOTICE_FILES
LOCAL_INSTALLED_MODULE := $(PRODUCT_OUT)/system/lib/libfoo.so
include $(BUILD_NOTICE_FILE)
Bug: 7460213
Change-Id: Ie692be72deab37be04d1b578578c131a0885a090
To reduce the start time.
With the change and previous change of doing clean step in only given paths,
start time of mm/mmm is reduced from ~5s to about 1s;
lunch time is reduced from ~40s to 3.5s.
Bug: 7186768,7169854
Change-Id: Ifd72ba1c6362a5e1125a23c505fd47947ab56675
To reduce the start time.
With the change and previous change of doing clean step in only given paths,
start time of mm/mmm is reduced from ~5s to about 1s;
lunch time is reduced from ~40s to 3.5s.
Bug: 7186768,7169854
Change-Id: Ifd72ba1c6362a5e1125a23c505fd47947ab56675
Instead we should explicitly set up the dependency, if the module will
be used in the build process; Use LOCAL_MODULE_TAGS with eng, debug or
tests if the module is for testing; or add to PRODUCT_PACKAGES if it's
required by a product.
Change-Id: I326e97df6630dee4acc6582ce6cef2dec8289155
It is not forbidden to say LOCAL_MODULE_TAGS := user,
and if you don't say LOCAL_MODULE_TAGS, it now defaults
to optional.
Change-Id: I0a0b200bb6f1c7bf1fe3a89cdc8f69678617526c