From cf9855d9eb0d6c3f043b301791405a1a9b8a4a2e Mon Sep 17 00:00:00 2001 From: "leozwang@webrtc.org" Date: Tue, 10 Jul 2012 17:38:48 +0000 Subject: [PATCH] Update build.xml and api level Description: This cl updates build.xml following the sdk_r20 release. Also upgrade api level to 10. API level 9 is obsolete and we don't reply on level 9 particular features, upgrade to 10 to make development more easier. BUG= TEST=local build Review URL: https://webrtc-codereview.appspot.com/678005 git-svn-id: http://webrtc.googlecode.com/svn/trunk@2499 4adac7df-926f-26a2-2b94-8c16560cd09d --- .../test/android_test/AndroidManifest.xml | 2 +- .../main/test/android_test/build.xml | 750 +++++++++++------- .../main/test/android_test/project.properties | 2 +- 3 files changed, 457 insertions(+), 297 deletions(-) diff --git a/src/video_engine/main/test/android_test/AndroidManifest.xml b/src/video_engine/main/test/android_test/AndroidManifest.xml index 2b11ba4134..74e5a381af 100644 --- a/src/video_engine/main/test/android_test/AndroidManifest.xml +++ b/src/video_engine/main/test/android_test/AndroidManifest.xml @@ -16,7 +16,7 @@ - + diff --git a/src/video_engine/main/test/android_test/build.xml b/src/video_engine/main/test/android_test/build.xml index 555cb05e64..cd46e4d37a 100644 --- a/src/video_engine/main/test/android_test/build.xml +++ b/src/video_engine/main/test/android_test/build.xml @@ -221,13 +221,13 @@ Notice for all the files in this folder. - + - + @@ -252,6 +264,16 @@ Notice for all the files in this folder. + + + + + + + + + + @@ -265,41 +287,7 @@ Notice for all the files in this folder. - - - - - - - - - - - - - - - - - + @@ -322,16 +310,22 @@ Notice for all the files in this folder. - + + + + + + + @@ -343,8 +337,13 @@ Notice for all the files in this folder. - + + + + + + + @@ -381,6 +380,17 @@ Notice for all the files in this folder. + + + + + + + + + + @@ -396,7 +406,7 @@ Notice for all the files in this folder. - @{elseText} + @{elseText} @@ -418,7 +428,7 @@ Notice for all the files in this folder. - @{elseText} + @{elseText} @@ -445,7 +455,7 @@ Notice for all the files in this folder. - + @@ -485,9 +495,9 @@ Notice for all the files in this folder. buildType="${build.is.packaging.debug}/${build.is.signing.debug}"> - + - + @@ -511,7 +521,7 @@ Notice for all the files in this folder. - Running tests ... + Running tests ... @@ -522,7 +532,7 @@ Notice for all the files in this folder. - + @@ -549,7 +559,7 @@ Notice for all the files in this folder. - Uninstalling @{app.package} from the default emulator or device... + Uninstalling @{app.package} from the default emulator or device... @@ -562,96 +572,122 @@ Notice for all the files in this folder. + + + + + - - + + + Project Name: ${ant.project.name} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Switching between debug and non debug build: Deleting previous compilation output... + + + + + + + + + + + + + Switching from instrumented to non-instrumented build: Deleting previous compilation output... + + + + + + + + + + + - - + - + - - - + - - - - - - - - - - - - - - - - - Gathering info for ${ant.project.name}... - - - - - - - - - - - - - + + + + + - + + + + + @@ -670,26 +706,72 @@ Notice for all the files in this folder. + Resolving Build Target for ${ant.project.name}... + + + + + + + ---------- + Creating output directories if needed... + + + + + + + + + + ---------- + Resolving Dependencies for ${ant.project.name}... + + - + - Building Libraries + + + + + + ---------- + Building Libraries with '${project.libraries.target}'... + + - + + - - ############################################ - **** Back to project ${ant.project.name} **** - ############################################ @@ -702,52 +784,24 @@ Notice for all the files in this folder. - Building tested project at ${tested.project.absolute.dir} + ---------- + Building tested project at ${tested.project.absolute.dir} with '${tested.project.target}'... - - ############################################ - **** Back to project ${ant.project.name} **** - ############################################ + + + + + + + - - - - - - - - - - - - - - - - - - - - Switching from instrumented to non-instrumented build: Deleting previous compilation output... - - - - - Creating output directories if needed... - - - - - - - - + + + + + - ---------- - Handling aidl files... - + Handling aidl files... + - ---------- - Handling RenderScript files... + ---------- + Handling RenderScript files... + targetApi="${project.minSdkVersion}" + optLevel="${renderscript.opt.level}" + buildType="${build.is.packaging.debug}" + previousBuildType="${build.last.is.packaging.debug}"> - ---------- - Handling Resources... + ---------- + Handling Resources... + libraryResFolderPathRefid="project.library.res.folder.path" + libraryPackagesRefid="project.library.packages" + ignoreAssets="${aapt.ignore.assets}" + proguardFile="${out.absolute.dir}/proguard.txt"> + + ---------- + Handling BuildConfig class... + + @@ -800,69 +878,78 @@ Notice for all the files in this folder. - - - - - - - + + + + + + classpathref="project.javac.classpath" + fork="${need.javac.fork}"> - - - + + + + + Instrumenting classes from ${out.absolute.dir}/classes... + + + + + + + + + + + + + + + + + - Creating library output jar file... + Creating library output jar file... - Custom jar packaging exclusion: ${android.package.excludes} + Custom jar packaging exclusion: ${android.package.excludes} + + + - + - - - - Instrumenting classes from ${out.absolute.dir}/classes... - - - - - - - - @@ -903,7 +990,7 @@ Notice for all the files in this folder. all the jar files separated by a platform path-separator. Each path must be quoted if it contains spaces. --> - + @@ -913,31 +1000,43 @@ Notice for all the files in this folder. - + - + - + + + + + + + - @${proguard.config} - -injars ${project.jars} + -include "${proguard.configcmd}" + -include "${out.absolute.dir}/proguard.txt" + -injars ${project.all.classes.value} -outjars "${obfuscated.jar.file}" - -libraryjars ${android.libraryjars} + -libraryjars ${project.target.classpath.value} -dump "${obfuscate.absolute.dir}/dump.txt" -printseeds "${obfuscate.absolute.dir}/seeds.txt" -printusage "${obfuscate.absolute.dir}/usage.txt" @@ -995,17 +1094,18 @@ Notice for all the files in this folder. versioncode="${version.code}" versionname="${version.name}" debug="${build.is.packaging.debug}" - manifest="AndroidManifest.xml" + manifest="${out.manifest.abs.file}" assets="${asset.absolute.dir}" - androidjar="${android.jar}" + androidjar="${project.target.android.jar}" apkfolder="${out.absolute.dir}" nocrunch="${build.packaging.nocrunch}" resourcefilename="${resource.package.file.name}" resourcefilter="${aapt.resource.filter}" - projectLibrariesResName="project.libraries.res" - projectLibrariesPackageName="project.libraries.package" + libraryResFolderPathRefid="project.library.res.folder.path" + libraryPackagesRefid="project.library.packages" previousBuildType="${build.last.target}" - buildType="${build.target}"> + buildType="${build.target}" + ignoreAssets="${aapt.ignore.assets}"> @@ -1034,6 +1134,9 @@ Notice for all the files in this folder. + + + @@ -1051,11 +1154,24 @@ Notice for all the files in this folder. - + - + + + + + + + + + + + + + + @@ -1063,6 +1179,9 @@ Notice for all the files in this folder. + + + @@ -1071,20 +1190,20 @@ Notice for all the files in this folder. - + - Debug Package: ${out.final.file} + Debug Package: ${out.final.file} + - - @@ -1110,15 +1229,16 @@ Notice for all the files in this folder. - No key.store and key.alias properties found in build.properties. - Please sign ${out.packaged.file} manually - and run zipalign from the Android SDK tools. + No key.store and key.alias properties found in build.properties. + Please sign ${out.packaged.file} manually + and run zipalign from the Android SDK tools. + proguard.config is ${proguard.config} @@ -1127,6 +1247,7 @@ Notice for all the files in this folder. + Proguard.config is enabled @@ -1146,12 +1267,15 @@ Notice for all the files in this folder. - + + + ************************************************* @@ -1168,40 +1292,40 @@ Notice for all the files in this folder. - - - + - Signing final apk... - Signing final apk... + + keypass="${key.alias.password}"/> - - Release Package: ${out.final.file} + + Release Package: ${out.final.file} + + + + @@ -1226,7 +1350,7 @@ Notice for all the files in this folder. - Instrumented Package: ${out.final.file} + Instrumented Package: ${out.final.file} @@ -1242,33 +1366,67 @@ Notice for all the files in this folder. - - + - + + + + - + - + - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + value="/data/data/${tested.project.app.package}/coverage.ec" /> @@ -1280,30 +1438,37 @@ Notice for all the files in this folder. - Downloading coverage file into project directory... + Downloading coverage file into project directory... - + - Extracting coverage report... + Extracting coverage report... + + + + + + + + + - + - - - - + + - + - Cleaning up temporary files... - - - Saving the report file in ${basedir}/coverage/coverage.html + Cleaning up temporary files... + + + Saving the report file in ${out.absolute.dir}/coverage.html @@ -1334,7 +1499,7 @@ Notice for all the files in this folder. - Installing ${out.final.file} onto default emulator or device... + Installing ${out.final.file} onto default emulator or device... @@ -1405,30 +1570,25 @@ Notice for all the files in this folder. - - - - - + - + - Could not find application package in manifest. Cannot run 'adb uninstall'. + - - + @@ -1439,16 +1599,16 @@ Notice for all the files in this folder. + expression="/manifest/@package" output="tested.project.app.package" /> - + - + - Could not find tested application package in manifest. Cannot run 'adb uninstall'. + @@ -1483,7 +1643,7 @@ Notice for all the files in this folder. debug key. test: Runs the tests. Project must be a test project and must have been built. Typical usage would be: - ant [emma] debug installt test + ant [emma] debug install test emma: Transiently enables code coverage for subsequent targets. install: Installs the newly build package. Must either be used diff --git a/src/video_engine/main/test/android_test/project.properties b/src/video_engine/main/test/android_test/project.properties index 4d7ea1e41e..ddd0fc4187 100644 --- a/src/video_engine/main/test/android_test/project.properties +++ b/src/video_engine/main/test/android_test/project.properties @@ -10,4 +10,4 @@ # Indicates whether an apk should be generated for each density. split.density=false # Project target. -target=android-9 +target=android-10