| OLD | NEW |
| 1 <?xml version="1.0" encoding="UTF-8"?> | 1 <?xml version="1.0" encoding="UTF-8"?> |
| 2 <!-- | 2 <!-- |
| 3 Copyright (C) 2005-2008 The Android Open Source Project | 3 Copyright (C) 2005-2008 The Android Open Source Project |
| 4 | 4 |
| 5 Licensed under the Apache License, Version 2.0 (the "License"); | 5 Licensed under the Apache License, Version 2.0 (the "License"); |
| 6 you may not use this file except in compliance with the License. | 6 you may not use this file except in compliance with the License. |
| 7 You may obtain a copy of the License at | 7 You may obtain a copy of the License at |
| 8 | 8 |
| 9 http://www.apache.org/licenses/LICENSE-2.0 | 9 http://www.apache.org/licenses/LICENSE-2.0 |
| 10 | 10 |
| 11 Unless required by applicable law or agreed to in writing, software | 11 Unless required by applicable law or agreed to in writing, software |
| 12 distributed under the License is distributed on an "AS IS" BASIS, | 12 distributed under the License is distributed on an "AS IS" BASIS, |
| 13 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | 13 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 14 See the License for the specific language governing permissions and | 14 See the License for the specific language governing permissions and |
| 15 limitations under the License. | 15 limitations under the License. |
| 16 --> | 16 --> |
| 17 | 17 |
| 18 <project default="-do-sign"> | 18 <project default="-package"> |
| 19 <property name="verbose" value="false" /> | 19 <property name="verbose" value="false" /> |
| 20 <property name="out.dir" location="${OUT_DIR}" /> | 20 <property name="out.dir" location="${OUT_DIR}" /> |
| 21 <!-- Output directories --> | 21 <!-- Output directories --> |
| 22 <property name="out.dir" value="bin" /> | 22 <property name="out.dir" value="bin" /> |
| 23 <property name="out.absolute.dir" location="${out.dir}" /> | 23 <property name="out.absolute.dir" location="${out.dir}" /> |
| 24 <property name="out.res.absolute.dir" location="${out.dir}/res" /> | 24 <property name="out.res.absolute.dir" location="${out.dir}/res" /> |
| 25 <property name="out.manifest.abs.file" location="${out.dir}/AndroidManifest.xm
l" /> | 25 <property name="out.manifest.abs.file" location="${out.dir}/AndroidManifest.xm
l" /> |
| 26 | 26 |
| 27 <!-- tools location --> | 27 <!-- tools location --> |
| 28 <property name="sdk.dir" location="${ANDROID_SDK_ROOT}"/> | 28 <property name="sdk.dir" location="${ANDROID_SDK_ROOT}"/> |
| (...skipping 10 matching lines...) Expand all Loading... |
| 39 <!-- Custom tasks --> | 39 <!-- Custom tasks --> |
| 40 <taskdef resource="anttasks.properties" classpathref="android.antlibs" /> | 40 <taskdef resource="anttasks.properties" classpathref="android.antlibs" /> |
| 41 | 41 |
| 42 <condition property="build.target" value="release" else="debug"> | 42 <condition property="build.target" value="release" else="debug"> |
| 43 <equals arg1="${CONFIGURATION_NAME}" arg2="Release" /> | 43 <equals arg1="${CONFIGURATION_NAME}" arg2="Release" /> |
| 44 </condition> | 44 </condition> |
| 45 <condition property="build.is.packaging.debug" value="true" else="false"> | 45 <condition property="build.is.packaging.debug" value="true" else="false"> |
| 46 <equals arg1="build.target" arg2="debug" /> | 46 <equals arg1="build.target" arg2="debug" /> |
| 47 </condition> | 47 </condition> |
| 48 | 48 |
| 49 <property name="out.final.file" location="${FINAL_APK_PATH}" /> | |
| 50 | |
| 51 <!-- Disables automatic signing. --> | 49 <!-- Disables automatic signing. --> |
| 52 <property name="build.is.signing.debug" value="false"/> | 50 <property name="build.is.signing.debug" value="false"/> |
| 53 | 51 |
| 54 <!-- SDK tools assume that out.packaged.file is signed and name it "...-unalig
ned" --> | 52 <!-- SDK tools assume that out.packaged.file is signed and name it "...-unalig
ned" --> |
| 55 <property name="out.packaged.file" value="${out.dir}/${APK_NAME}-unsigned.apk"
/> | 53 <property name="out.packaged.file" value="${UNSIGNED_APK_PATH}" /> |
| 56 <property name="out.unaligned.file" value="${out.dir}/${APK_NAME}-unaligned.ap
k" /> | |
| 57 | 54 |
| 58 <property name="resource.dir" value="${RESOURCE_DIR}"/> | 55 <property name="resource.dir" value="${RESOURCE_DIR}"/> |
| 59 <property name="resource.absolute.dir" location="${resource.dir}"/> | 56 <property name="resource.absolute.dir" location="${resource.dir}"/> |
| 60 | 57 |
| 61 <property name="asset.dir" value="${ASSET_DIR}" /> | 58 <property name="asset.dir" value="${ASSET_DIR}" /> |
| 62 <property name="asset.absolute.dir" location="${asset.dir}" /> | 59 <property name="asset.absolute.dir" location="${asset.dir}" /> |
| 63 | 60 |
| 64 <property name="native.libs.absolute.dir" location="${NATIVE_LIBS_DIR}" /> | 61 <property name="native.libs.absolute.dir" location="${NATIVE_LIBS_DIR}" /> |
| 65 | 62 |
| 66 <property name="aapt" location="${android.platform.tools.dir}/aapt" /> | 63 <property name="aapt" location="${android.platform.tools.dir}/aapt" /> |
| (...skipping 93 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 160 debugsigning="${build.is.signing.debug}" | 157 debugsigning="${build.is.signing.debug}" |
| 161 verbose="${verbose}" | 158 verbose="${verbose}" |
| 162 hascode="true" | 159 hascode="true" |
| 163 previousBuildType="/" | 160 previousBuildType="/" |
| 164 buildType="${build.is.packaging.debug}/${build.is.signing.debug}"> | 161 buildType="${build.is.packaging.debug}/${build.is.signing.debug}"> |
| 165 <dex path="${intermediate.dex.file}"/> | 162 <dex path="${intermediate.dex.file}"/> |
| 166 <sourcefolder path="${source.absolute.dir}"/> | 163 <sourcefolder path="${source.absolute.dir}"/> |
| 167 <nativefolder path="${native.libs.absolute.dir}" /> | 164 <nativefolder path="${native.libs.absolute.dir}" /> |
| 168 </apkbuilder> | 165 </apkbuilder> |
| 169 </target> | 166 </target> |
| 170 | |
| 171 | |
| 172 | |
| 173 <property name="key.store" value="${KEYSTORE_PATH}"/> | |
| 174 <property name="key.store.password" value="chromium"/> | |
| 175 <property name="key.alias" value="chromiumdebugkey"/> | |
| 176 <property name="key.alias.password" value="chromium"/> | |
| 177 <property name="zipalign" location="${android.tools.dir}/zipalign" /> | |
| 178 | |
| 179 <!-- Signs and zipaligns the apk. --> | |
| 180 <target name="-do-sign" depends="-package"> | |
| 181 <sequential> | |
| 182 <echo level="info">Signing final apk...</echo> | |
| 183 <signapk | |
| 184 input="${out.packaged.file}" | |
| 185 output="${out.unaligned.file}" | |
| 186 keystore="${key.store}" | |
| 187 storepass="${key.store.password}" | |
| 188 alias="${key.alias}" | |
| 189 keypass="${key.alias.password}" /> | |
| 190 | |
| 191 <zipalign | |
| 192 executable="${zipalign}" | |
| 193 input="${out.unaligned.file}" | |
| 194 output="${out.final.file}" | |
| 195 verbose="${verbose}" /> | |
| 196 <echo level="info">Release Package: ${out.final.file}</echo> | |
| 197 </sequential> | |
| 198 </target> | |
| 199 </project> | 167 </project> |
| OLD | NEW |