Chromium Code Reviews| OLD | NEW |
|---|---|
| (Empty) | |
| 1 <!-- Copyright (c) 2012 The Chromium Authors. All rights reserved. | |
| 2 | |
| 3 Use of this source code is governed by a BSD-style license that can be | |
| 4 found in the LICENSE file. | |
| 5 --> | |
| 6 <project name="Content" default="dist" basedir="."> | |
| 7 <description> | |
| 8 building content java source code with ant | |
| 9 </description> | |
| 10 <!-- set global properties for this build --> | |
| 11 <property environment="env"/> | |
| 12 <property name="sdk.dir" location="${env.ANDROID_SDK_ROOT}"/> | |
| 13 <property name="sdk.version" value="${env.ANDROID_SDK_VERSION}"/> | |
| 14 <property name="src" location="."/> | |
| 15 <property name="build" location="build"/> | |
|
Yaron
2012/04/19 00:35:34
Please use the PRODUCT_DIR approach jrg is introdu
| |
| 16 <property name="dist" location="dist"/> | |
| 17 | |
| 18 <condition property="location.base" | |
| 19 value="${sdk.dir}" | |
| 20 else="${sdk.dir}/platforms/android-${sdk.version}"> | |
| 21 <isset property="env.ANDROID_BUILD_TOP"/> | |
| 22 </condition> | |
| 23 | |
| 24 <target name="init"> | |
| 25 <!-- Create the time stamp --> | |
| 26 <tstamp/> | |
| 27 <!-- Create the build directory structure used by compile --> | |
| 28 <mkdir dir="${build}"/> | |
| 29 </target> | |
| 30 | |
| 31 <target name="compile" depends="init" | |
| 32 description="compile the source " > | |
| 33 <!-- Compile the java code from ${src} into ${build} --> | |
| 34 <javac srcdir="${src}" destdir="${build}"> | |
| 35 <classpath> | |
| 36 <path location="${location.base}/android.jar"/> | |
| 37 </classpath> | |
| 38 </javac> | |
| 39 </target> | |
| 40 | |
| 41 <target name="dist" depends="compile" | |
| 42 description="generate the distribution" > | |
| 43 <!-- Create the distribution directory --> | |
| 44 <mkdir dir="${dist}/lib"/> | |
| 45 | |
| 46 <!-- Put everything in ${build} into the chromium_content.jar file --> | |
| 47 <jar jarfile="${dist}/lib/chromium_content.jar" basedir="${build}"/> | |
| 48 </target> | |
| 49 | |
| 50 <target name="clean" | |
| 51 description="clean up" > | |
| 52 <!-- Delete the ${build} and ${dist} directory trees --> | |
| 53 <delete dir="${build}"/> | |
| 54 <delete dir="${dist}"/> | |
| 55 </target> | |
| 56 </project> | |
| OLD | NEW |