Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(2785)

Unified Diff: build/android/ant/apk-package.xml

Issue 1278573002: [Android] Add gyp support for multidex. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase Created 5 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: build/android/ant/apk-package.xml
diff --git a/build/android/ant/apk-package.xml b/build/android/ant/apk-package.xml
index e8b76f7e453064d56ef3ac2f4c3a3d44be1d7e57..cb7956091810c8c4da8e120376e6eeb0855bfb58 100644
--- a/build/android/ant/apk-package.xml
+++ b/build/android/ant/apk-package.xml
@@ -54,6 +54,9 @@
<property name="resource.package.file.name" value="${RESOURCE_PACKAGED_APK_NAME}" />
<property name="intermediate.dex.file" location="${DEX_FILE_PATH}" />
+ <condition property="multidex.enabled" value="true">
+ <equals arg1="${MULTIDEX_ENABLED}" arg2="1"/>
+ </condition>
<!-- Macro that enables passing a variable list of external jar files
to ApkBuilder. -->
@@ -70,13 +73,32 @@
hascode="${HAS_CODE}"
previousBuildType="/"
buildType="${build.is.packaging.debug}/${build.is.signing.debug}">
- <dex path="${intermediate.dex.file}"/>
+ <dex path="${intermediate.dex.file}" />
<nativefolder path="${native.libs.absolute.dir}" />
<extra-jars/>
</apkbuilder>
</sequential>
</macrodef>
+ <macrodef name="multidex-package-helper">
+ <element name="extra-jars" optional="yes" />
+ <sequential>
+ <apkbuilder
+ outfolder="${out.absolute.dir}"
+ resourcefile="${resource.package.file.name}"
+ apkfilepath="${out.packaged.file}"
+ debugpackaging="${build.is.packaging.debug}"
+ debugsigning="${build.is.signing.debug}"
+ verbose="${verbose}"
+ hascode="false"
+ previousBuildType="/"
+ buildType="${build.is.packaging.debug}/${build.is.signing.debug}">
+ <zip path="${intermediate.dex.file}" />
+ <nativefolder path="${native.libs.absolute.dir}" />
+ <extra-jars/>
+ </apkbuilder>
+ </sequential>
+ </macrodef>
<!-- Packages the application. -->
<target name="-package">
@@ -89,7 +111,14 @@
</package-helper>
</then>
<else>
- <package-helper />
+ <if condition="${multidex.enabled}">
+ <then>
+ <multidex-package-helper />
+ </then>
+ <else>
+ <package-helper />
+ </else>
+ </if>
</else>
</if>
</target>
« no previous file with comments | « base/test/android/junit/src/org/chromium/base/test/shadows/ShadowMultiDex.java ('k') | build/android/apkbuilder_action.gypi » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698