diff options
author | jayjang@chromium.org <jayjang@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2013-03-19 21:40:39 +0000 |
---|---|---|
committer | jayjang@chromium.org <jayjang@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2013-03-19 21:40:39 +0000 |
commit | e5770c7626adcedb3c9ef04e9196a28feb552233 (patch) | |
tree | dfc749261cc05a0abd8d6e68e1742ef9dfb687dc /build | |
parent | fc8b612323dd4fe375c0e3e36bab50fe209c9998 (diff) | |
download | chromium_src-e5770c7626adcedb3c9ef04e9196a28feb552233.zip chromium_src-e5770c7626adcedb3c9ef04e9196a28feb552233.tar.gz chromium_src-e5770c7626adcedb3c9ef04e9196a28feb552233.tar.bz2 |
Make manifestmerge.enabled configurable from java_apk.gypi In order to put activity or service AndroidManifest.xml by flag we need to be able to set "manifestmerge.enabled=true" from gyp file. This is required to put googletv specific activity and services
BUG=181470
Review URL: https://chromiumcodereview.appspot.com/12450013
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@189115 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'build')
-rw-r--r-- | build/android/ant/apk-build.xml | 12 | ||||
-rw-r--r-- | build/java_apk.gypi | 7 |
2 files changed, 16 insertions, 3 deletions
diff --git a/build/android/ant/apk-build.xml b/build/android/ant/apk-build.xml index bc84338..d123279 100644 --- a/build/android/ant/apk-build.xml +++ b/build/android/ant/apk-build.xml @@ -37,6 +37,9 @@ <path id="project.library.bin.r.file.path"> <filelist files="${ADDITIONAL_R_TEXT_FILES}"/> </path> + <path id="project.library.manifest.file.path"> + <filelist files="${LIBRARY_MANIFEST_PATHS}"/> + </path> <script language="javascript"> var before = project.getProperty("ADDITIONAL_RES_PACKAGES"); project.setProperty("project.library.packages", before.replaceAll(" ", ";")); @@ -114,8 +117,12 @@ <property name="java.source" value="1.5" /> <property name="java.compilerargs" value="" /> - <!-- manifest merger default value --> - <property name="manifestmerger.enabled" value="false" /> + <!-- manifest merger default value if it's not set.--> + <condition property="manifestmerger.enabled" + value="false" + else="true"> + <equals arg1="${LIBRARY_MANIFEST_PATHS}" arg2=""/> + </condition> <!-- Verbosity --> <property name="verbose" value="false" /> @@ -304,6 +311,7 @@ appManifest="${manifest.abs.file}" outManifest="${out.manifest.abs.file}" enabled="${manifestmerger.enabled}"> + <library refid="project.library.manifest.file.path" /> </mergemanifest> <echo level="info">----------</echo> diff --git a/build/java_apk.gypi b/build/java_apk.gypi index 042bfd7..3f3e706 100644 --- a/build/java_apk.gypi +++ b/build/java_apk.gypi @@ -47,6 +47,8 @@ # By default, the package given in AndroidManifest.xml will be used. # java_strings_grd - The name of the grd file from which to generate localized # strings.xml files, if any. +# library_manifest_paths'- Paths to additional AndroidManifest.xml files from +# libraries. { 'variables': { @@ -68,6 +70,7 @@ 'is_test_apk%': 0, 'java_strings_grd%': '', 'grit_grd_file%': '', + 'library_manifest_paths%' : [], }, 'sources': [ '<@(native_libs_paths)' @@ -148,6 +151,7 @@ '>@(input_jars_paths)', '>@(native_libs_paths)', '>@(additional_input_paths)', + '>@(library_manifest_paths)', ], 'conditions': [ ['resource_dir!=""', { @@ -169,7 +173,7 @@ }], ['proguard_enabled == "true" and proguard_flags != ""', { 'inputs': ['<(java_in_dir)/<(proguard_flags)'] - }] + }], ], 'outputs': [ '<(PRODUCT_DIR)/apks/<(apk_name).apk', @@ -202,6 +206,7 @@ '-DAPP_MANIFEST_VERSION_CODE=<(app_manifest_version_code)', '-DPROGUARD_FLAGS=>(proguard_flags)', '-DPROGUARD_ENABLED=>(proguard_enabled)', + '-DLIBRARY_MANIFEST_PATHS=>(library_manifest_paths)', # Add list of inputs to the command line, so if inputs change # (e.g. if a Java file is removed), the command will be re-run. |