diff options
| author | Siva Velusamy <vsiva@google.com> | 2013-06-10 18:22:08 -0700 |
|---|---|---|
| committer | Siva Velusamy <vsiva@google.com> | 2013-06-12 16:17:53 -0700 |
| commit | 4964a0b8943ddab43e4e02d83c539fa9293edb69 (patch) | |
| tree | 18998b25ee5a4484bd6fd25b5c773573b03a5525 | |
| parent | 3bc980fa160ea8f7e77b27fa048eaf410a0d2dab (diff) | |
| download | sdk-4964a0b8943ddab43e4e02d83c539fa9293edb69.zip sdk-4964a0b8943ddab43e4e02d83c539fa9293edb69.tar.gz sdk-4964a0b8943ddab43e4e02d83c539fa9293edb69.tar.bz2 | |
Install Translation Plugin if available
Change-Id: I8a517c2ced3a0293bb94b9955cad9617f555faa8
| -rw-r--r-- | adtproductbuild/build.xml | 16 | ||||
| -rw-r--r-- | eclipse/features/com.android.ide.eclipse.adt.package/feature.xml | 7 |
2 files changed, 22 insertions, 1 deletions
diff --git a/adtproductbuild/build.xml b/adtproductbuild/build.xml index 95e682a..4c5cbb9 100644 --- a/adtproductbuild/build.xml +++ b/adtproductbuild/build.xml @@ -84,6 +84,16 @@ </copy> </target> + <property name="GooglePlayTranslation.zip" value="${ANDROID_SRC}/tools/vendor/google/TranslationPluginForEclipse/ADT_Translation_Manager_plugin.zip" /> + <available file="${GooglePlayTranslation.zip}" property="translation.plugin.present" /> + + <!-- Add localization plugin to the list of features if necessary --> + <target name="update-features" if="translation.plugin.present"> + <replace file="${productBuildDir}/features/com.android.ide.eclipse.adt.package/feature.xml" + token='!--import feature="com.google.i18n.inkstone.eclipse.localization" --' + value='import feature="com.google.i18n.inkstone.eclipse.localization" /' /> + </target> + <!-- create target platform --> <target name="create-target"> <mkdir dir="${targetDir}" /> @@ -101,8 +111,12 @@ <unzip src="${targetSrcDir}/egit/org.eclipse.egit.repository-2.2.0.201212191850-r.zip" dest="${targetDir}/repos/egit" overwrite="false" /> </target> + <target name="create-translation-target" if="translation.plugin.present"> + <unzip src="${GooglePlayTranslation.zip}" dest="${targetDir}/repos/tpe" overwrite="false" /> + </target> + <!-- Launch pde build to build the adtpackage product --> - <target name="feature-build" depends="copy_srcs, create-target"> + <target name="feature-build" depends="copy_srcs, update-features, create-target, create-translation-target"> <java classname="org.eclipse.equinox.launcher.Main" fork="true" failonerror="true"> <arg value="-application" /> <arg value="org.eclipse.ant.core.antRunner" /> diff --git a/eclipse/features/com.android.ide.eclipse.adt.package/feature.xml b/eclipse/features/com.android.ide.eclipse.adt.package/feature.xml index 15871b1..8e69281 100644 --- a/eclipse/features/com.android.ide.eclipse.adt.package/feature.xml +++ b/eclipse/features/com.android.ide.eclipse.adt.package/feature.xml @@ -79,6 +79,13 @@ <import feature="com.android.ide.eclipse.hierarchyviewer" version="22.0.0" match="greaterOrEqual" /> <import feature="com.android.ide.eclipse.ndk" version="22.0.0" match="greaterOrEqual" /> <import feature="com.android.ide.eclipse.traceview" version="22.0.0" match="greaterOrEqual" /> + <!-- + The build scripts will pull in the translation plugin if its plugin repository is accessible. + The following line should remain without any modifications as the build script looks for + exactly this pattern and removes the comment tags. + See sdk.git/adtproductbuild/build.xml. + --> + <!--import feature="com.google.i18n.inkstone.eclipse.localization" --> </requires> </feature> |
