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

Side by Side Diff: content/shell/android/java/content_shell_apk.xml

Issue 10905138: Add test jar generation logic for ant builds. (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: rebase Created 8 years, 3 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 unified diff | Download patch
OLDNEW
1 <?xml version="1.0" encoding="UTF-8"?> 1 <?xml version="1.0" encoding="UTF-8"?>
2 <!-- 2 <!--
3 Copyright (c) 2012 The Chromium Authors. All rights reserved. 3 Copyright (c) 2012 The Chromium Authors. All rights reserved.
4 Use of this source code is governed by a BSD-style license that can be 4 Use of this source code is governed by a BSD-style license that can be
5 found in the LICENSE file. 5 found in the LICENSE file.
6 --> 6 -->
7 <project name="ContentShell" default="debug" basedir="."> 7 <project name="ContentShell" default="debug" basedir=".">
8 <description> 8 <description>
9 Building ContentShell.apk 9 Building ContentShell.apk
10 </description> 10 </description>
11 <import file="../../../../build/android/ant/common.xml"/> 11 <import file="../../../../build/android/ant/common.xml"/>
12 <import file="../../../../build/android/ant/sdk-targets.xml"/> 12 <import file="../../../../build/android/ant/sdk-targets.xml"/>
13 13
14 <!-- Convert the buildtype to lowercase. E.g Debug -> debug, Release -> releas e. --> 14 <!-- Convert the buildtype to lowercase. E.g Debug -> debug, Release -> releas e. -->
15 <script language="javascript"> 15 <script language="javascript">
16 project.setProperty("configuration.name", 16 project.setProperty("configuration.name",
17 project.getProperty("CONFIGURATION_NAME").toLowerCase()) 17 project.getProperty("CONFIGURATION_NAME").toLowerCase())
18 </script> 18 </script>
19 <property-value name="target.abi" value="${APP_ABI}"/> 19 <property-value name="target.abi" value="${APP_ABI}"/>
20 <property-location name="out.dir" location="${PRODUCT_DIR}/content_shell" 20 <property-location name="out.dir" location="${PRODUCT_DIR}/content_shell"
21 check-exists="false"/> 21 check-exists="false"/>
22 <property name="resource.absolute.dir" value="../res"/> 22 <property name="resource.absolute.dir" value="../res"/>
23 <property name="gen.absolute.dir" value="${out.dir}/gen"/> 23 <property name="gen.absolute.dir" value="${out.dir}/gen"/>
24 <property name="jar.libs.dir" value="${out.dir}/java/libs"/>
25 <path id="native.libs.gdbserver"> 24 <path id="native.libs.gdbserver">
26 <fileset file="${android.gdbserver}"/> 25 <fileset file="${android.gdbserver}"/>
27 </path> 26 </path>
28 <property name="native.libs.absolute.dir" location="${out.dir}/libs"/> 27 <property name="native.libs.absolute.dir" location="${out.dir}/libs"/>
29 <property name="asset.absolute.dir" location="${out.dir}/assets"/> 28 <property name="asset.absolute.dir" location="${out.dir}/assets"/>
29 <!-- Set the output directory for the final apk to the ${apks.dir}. -->
30 <property-location name="out.final.file" location="${apks.dir}/${ant.project.n ame}-debug.apk"
31 check-exists="false" />
32 <property name="generate.test.jar" value="true" />
30 33
31 <path id="out.dex.jar.input.ref"> 34 <path id="out.dex.jar.input.ref">
32 <pathelement location="${PRODUCT_DIR}/lib.java/chromium_base.jar"/> 35 <fileset file="${lib.java.dir}/chromium_content.jar"/>
cjhopman 2012/09/07 19:50:35 <pathelement location=
shashi 2012/09/07 23:31:31 Done.
33 <pathelement location="${PRODUCT_DIR}/lib.java/chromium_content.jar"/> 36 <fileset file="${lib.java.dir}/chromium_net.jar"/>
34 <pathelement location="${PRODUCT_DIR}/lib.java/chromium_media.jar"/> 37 <fileset file="${lib.java.dir}/chromium_base.jar"/>
35 <pathelement location="${PRODUCT_DIR}/lib.java/chromium_net.jar"/> 38 <fileset file="${lib.java.dir}/chromium_media.jar"/>
36 </path> 39 </path>
37 <property name="java.compilerargs" value="-classpath ${toString:out.dex.jar.in put.ref}"/>
38
39 <echo>classpath: ${toString:out.dex.jar.input.ref}</echo>
40
41 <!-- We expect PRODUCT_DIR to be set like the gyp var (e.g. $ROOT/out/Debug) - ->
cjhopman 2012/09/07 19:50:35 We are no longer checking that PRODUCT_DIR is set?
shashi 2012/09/07 21:02:30 It is already done in common.xml, due to safe sett
42 <fail message="PRODUCT_DIR env var not set?">
43 <condition>
44 <not>
45 <isset property="PRODUCT_DIR"/>
46 </not>
47 </condition>
48 </fail>
49
50 <target name="-post-compile"> 40 <target name="-post-compile">
51 <!-- 41 <!--
52 Copy gdbserver to main libs directory if building debug. 42 Copy gdbserver to main libs directory if building debug.
53 TODO(jrg): for now, Chrome on Android always builds native code 43 TODO(jrg): for now, Chrome on Android always builds native code
54 as Release and java/ant as Debug, which means we always install 44 as Release and java/ant as Debug, which means we always install
55 gdbserver. Resolve this discrepancy, possibly by making this 45 gdbserver. Resolve this discrepancy, possibly by making this
56 Release Official build java/ant as Release. 46 Release Official build java/ant as Release.
57 --> 47 -->
58 <if> 48 <if>
59 <condition> 49 <condition>
60 <equals arg1="${build.target}" arg2="debug"/> 50 <equals arg1="${build.target}" arg2="debug"/>
61 </condition> 51 </condition>
62 <then> 52 <then>
63 <echo message="Copying gdbserver to the apk to enable native debugging" /> 53 <echo message="Copying gdbserver to the apk to enable native debugging" />
64 <copy todir="${out.dir}/libs/${target.abi}"> 54 <copy todir="${out.dir}/libs/${target.abi}">
65 <path refid="native.libs.gdbserver"/> 55 <path refid="native.libs.gdbserver"/>
66 </copy> 56 </copy>
67 </then> 57 </then>
68 </if> 58 </if>
69 </target> 59 </target>
70 60
71 <!-- Classpath for javac --> 61 <!-- Classpath for javac -->
72 <path id="javac.custom.classpath"> 62 <path id="javac.custom.classpath">
73 <path refid="out.dex.jar.input.ref"/> 63 <path refid="out.dex.jar.input.ref"/>
74 </path> 64 </path>
75 <import file="${sdk.dir}/tools/ant/build.xml"/> 65 <import file="${sdk.dir}/tools/ant/build.xml"/>
76 </project> 66 </project>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698