Commit Graph

7 Commits

Author SHA1 Message Date
Colin Cross 34054eb615 Revert "Upgrade to ManifestMerger2"
This reverts commit a636f16b34.

Bug: 36005379
Change-Id: If5516b34c103016529de4d591038e9e34260a8e8
2017-09-19 15:40:25 +00:00
Colin Cross a636f16b34 Upgrade to ManifestMerger2
Switch to using ManifestMerger2 from
prebuilts/gradle-plugin/com/android/tools/build/manifest-merger/25.3.1/manifest-merger-25.3.1.jar

Bug: 36005379
Test: m -j checkbuild
Change-Id: Ia03a1eb096ebab9578e5b08183faa86f6818ff3c
Merged-In: I83bd3f95778e93796d06f063aa7c61d2a63b117b
(cherry picked from commit e76e8021eb)
2017-09-18 21:08:58 +00:00
Ying Wang e295c3df68 AAPT2: library resource compilation
- Switch to static library's package-res.apk as the link artifact.
- For prebuilt AAR file, build package-res.apk using aapt2's "--dir"
  option.
- New LOCAL variables:
  LOCAL_USE_AAPT2: a module can opt-in with "LOCAL_USE_AAPT2 := true".
  LOCAL_STATIC_ANDROID_LIBRARIES: static Java libraries with compiled
                   resources.
  LOCAL_SHARED_ANDROID_LIBRARIES: shared Java libraries with compiled
                   resources.

Bug: 25958912
Change-Id: I4be2d1e8137555986338c2583cb39b0c97391751
2016-02-26 10:44:56 -08:00
Ying Wang dd71c85a45 Support to build with AAPT2
To build with AAPT2, set "USE_AAPT2=true".
TODO: Support split apks and generated resources from other than renderscript.

Bug: 25958912
Change-Id: I19b1a038824ce5b2a3d3ffadbce3173c845193fc
2016-01-25 22:41:43 -08:00
Ying Wang 12f4497565 Strip LOCAL_STATIC_JAVA_AAR_LIBRARIES
Change-Id: I0a0c4fe0cdd9c162976ef5f4c4709d400fde2d5a
2015-05-27 15:14:28 -07:00
Ying Wang 2902d4585f Add support for prebuilt AARs.
- You can give a .aar as source file to a prebuilt static Java library
  module. The build system will set up dependencies and rules to extract
  classes.jar and other resource files.
- To build against a prebuilt AAR module, use:
  LOCAL_STATIC_JAVA_AAR_LIBRARIES := <module names of aar prebuilt AARs>
  The build system will set up rules to merge the library's
  AndroidManifest.xml with the main AndroidManifest.xml, add the AAR's
  resource dirs and link/merge the AAR's classes.jar.

Bug: 18168693
Change-Id: Ic2c1d20572a93bd98dbc72f8a39e26b459e442c2
(cherry picked from commit e9dd9f2bfc)
2014-12-17 22:27:26 +00:00
Ying Wang dc7fee9fbf Set up rules to merge AndroidManifest.xmls
Now you can merge the library manifest files to the main app's
AndroidManifest.xml with LOCAL_FULL_LIBS_MANIFEST_FILES.
LOCAL_FULL_LIBS_MANIFEST_FILES is a list of paths relative to the top of
the source tree.

Bug: 12907528
Change-Id: I16a347c83dfb6fbbb7d5d40284b7c65aa682fdd2
2014-02-05 18:24:45 -08:00