diff options
author | Eric Cloninger <dcp874@motorola.com> | 2012-08-21 16:47:26 -0500 |
---|---|---|
committer | Eric Cloninger <dcp874@motorola.com> | 2012-08-21 16:47:26 -0500 |
commit | caaf5251628a0ef95931ed2e54449dbde92d97fc (patch) | |
tree | b77127837ffddddf5fe7dafb48b812a3e125b7f5 | |
parent | dd37e1328b736a11354a5847ad82c5f2551defa5 (diff) | |
download | motodev-caaf5251628a0ef95931ed2e54449dbde92d97fc.tar.gz |
Scripted build files for MOTODEV tools
Build the MOTODEV Eclipse plugins and App Validator with ant.
Change-Id: I5e85c02797f8c7400412f881c1f69ca518e4b25e
Signed-off-by: Eric Cloninger <dcp874@motorola.com>
40 files changed, 4221 insertions, 0 deletions
diff --git a/makefile/auto_tests/ant/build.xml b/makefile/auto_tests/ant/build.xml new file mode 100644 index 0000000..54ec1fe --- /dev/null +++ b/makefile/auto_tests/ant/build.xml @@ -0,0 +1,51 @@ +<?xml version="1.0" encoding="UTF-8" ?> + + +<project name="testsuite" default="run"> + +<property file="../config.properties"/> + + <property name="eclipse-home" value="${MOTODEV_INSTALLATION_PATH_BUILD}" /> + <property name="plugin-name" value="com.motorola.studio.android.autotester" /> + <property name="test-classname" value="${CATEGORY}" /> + <property name="library-file" value="${LIBRARY_PATH_BUILD}/library.xml" /> + + + <target name="suite"> + + <property name="jvmOption" value=""></property> + + <property name="temp-workspace" value="workspace" /> + <delete dir="${temp-workspace}" quiet="true" /> + + <ant target="swtbot-test" antfile="${library-file}" dir="${eclipse-home}"> + <property name="data-dir" value="${temp-workspace}" /> + <property name="plugin-name" value="${plugin-name}" /> + <property name="os" value="" /> + <property name="ws" value="workspace" /> + <property name="arch" value="x86_64" /> + <property name="classname" value="${test-classname}" /> + <property name="vmargs" value=" -Xms128M -XX:MaxPermSize=512m -Xmx512M" /> + </ant> + </target> + + <target name="cleanup" > + <delete dir="${WORKSPACE_TEMP}" /> + </target> + <!--target name="run" depends="init, suite, cleanup"--> + <target name="run" depends="suite, cleanup"> + <antcall target="finishing"/> + </target> + +<target name="finishing" if="${COPY_LOG}"> + <property file="../lastlog.txt"/> + <echo>Last Log: ${LAST_LOG_DIR} workspace: ${WORKSPACE}</echo> + <mkdir dir="${LAST_LOG_DIR}/autotests"/> + <copy todir="${LAST_LOG_DIR}/autotests"> + <fileset dir="${WORKSPACE}/results" includes="**/**"/> + <fileset file="../logscripts.txt"/> + <fileset file="logant.txt"/> + </copy> +</target> + +</project> diff --git a/makefile/auto_tests/config.properties b/makefile/auto_tests/config.properties new file mode 100644 index 0000000..8a6f1d1 --- /dev/null +++ b/makefile/auto_tests/config.properties @@ -0,0 +1,45 @@ +AUTO_TEST_BASE=/android/2.2.0/automated_tests +HOME_PATH=/home/rdbp36 +ANT_LOCATION=/android/apache-ant-1.8.1/bin + + +####### INIT SCRIPT USE ONLY, DO NOT MODIFY ########## +BUILD_BASE_PATH=/android/2.2.0 +SOURCE_BASE_PATH=${BUILD_BASE_PATH}/env/code/android/makefile/auto_tests +BUILD_INSTALLERS=${BUILD_BASE_PATH}/logs/Android-2.2.0 +INSTALLER_NAME=studio_linux_gtk_x86_64.jar +#comment the line below if you don't want to publish the results on cruisecontrol +COPY_LOG=TRUE +#comment the line below if the auto tests will run on the current machine +SHOW_DISPLAY=10.10.26.211:0.0 +####### INIT SCRIPT USE ONLY, DO NOT MODIFY ########## + +AUTO_TEST_TEMP_FILES=${AUTO_TEST_BASE}/temp +AUTO_TEST_TEMP_FILES_BUILD=${AUTO_TEST_BASE}/temp #on Linux, should have the same value of the variable above, on Windows, should initiate with c:/ and not /cygdrive +AUTO_TEST_FILES=${AUTO_TEST_BASE}/files # This directory contains all necessary dependencies to run automated tests +AUTO_TEST_SCRIPT_FILES=${AUTO_TEST_BASE}/files/scripts # configuration files and scripts should be placed here + + +#Path of the workspace directory +WORKSPACE=${AUTO_TEST_TEMP_FILES}/workspace +#on Linux, should have the same value of the variable above, on Windows, should initiate with c:/ and not /cygdrive +WORKSPACE_BUILD=${AUTO_TEST_TEMP_FILES}/workspace +SDK_FOLDER=${AUTO_TEST_FILES}/android-sdk-linux_x86 #Path of the SDK Folder +KEYSTORE_SOURCE=${AUTO_TEST_FILES}/motodev.keystore #keystore file (source) +KEYSTORE_PATH=${HOME_PATH}/motodevstudio/tools/ #directory where KEYSTORE_SOURCE file will be copied to +SWTBOT_FILES=${AUTO_TEST_FILES}/REPO_SWTBOT.zip #Path of the SWTBot Files, on Windows, should initiate with c:/ and not /cygdrive +LIBRARY_FILE=${AUTO_TEST_FILES}/library.xml #Path of the 'library.xml' file +PLUGIN_FILES=${AUTO_TEST_FILES}/plugin_files/ #Path of the .jar File + + +#directory where Studio is installed +MOTODEV_INSTALLATION_PATH=${AUTO_TEST_TEMP_FILES}/motodev_studio_installed + +#on Linux, should have the same value of the variable above, on Windows, should initiate with c:/ and not /cygdrive +MOTODEV_INSTALLATION_PATH_BUILD=${AUTO_TEST_TEMP_FILES}/motodev_studio_installed + +LIBRARY_PATH=${MOTODEV_INSTALLATION_PATH}/plugins/org.eclipse.swtbot.eclipse.junit4.headless_2.0.4.20110304_0338-e5aff47-dev-e36 +LIBRARY_PATH_BUILD=${MOTODEV_INSTALLATION_PATH_BUILD}/plugins/org.eclipse.swtbot.eclipse.junit4.headless_2.0.4.20110304_0338-e5aff47-dev-e36 +WORKSPACE_TEMP=${WORKSPACE}/auto_workspace_temp +WORKSPACE_TEMP_BUILD=${WORKSPACE_BUILD}/auto_workspace_temp +CATEGORY=itc003.ITC003All diff --git a/makefile/auto_tests/configure_start_auto_tests.sh b/makefile/auto_tests/configure_start_auto_tests.sh new file mode 100644 index 0000000..99fd2c8 --- /dev/null +++ b/makefile/auto_tests/configure_start_auto_tests.sh @@ -0,0 +1,152 @@ +#!/bin/sh +# +# This script configures a Studio installation in order to make it possible to run the automated tests over it. +# +# Source the properties: +. ./config.properties +echo "Initiating configure_start_auto_tests.sh" +echo "--- Starting required setups to prepare MOTODEVSTUDIO before to start the Automated Tests ---" +echo + +echo "Copying SDK Folder (1/2)" +echo + +### Copy and Paste to destination path. The folder 'SDK' to inside 'L' +echo "Installation path: $MOTODEV_INSTALLATION_PATH" +cp -r $SDK_FOLDER $MOTODEV_INSTALLATION_PATH +sleep 1 + +echo "Copying SDK Folder (2/2)" +echo + +mkdir $WORKSPACE +mkdir $WORKSPACE_TEMP +### The folder 'SDK' to inside 'WORKSPACE' +cp -r $SDK_FOLDER $WORKSPACE +sleep 1 + + +echo "Deleting folder inside SDK Folder" +echo +rm -rf $WORKSPACE/$SDK_FOLDER/platforms/android-8 + + +echo "Creating folders and Copying .keystore file" +echo + +### The file '.keystore' to inside 'KEYSTORE_PATH' +cd $HOME_PATH +mkdir motodevstudio +cd motodevstudio +mkdir tools +cp $KEYSTORE_SOURCE $KEYSTORE_PATH + +echo "Creating an AVD" +echo + +### Create AVD +cd $SDK_FOLDER/tools +mkdir $AUTO_TEST_TEMP_FILES +AUX_UNAME=`uname -a|grep Linux` +if [ "$AUX_UNAME" != "" ] +then +ANDROID_EXE=android +else +ANDROID_EXE=android.bat +fi +echo "no" | ./$ANDROID_EXE create avd --force -n AVD -t 1 -p $AUTO_TEST_TEMP_FILES_BUILD/avds_autotest + + +echo "Installing SWTBot Plug-ins" +echo + +### Install SWTBot Plug-ins + +id1="org.eclipse.swtbot.feature.group" +id2="org.eclipse.swtbot.eclipse.test.junit4.feature.group" +id3="org.eclipse.swtbot.eclipse.feature.group" +id4="org.eclipse.swtbot.eclipse.gef.feature.group" + +cd $MOTODEV_INSTALLATION_PATH +if [ "$AUX_UNAME" != "" ] +then +MOTODEV_EXE="motodevstudio" +else +MOTODEV_EXE="motodevstudio.exe" +fi + + +echo "Installing $id1" +./$MOTODEV_EXE -noSplash -application org.eclipse.equinox.p2.director -metadataRepository jar:file:$SWTBOT_FILES\!/ -artifactRepository jar:file:$SWTBOT_FILES\!/ -installIU $id1 -profileProperties org.eclipse.update.install.features=true -vmArgs -Xms512M -Xmx512M + +echo "Installing $id2" +./$MOTODEV_EXE -noSplash -application org.eclipse.equinox.p2.director -metadataRepository jar:file:$SWTBOT_FILES\!/ -artifactRepository jar:file:$SWTBOT_FILES\!/ -installIU $id2 -profileProperties org.eclipse.update.install.features=true -vmArgs -Xms512M -Xmx512M + +echo "Installing $id3" +./$MOTODEV_EXE -noSplash -application org.eclipse.equinox.p2.director -metadataRepository jar:file:$SWTBOT_FILES\!/ -artifactRepository jar:file:$SWTBOT_FILES\!/ -installIU $id3 -profileProperties org.eclipse.update.install.features=true -vmArgs -Xms512M -Xmx512M + +echo "Installing $id4" +./$MOTODEV_EXE -noSplash -application org.eclipse.equinox.p2.director -metadataRepository jar:file:$SWTBOT_FILES\!/ -artifactRepository jar:file:$SWTBOT_FILES\!/ -installIU $id4 -profileProperties org.eclipse.update.install.features=true -vmArgs -Xms512M -Xmx512M + + + +echo "Replacing 'library.xml' file" +echo + +### Changing the 'library.xml' file (Replacing the original file) +echo $WORKSPACE_BUILD|sed "s/\//\\\\\//g" > $AUTO_TEST_TEMP_FILES/temp.txt +W=`tail -1 $AUTO_TEST_TEMP_FILES/temp.txt` +sed "s/WORKSPACE/$W/g" $LIBRARY_FILE > $AUTO_TEST_TEMP_FILES/library.xml + +echo $WORKSPACE_TEMP_BUILD|sed "s/\//\\\\\//g" > $AUTO_TEST_TEMP_FILES/temp.txt +W1=`tail -1 $AUTO_TEST_TEMP_FILES/temp.txt` +sed "s/WORKTEMP/$W1/g" $AUTO_TEST_TEMP_FILES/library.xml > $LIBRARY_PATH/library.xml + + + +if [ "$AUX_UNAME" != "" ] +then +AUTO_TEST_OS1=linux +AUTO_TEST_OS2=gtk +AUTO_TEST_ARCH=x86_64 +else +AUTO_TEST_OS1=win32 +AUTO_TEST_OS2=win32 +AUTO_TEST_ARCH=x86_64 +fi + + +sed "s/AUTO_TEST_OS1/$AUTO_TEST_OS1/g" $LIBRARY_PATH/library.xml > $AUTO_TEST_TEMP_FILES/library.xml2 +sed "s/AUTO_TEST_OS2/$AUTO_TEST_OS2/g" $AUTO_TEST_TEMP_FILES/library.xml2 > $AUTO_TEST_TEMP_FILES/library.xml3 +sed "s/AUTO_TEST_ARCH/$AUTO_TEST_ARCH/g" $AUTO_TEST_TEMP_FILES/library.xml3 > $LIBRARY_PATH/library.xml + + +echo "Copying the .jar file" +echo + +find $PLUGIN_FILES -iname '*.jar' -exec cp \{\} $MOTODEV_INSTALLATION_PATH/plugins/ \; +find $PLUGIN_FILES -iname '*.zip' -exec cp \{\} $WORKSPACE/ \; +cd $WORKSPACE +unzip -u *.zip + + +echo +echo "--- Setup DONE! ---" + +echo +echo "--- Now, starting the ANT execution ---" +echo + + +### ANT +cd $AUTO_TEST_SCRIPT_FILES/ant +export PATH=$ANT_LOCATION:$PATH +if [ "$SHOW_DISPLAY" != "" ] +then + export DISPLAY=$SHOW_DISPLAY +fi +ant -logfile logant.txt + +echo +echo "Finishing configure_start_auto_tests.sh" +echo diff --git a/makefile/auto_tests/init_auto_tests.sh b/makefile/auto_tests/init_auto_tests.sh new file mode 100644 index 0000000..7ca99f5 --- /dev/null +++ b/makefile/auto_tests/init_auto_tests.sh @@ -0,0 +1,47 @@ +#!/bin/sh +# +# This script is used for the build server only. It installs the latest generated build of the Studio and calls +# other script to configure the automated tests environment and run the auto tests. +# It also copies the auto test scripts from the git repository to the directory that contains all the auto test dependencies. +# +# Source the properties: +. ./config.properties + +echo "Initiating init_auto_tests.sh" +echo "Cleaning previous installation." +rm -rf $AUTO_TEST_TEMP_FILES + +echo "Retrieving last generated installer." +LAST_LOG_WC=`ls -latr $BUILD_INSTALLERS |grep drw |tail -1|wc -m` +LAST_LOG_WC1=`echo "$LAST_LOG_WC-14" |bc` +LAST_LOG_WC2=`echo "$LAST_LOG_WC-1" |bc` +LAST_LOG=`ls -latr $BUILD_INSTALLERS |grep drw |tail -1|cut -c $LAST_LOG_WC1-$LAST_LOG_WC2` +LAST_BUILD_INSTALLERS=$BUILD_INSTALLERS/$LAST_LOG +echo "LAST_LOG_DIR=$LAST_BUILD_INSTALLERS" > lastlog.txt +fileName=$INSTALLER_NAME +fullFileName=$LAST_BUILD_INSTALLERS/$fileName +if [ ! -f $fullFileName ]; then + echo "Filename $fullFileName does not exists." + exit 1 +fi +echo "Last installer found at: $fullFileName" +mkdir $AUTO_TEST_TEMP_FILES +cp $fullFileName $AUTO_TEST_TEMP_FILES +chmod 755 $AUTO_TEST_TEMP_FILES/$fileName + +echo "Updating the properties file with the installation path." +echo $MOTODEV_INSTALLATION_PATH|sed "s/\//\\\\\//g" > $AUTO_TEST_TEMP_FILES/temp.txt +W=`tail -1 $AUTO_TEST_TEMP_FILES/temp.txt` +sed "s/MOTODEV_INSTALLATION_PATH/$W/" $SOURCE_BASE_PATH/install_properties.txt > $AUTO_TEST_TEMP_FILES/install_properties_aux.txt + +echo "Installing MOTODEV Studio for Android at $MOTODEV_INSTALLATION_PATH" +java -jar $AUTO_TEST_TEMP_FILES/$fileName $AUTO_TEST_TEMP_FILES/install_properties_aux.txt + +echo "Copying the scripts to the directory with all autotest dependencies." +#cp $SOURCE_BASE_PATH/init_auto_tests* $AUTO_TEST_SCRIPT_FILES/. +#cp $SOURCE_BASE_PATH/configure_start_auto_tests* $AUTO_TEST_SCRIPT_FILES/. +#cp $SOURCE_BASE_PATH/config.properties $AUTO_TEST_SCRIPT_FILES/. +#cp -rf $SOURCE_BASE_PATH/ant $AUTO_TEST_SCRIPT_FILES/. + +cd $AUTO_TEST_SCRIPT_FILES +./configure_start_auto_tests.sh diff --git a/makefile/auto_tests/install_properties.txt b/makefile/auto_tests/install_properties.txt new file mode 100644 index 0000000..a8f6fef --- /dev/null +++ b/makefile/auto_tests/install_properties.txt @@ -0,0 +1,14 @@ +<?xml version="1.0" encoding="UTF-8" standalone="no"?> +<AutomatedInstallation langpack="eng"> + <com.izforge.izpack.panels.TargetPanel id="targetpanel"> + <installpath>MOTODEV_INSTALLATION_PATH</installpath> + </com.izforge.izpack.panels.TargetPanel> +<com.izforge.izpack.panels.PacksPanel id="packspanel"> +<pack index="0" name="MOTODEV Studio for Android" selected="true"/> +</com.izforge.izpack.panels.PacksPanel> +<com.izforge.izpack.panels.SummaryPanel id="summarypanel"/> +<com.izforge.izpack.panels.InstallPanel id="installpanel"/> +<com.izforge.izpack.panels.ShortcutPanel id="shortcutpanel"> +<programGroup name="MOTODEV Studio for Android"/> +</com.izforge.izpack.panels.ShortcutPanel> +</AutomatedInstallation> diff --git a/makefile/autotest.sh b/makefile/autotest.sh new file mode 100644 index 0000000..3f597c7 --- /dev/null +++ b/makefile/autotest.sh @@ -0,0 +1,31 @@ +#!/bin/bash +# Run automated tests +installer=`ls /android/4.1.0/output/output/MOTODEV_Application_Validator_* | grep linux.gtk` +if [ $? -lt 1 ] +then +echo [Autotest] Installer found +else +echo [Autotest] Installer not found, exiting +exit 1 +fi + +# Step 1: Copy and extract AppValidator installation +cp $installer /android/tests/AppValidator_install/. +cd /android/tests/AppValidator_install/ +tar -xvf $installer +#rm $installer +if [ ! -e "MOTODEV_App_Validator/appvalidator.sh" ] +then +echo [Autotest] Error during untar, please check +exit 1 +fi + +#Step 2: Copy the correct results to compare +cp -a /android/tests/correct-output/* /android/4.1.0/env/code/android/autotester/appvalidator/AutomatedTests/correct-output/. + +# Step 3: Run all tests and compare the results +perl /android/4.1.0/env/code/android/autotester/appvalidator/AutomatedTests/AppTester.pl -runMultiAndCompare + +# Step 4: Copy results to tests folder +cd /android/4.1.0/env/code/android/autotester/appvalidator/AutomatedTests/zip-outputs +cp `ls -t *.zip | head -n1` /android/tests/results/.
\ No newline at end of file diff --git a/makefile/build.properties b/makefile/build.properties new file mode 100644 index 0000000..b7fcb9b --- /dev/null +++ b/makefile/build.properties @@ -0,0 +1,290 @@ +############################################################################### +# Copyright (c) 2003, 2006 IBM Corporation and others. +# All rights reserved. This program and the accompanying materials +# are made available under the terms of the Eclipse Public License v1.0 +# which accompanies this distribution, and is available at +# http://www.eclipse.org/legal/epl-v10.html +# +# Contributors: +# IBM Corporation - initial API and implementation +############################################################################### +build.compiler=org.eclipse.jdt.core.JDTCompilerAdapter +###################### +# Build Properties from legacy build +###################### + +ADT_JAR_FILENAME = com.android.ide.eclipse.adt_20.0.2.v201207191942-407447 +DDMS_JAR_FILENAME = com.android.ide.eclipse.ddms_20.0.2.v201207191942-407447 + +STUDIO_ROOT_BINARY = com.motorola.studio.android.android_root + +SIGNTOOL = ${BASE_DIR}/env/osslsigncode +AUTHENTICODE_KEY = ${INPUT_DIR}/sign/MOTODEV_Studio_Authenticode_USMOTOX214.pvk + +##################### +# Parameters describing how and where to execute the build. +# Typical users need only update the following properties: +# baseLocation - where things you are building against are installed +# bootclasspath - The base jars to compile against (typicaly rt.jar) +# configs - the list of {os, ws, arch} configurations to build. +# +# Of course any of the settings here can be overridden by spec'ing +# them on the command line (e.g., -DbaseLocation=d:/eclipse + +#The type of the top level element we are building, generally "feature" +topLevelElementType = feature +#The id of the top level element we are building +topLevelElementId = com.motorola.studio.android.feature + +############# PRODUCT/PACKAGING CONTROL ############# +#product=${buildDirectory}/plugins/product/studio_android.product +runPackager=true + +#some more variables defined from p2 publisher +#http://wiki.eclipse.org/Equinox/p2/Publisher +generate.p2.metadata = true +p2.repo.dir=${buildDirectory}/distRepo +p2.metadata.repo=file:${p2.repo.dir} +p2.artifact.repo=file:${p2.repo.dir} +p2.metadata.repo.name=MOTODEV Studio for Android Metadata Repository +p2.artifact.repo.name=MOTODEV Studio for Android Artifact Repository +p2.build.dir=${buildDirectory}/buildRepo +p2.build.repo=file:${p2.build.dir} +p2.director.profile=MOTODEV_Profile_Android +p2.category.site=file:${buildDirectory}/site.xml +p2.flavor=tooling +p2.append=true +p2.gathering=true +skipDirector=true +skipMirroring=true + + +#Set the name of the archive that will result from the product build. +archiveNamePrefix=StudioAndroid + +# The prefix that will be used in the generated archive. +archivePrefix=studio_android + +# The location underwhich all of the build output will be collected. +collectingFolder=${archivePrefix} + +# The list of {os, ws, arch} configurations to build. This +# value is a '&' separated list of ',' separate triples. For example, +# configs=win32,win32,x86 & linux,motif,x86 +# By default the value is *,*,* +#configs = *, *, * +#configs=win32, win32, x86 & \ +# win32,win32,x86_64 & \ +# win32,win32,wpf & \ +# linux, gtk, ppc & \ +# linux, gtk, x86 & \ +# linux, gtk, x86_64 & \ +# linux, motif, x86 & \ +# solaris, motif, sparc & \ +# solaris, gtk, sparc & \ +# aix, motif, ppc & \ +# hpux, motif, ia64_32 & \ +# macosx, carbon, ppc & \ +# macosx, carbon, x86 & \ +# macosx, cocoa, ppc & \ +# macosx, cocoa, x86 & \ +# macosx, cocoa, x86_64 +configs=win32, win32, x86 & \ + win32,win32,x86_64 & \ + linux, gtk, x86 & \ + linux, gtk, x86_64 & \ + macosx, cocoa, x86 & \ + macosx, cocoa, x86_64 + +# By default PDE creates one archive (result) per entry listed in the configs property. +# Setting this value to true will cause PDE to only create one output containing all +# artifacts for all the platforms listed in the configs property. +# To control the output format for the group, add a "group, group, group - <format>" entry to the +# archivesFormat. +#groupConfigurations=true + +#The format of the archive. By default a zip is created using antZip. +#The list can only contain the configuration for which the desired format is different than zip. +#archivesFormat=win32, win32, x86 - antZip& \ +# linux, gtk, ppc - antZip &\ +# linux, gtk, x86 - antZip& \ +# linux, gtk, x86_64 - antZip& \ +# linux, motif, x86 - antZip& \ +# solaris, motif, sparc - antZip& \ +# solaris, gtk, sparc - antZip& \ +# aix, motif, ppc - antZip& \ +# hpux, motif, PA_RISC - antZip& \ +# macosx, carbon, ppc - antZip + +#Allow cycles involving at most one bundle that needs to be compiled with the rest being binary bundles. +allowBinaryCycles = true + +#Sort bundles depenedencies across all features instead of just within a given feature. +#flattenDependencies = true + +#Parallel compilation, requires flattenedDependencies=true +#parallelCompilation=true +#parallelThreadCount= +#parallelThreadsPerProcessor= + +#Set to true if you want the output to be ready for an update jar (no site.xml generated) +#outputUpdateJars = false + +#Set to true for Jnlp generation +#codebase should be a URL that will be used as the root of all relative URLs in the output. +#generateJnlp=false +#jnlp.codebase=<codebase url> +#jnlp.j2se=<j2se version> +#jnlp.locale=<a locale> +#jnlp.generateOfflineAllowed=true or false generate <offlineAllowed/> attribute in the generated features +#jnlp.configs=${configs} #uncomment to filter the content of the generated jnlp files based on the configuration being built + +#Set to true if you want to sign jars +#signJars=true +#sign.alias=motodev +#sign.keystore=${motodev.keystore} +#sign.storepass=${motodev.storepass} +#sign.keypass=${motodev.keypass} + +#Arguments to send to the zip executable +zipargs= + +#Arguments to send to the tar executable +tarargs= + +#Control the creation of a file containing the version included in each configuration - on by default +#generateVersionsLists=false + +############## BUILD NAMING CONTROL ################ +# The directory into which the build elements are fetched and where +# the build takes place. +#buildDirectory=/tmp/android_build_220 + +# Type of build. Used in naming the build output. Typically this value is +# one of I, N, M, S, ... +buildType= + +# ID of the build. Used in naming the build output. +buildId=dist + +# Label for the build. Used in naming the build output +buildLabel=${buildId} + +#The value to be used for the qualifier of a plugin or feature when you want to override the value computed by pde. +#The value will only be applied to plugin or features indicating build.properties, qualifier = context +#forceContextQualifier=${forceContextQualifier} + +#Enable / disable the generation of a suffix for the features that use .qualifier. +#The generated suffix is computed according to the content of the feature +#generateFeatureVersionSuffix=true + +############# BASE CONTROL ############# +# Settings for the base Eclipse components and Java class libraries +# against which you are building. +# Base location for anything the build needs to compile against. For example, +# in most RCP app or a plug-in, the baseLocation should be the location of a previously +# installed Eclipse against which the application or plug-in code will be compiled and the RCP delta pack. + +base=${BASE_DIR} +#baseLocation=${base}/env/eclipse + +#Folder containing repositories whose content is needed to compile against +#repoBaseLocation=${REPOSITORIES_DIR} +#Folder where the content of the repositories from ${repoBaseLocation} will be made available as a form suitable to be compiled against +#transformedRepoLocation=${INPUT_DIR}/transformedRepos + +#Os/Ws/Arch/nl of the eclipse specified by baseLocation +baseos=linux +basews=gtk +basearch=x86_64 + +#this property indicates whether you want the set of plug-ins and features to be considered during the build to be limited to the ones reachable from the features / plugins being built +filteredDependencyCheck=false + +#this property indicates whether the resolution should be done in development mode (i.e. ignore multiple bundles with singletons) +resolution.devMode=false + +#pluginPath is a list of locations in which to find plugins and features. This list is separated by the platform file separator (; or :) +#a location is one of: +#- the location of the jar or folder that is the plugin or feature : /path/to/foo.jar or /path/to/foo +#- a directory that contains a /plugins or /features subdirectory +#- the location of a feature.xml, or for 2.1 style plugins, the plugin.xml or fragment.xml +#pluginPath=${REPOSITORIES_TO_USE} + +skipBase=true +eclipseURL=<url for eclipse download site> +eclipseBuildId=<Id of Eclipse build to get> +eclipseBaseURL=${eclipseURL}/eclipse-platform-${eclipseBuildId}-win32.zip + + +############# MAP FILE CONTROL ################ +# This section defines CVS tags to use when fetching the map files from the repository. +# If you want to fetch the map file from repository / location, change the getMapFiles target in the customTargets.xml + +skipMaps=true +mapsRepo=:pserver:anonymous@example.com/path/to/repo +mapsRoot=path/to/maps +mapsCheckoutTag=HEAD + +#tagMaps=true +mapsTagTag=v${buildId} + + +############ REPOSITORY CONTROL ############### +# This section defines properties parameterizing the repositories where plugins, fragments +# bundles and features are being obtained from. + +# The tags to use when fetching elements to build. +# By default thebuilder will use whatever is in the maps. +# This value takes the form of a comma separated list of repository identifier (like used in the map files) and the +# overriding value +# For example fetchTag=CVS=HEAD, SVN=v20050101 +# fetchTag=HEAD +skipFetch=true + + +############# JAVA COMPILER OPTIONS ############## +# The location of the Java jars to compile against. Typically the rt.jar for your JDK/JRE +#bootclasspath=${java.home}/lib/rt.jar + +# specific JRE locations to compile against. These values are used to compile bundles specifying a +# Bundle-RequiredExecutionEnvironment. Uncomment and set values for environments that you support +#CDC-1.0/Foundation-1.0= /path/to/rt.jar +#CDC-1.1/Foundation-1.1= +#OSGi/Minimum-1.0= +#OSGi/Minimum-1.1= +#JRE-1.1= +#J2SE-1.2= +#J2SE-1.3= +#J2SE-1.4= +#J2SE-1.5= +#JavaSE-1.6= +#PersonalJava-1.1= +#PersonalJava-1.2= +#CDC-1.0/PersonalBasis-1.0= +#CDC-1.0/PersonalJava-1.0= +#CDC-1.1/PersonalBasis-1.1= +#CDC-1.1/PersonalJava-1.1= + +# Specify the output format of the compiler log when eclipse jdt is used +logExtension=.log + +# Whether or not to include debug info in the output jars +javacDebugInfo=true + +# Whether or not to fail the build if there are compiler errors +javacFailOnError=true + +# Enable or disable verbose mode of the compiler +javacVerbose=true + +# Extra arguments for the compiler. These are specific to the java compiler being used. +#compilerArg= + +# Default value for the version of the source code. This value is used when compiling plug-ins that do not set the Bundle-RequiredExecutionEnvironment or set javacSource in build.properties +javacSource=1.6 + +# Default value for the version of the byte code targeted. This value is used when compiling plug-ins that do not set the Bundle-RequiredExecutionEnvironment or set javacTarget in build.properties. +javacTarget=1.6 + + diff --git a/makefile/build_server_structure.txt b/makefile/build_server_structure.txt new file mode 100644 index 0000000..26fc5f1 --- /dev/null +++ b/makefile/build_server_structure.txt @@ -0,0 +1,25 @@ +.
+./<version>
+./<version>/env
+./<version>/env/ant-contrib
+./<version>/env/code
+./<version>/env/eclipse
+./<version>/input
+./<version>/input/repository
+./<version>/input/repository/base
+./<version>/input/repository/base/REPO_ADT
+./<version>/input/repository/base/REPO_BIRT
+./<version>/input/repository/base/REPO_DATATOOLS
+./<version>/input/repository/base/REPO_ECLIPSE_PLATFORM
+./<version>/input/repository/base/REPO_EMF_XSD_SDO
+./<version>/input/repository/base/REPO_EQUINOX
+./<version>/input/repository/base/REPO_GEF
+./<version>/input/repository/base/REPO_JDT
+./<version>/input/repository/base/REPO_MAT
+./<version>/input/repository/base/REPO_MPC
+./<version>/input/repository/base/REPO_PDE
+./<version>/input/repository/base/REPO_PROGUARD
+./<version>/input/repository/base/REPO_RSS
+./<version>/input/repository/base/REPO_SEQUOYAH
+./<version>/input/repository/base/REPO_WTP
+./<version>/input/repository/transformedRepos
\ No newline at end of file diff --git a/makefile/config.xml b/makefile/config.xml new file mode 100644 index 0000000..7a7413f --- /dev/null +++ b/makefile/config.xml @@ -0,0 +1,63 @@ +<?xml version="1.0" encoding="UTF-8"?> + +<cruisecontrol> + +<!-- +######################################################### +############## ONLY MODIFY THESE PROPERTIES ############# +#########################################################--> + + <property name="project_name" value="Android-5.0.0" /> + <property name="path_name" value="5.0.0" /> +<!-- +######################################################### +######################################################### +--> + + <project name="${project_name}" buildafterfailed="true"> + + <listeners> + <currentbuildstatuslistener + file="/android/${path_name}/logs/${project_name}/status.txt"/> + </listeners> + + <bootstrappers> + <execbootstrapper command="sh" args="git_update.sh" workingdir="/android/${path_name}/env/code/android/makefile/scripts/"/> + </bootstrappers> + + <!-- Defines where cruise looks for changes, to decide whether to run the build --> + <modificationset quietperiod="300"> + <git LocalWorkingCopy="/android/${path_name}/env/code/" /> + </modificationset> + + <!-- Configures the build loop, how often and which build file/target --> + <schedule interval="900"> + <ant antscript="/android/${path_name}/env/code/android/makefile/eant" buildfile="/android/${path_name}/env/code/android/makefile/studioBuild.xml"/> + </schedule> + + <!-- directory to write build logs to --> + <log dir="/android/${path_name}/logs/${project_name}"> + <delete unit="WEEK" + every="2" + ignoreSuffix="true"/> + </log> + + <!-- Publishers are run *after* a build completes --> + <publishers> + <artifactspublisher dest="/android/${path_name}/logs/${project_name}" dir="/android/${path_name}/output/output"/> + <htmlemail mailhost="serv070.corp.eldorado.org.br" + returnaddress="android.noreply@serv167.corp.eldorado.org.br" + buildresultsurl="http://192.168.4.167:8080/dashboard/tab/build/detail/${project_name}" + skipusers="true" spamWhileBroken="false" + css="/android/${path_name}/env/cruisecontrol-bin-2.8.4/webapps/cruisecontrol/css/cruisecontrol.css" + xsldir="/android/${path_name}/env/cruisecontrol-bin-2.8.4/webapps/cruisecontrol/xsl" + subjectprefix="Build Android -"> + <always address="daniel.pastore@eldorado.org.br"/> + <always address="julia.perdigueiro@eldorado.org.br" /> + <success address="pablo.leite@eldorado.org.br"/> + <success address="paulo.faria@eldorado.org.br"/> + </htmlemail> + </publishers> + </project> + +</cruisecontrol> diff --git a/makefile/customTargets.xml b/makefile/customTargets.xml new file mode 100644 index 0000000..552af30 --- /dev/null +++ b/makefile/customTargets.xml @@ -0,0 +1,282 @@ +<project name="Build specific targets and properties" default="noDefault"> + <target name="createSiteXML"> + <echoxml file="${buildDirectory}/site.xml"> + <site> + <feature url="features/${studioFeatureName}.${studioFeatureVersion}.jar" id="${studioFeatureName}" version="${studioFeatureVersion}"> + <category name="MOTODEVStudioforAndroid" /> + </feature> + <category-def name="MOTODEVStudioforAndroid" label="MOTODEV Studio for Android" /> + </site> + </echoxml> + </target> + + <target name="init"> + <copy todir="${buildDirectory}"> + <fileset dir="${SOURCE_DIR}/" includes="**/**" /> + </copy> + <move file="${buildDirectory}/features/feature" tofile="${buildDirectory}/features/com.motorola.studio.android.feature" /> + <move file="${buildDirectory}/features/basic" tofile="${buildDirectory}/features/basic.feature" /> + </target> + + <target name="setTimeStamp"> + <echo message="1=${timestamp}" file="${buildDirectory}/plugins/product/about.mappings" append="true" /> + <replace file="${buildDirectory}/plugins/product/about.mappings" token="@studioversion@" value="${studioVersion}" /> + <echo message="1=${timestamp}" file="${buildDirectory}/plugins/common/about.mappings" append="true" /> + <replace file="${buildDirectory}/plugins/common/about.mappings" token="@studioversion@" value="${studioVersion}" /> + </target> + + <!-- ===================================================================== --> + <!-- Run a given ${target} on all elements being built --> + <!-- Add on <ant> task for each top level element being built. --> + <!-- ===================================================================== --> + <available property="allElementsFile" file="${builder}/allElements.xml" value="${builder}/allElements.xml" /> + <property name="allElementsFile" location="${eclipse.pdebuild.templates}/headless-build/allElements.xml" /> + + <import file="${allElementsFile}" /> + <target name="allElements"> + <antcall target="allElementsDelegator" /> + </target> + + <!-- ===================================================================== --> + <!-- ===================================================================== --> + <target name="getBaseComponents" depends="checkLocalBase" unless="skipBase"> + <get src="${eclipseBaseURL}" dest="${buildDirectory}/../temp-base.zip" /> + <unzip dest="${base}" overwrite="true" src="${buildDirectory}/../temp-base.zip" /> + </target> + + <target name="checkLocalBase"> + <available file="${base}" property="skipBase" /> + </target> + + <!-- ===================================================================== --> + <!-- Check out map files from correct repository --> + <!-- Replace values for mapsCheckoutTag as desired. --> + <!-- ===================================================================== --> + <target name="getMapFiles" depends="checkLocalMaps" unless="skipMaps"> + <property name="mapsCheckoutTag" value="HEAD" /> + <cvs cvsRoot="${mapsRepo}" package="${mapsRoot}" dest="${buildDirectory}/maps" tag="${mapsCheckoutTag}" /> + </target> + + <target name="checkLocalMaps"> + <available property="skipMaps" file="${buildDirectory}/maps" /> + </target> + + <target name="tagMapFiles" if="tagMaps"> + <cvs dest="${buildDirectory}/maps/${mapsRoot}" command="tag ${mapsTagTag}" /> + </target> + + <!-- ===================================================================== --> + + <target name="clean" unless="noclean"> + <antcall target="allElements"> + <param name="target" value="cleanElement" /> + </antcall> + </target> + + <target name="gatherLogs"> + <mkdir dir="${buildDirectory}/${buildLabel}/compilelogs" /> + <antcall target="allElements"> + <param name="target" value="gatherLogs" /> + </antcall> + <unzip dest="${buildDirectory}/${buildLabel}/compilelogs" overwrite="true"> + <fileset dir="${buildDirectory}/features"> + <include name="**/*.log.zip" /> + </fileset> + </unzip> + </target> + + <!-- ===================================================================== --> + <!-- Steps to do before setup --> + <!-- ===================================================================== --> + <target name="preSetup"> + <antcall target="init" /> + <!-- Copy studio_android.product and plugin.properties to the build folder --> + <antcall target="setTimeStamp" /> + <antcall target="createSiteXML" /> + </target> + + <!-- ===================================================================== --> + <!-- Steps to do after setup but before starting the build proper --> + <!-- ===================================================================== --> + <target name="postSetup"> + <antcall target="getBaseComponents" /> + </target> + + <!-- ===================================================================== --> + <!-- Steps to do before fetching the build elements --> + <!-- ===================================================================== --> + <target name="preFetch"> + </target> + + <!-- ===================================================================== --> + <!-- Steps to do after fetching the build elements --> + <!-- ===================================================================== --> + <target name="postFetch"> + </target> + + <!-- ===================================================================== --> + <!-- Steps to do before the repositories are being processed --> + <!-- ===================================================================== --> + <target name="preProcessRepos"> + </target> + + <!-- ===================================================================== --> + <!-- Steps to do after the repositories have been processed --> + <!-- ===================================================================== --> + <target name="postProcessRepos"> + </target> + + <!-- ===================================================================== --> + <!-- Steps to do before generating the build scripts. --> + <!-- ===================================================================== --> + <target name="preGenerate"> + <mkdir dir="${buildDirectory}/tmp/plugins" /> + <copy todir="${buildDirectory}/tmp/plugins"> + <fileset dir="${GIT_REPOSITORY_PATH}/android/docs/manuals/" includes="*.jar" /> + </copy> + <p2.generator append="true" source="${buildDirectory}/tmp/" artifactrepository="file:${transformedRepoLocation}" metadatarepository="file:${transformedRepoLocation}" publishartifacts="true" /> + + <delete dir="${transformedRepoLocation}/plugins/${ADT_JAR_FILENAME}/" /> + <copy overwrite="true" file="${BASE_REPOSITORIES_DIR}/REPO_ADT/plugins/${ADT_JAR_FILENAME}.jar" todir="${transformedRepoLocation}/plugins/" /> + <unzip src="${transformedRepoLocation}/plugins/${ADT_JAR_FILENAME}.jar" dest="${transformedRepoLocation}/plugins/${ADT_JAR_FILENAME}/" /> + <delete file="${transformedRepoLocation}/plugins/${ADT_JAR_FILENAME}.jar" /> + + <delete dir="${transformedRepoLocation}/plugins/${DDMS_JAR_FILENAME}/" /> + <copy overwrite="true" file="${BASE_REPOSITORIES_DIR}/REPO_ADT/plugins/${DDMS_JAR_FILENAME}.jar" todir="${transformedRepoLocation}/plugins/" /> + <unzip src="${transformedRepoLocation}/plugins/${DDMS_JAR_FILENAME}.jar" dest="${transformedRepoLocation}/plugins/${DDMS_JAR_FILENAME}/" /> + <delete file="${transformedRepoLocation}/plugins/${DDMS_JAR_FILENAME}.jar" /> + + </target> + + <!-- ===================================================================== --> + <!-- Steps to do after generating the build scripts. --> + <!-- ===================================================================== --> + <target name="postGenerate"> + <antcall target="clean" /> + </target> + + <!-- ===================================================================== --> + <!-- Steps to do before running the build.xmls for the elements being built. --> + <!-- ===================================================================== --> + <target name="preProcess"> + </target> + + <!-- ===================================================================== --> + <!-- Steps to do after running the build.xmls for the elements being built. --> + <!-- ===================================================================== --> + <target name="postProcess"> + <jar basedir="${transformedRepoLocation}/plugins/${ADT_JAR_FILENAME}/" destfile="${transformedRepoLocation}/plugins/${ADT_JAR_FILENAME}.jar" /> + <delete dir="${transformedRepoLocation}/plugins/${ADT_JAR_FILENAME}/" /> + <jar basedir="${transformedRepoLocation}/plugins/${DDMS_JAR_FILENAME}/" destfile="${transformedRepoLocation}/plugins/${DDMS_JAR_FILENAME}.jar" /> + <delete dir="${transformedRepoLocation}/plugins/${DDMS_JAR_FILENAME}/" /> + </target> + + + <!-- ===================================================================== --> + <!-- Steps to do before running assemble. --> + <!-- ===================================================================== --> + <target name="preAssemble"> + </target> + + <!-- ===================================================================== --> + <!-- Steps to do after running assemble. --> + <!-- ===================================================================== --> + <target name="postAssemble"> + </target> + + + <!-- ===================================================================== --> + <!-- Steps to do before running package. --> + <!-- ===================================================================== --> + <target name="prePackage"> + </target> + + <!-- ===================================================================== --> + <!-- Steps to do after running package. --> + <!-- ===================================================================== --> + <target name="postPackage"> + </target> + + <!-- ===================================================================== --> + <!-- Steps to do after the build is done. --> + <!-- ===================================================================== --> + <target name="postBuild"> + <antcall target="gatherLogs" /> + <!-- ================================= + Mirror the build repo to the repository output folder (excluding exceeding packages) + ================================= --> + <mkdir dir="${p2.repo.dir}"/> + <copy todir="${p2.repo.dir}" file="${MAKEFILE}/repository_skel/content.xml"/> + + <!-- p2.mirror source="${p2.build.dir}" destination="${p2.artifact.repo}" raw="false"> + <iu id="com.motorola.studio.android.feature.feature.group" /> + <slicingoptions followstrict="true" includeoptional="false" includenongreedy="false" followonlyfilteredrequirements="true" includefeatures="true" /> + </p2.mirror --> + + <eclipse.publish.featuresAndBundles append="true" artifactrepository="${p2.artifact.repo}" + artifactrepositoryname="${p2.artifact.repo.name}" metadatarepository="${p2.metadata.repo}" + metadatarepositoryname="${p2.metadata.repo.name}" site="${p2.category.site}"> + <features dir="${p2.build.dir}" includes="features/com.motorola.studio.android.*" /> + <bundles dir="${p2.build.dir}" includes="plugins/com.motorola.studio.android*" /> + <bundles dir="${p2.build.dir}" includes="plugins/com.motorolamobility.studio.android*" /> + </eclipse.publish.featuresAndBundles> + + <!-- Remove equinox launcher artifacts from our repository --> + <p2.remove.iu> + <repository location="${p2.artifact.repo}"/> + <iu id="org.eclipse.equinox.launcher.gtk.linux.x86_64"/> + <iu id="org.eclipse.equinox.launcher.gtk.linux.x86"/> + <iu id="org.eclipse.equinox.launcher.win32.win32.x86_64"/> + <iu id="org.eclipse.equinox.launcher.win32.win32.x86"/> + <iu id="org.eclipse.equinox.launcher.cocoa.macosx"/> + <iu id="org.eclipse.equinox.launcher.cocoa.macosx.x86_64"/> + </p2.remove.iu> + + + <!-- categorize the repository --> + <java failonerror="true" jar="${eclipse.builder.path}/plugins/${eclipse.builder.launcher}" fork="true"> + <arg value="-application" /> + <arg value="org.eclipse.equinox.p2.publisher.CategoryPublisher" /> + <arg value="-metadataRepository" /> + <arg value="${p2.artifact.repo}" /> + <arg value="-categoryDefinition" /> + <arg value="file:/${buildDirectory}/site.xml" /> + </java> + + <!-- antcall target="signStudio" / --> + + <copy todir="${outputDirectory}"> + <fileset dir="${p2.repo.dir}" includes="**/**" /> + </copy> + + </target> + + <!-- target name="signStudio" if="motodev.keypass"> + <p2.process.artifacts repositorypath="${p2.artifact.repo}"> + <sign keystore="${motodev.keystore}" alias="motodev" keypass="${motodev.keypass}" storepass="${motodev.storepass}" /> + </p2.process.artifacts> + </target --> + + <!-- ===================================================================== --> + <!-- Steps to do to test the build results --> + <!-- ===================================================================== --> + <target name="test"> + <echo level="info" message="Studio Build Custom Targets Test"/> + <!-- exec executable="autotest.sh" output="/android/tests/autotest_output.log"/ --> + </target> + + <!-- ===================================================================== --> + <!-- Steps to do to publish the build results --> + <!-- ===================================================================== --> + <target name="publish"> + </target> + + + <!-- ===================================================================== --> + <!-- Default target --> + <!-- ===================================================================== --> + <target name="noDefault"> + <echo message="You must specify a target when invoking this file" /> + </target> + +</project> diff --git a/makefile/eant b/makefile/eant new file mode 100644 index 0000000..d97f35f --- /dev/null +++ b/makefile/eant @@ -0,0 +1,17 @@ +#!/bin/bash +# Run Ant with the configuration above +export BUILD_BASE_PATH=/android/5.0.0 + +#uncomment to create dev releases (qualifier is the build date) +#export DEV_RELEASE=true + +#[2012.03.03] Forcing git to update +#Investigate later if bootstraper from config.xml is being used +echo Forcing git to update +chmod 0777 $BUILD_BASE_PATH/env/code/android/makefile/scripts/git_update.sh +$BUILD_BASE_PATH/env/code/android/makefile/scripts/git_update.sh + +$BUILD_BASE_PATH/env/eclipse/eclipse -nosplash -application org.eclipse.ant.core.antRunner -data $BUILD_BASE_PATH/env/workspace_product -buildfile $BUILD_BASE_PATH/env/code/android/makefile/studioBuild.xml -logger org.apache.tools.ant.XmlLogger -logfile $BUILD_BASE_PATH/log.xml + + + diff --git a/makefile/preflighting/build.properties b/makefile/preflighting/build.properties new file mode 100644 index 0000000..ecf9b4c --- /dev/null +++ b/makefile/preflighting/build.properties @@ -0,0 +1,275 @@ +############################################################################### +# Copyright (c) 2003, 2009 IBM Corporation and others. +# All rights reserved. This program and the accompanying materials +# are made available under the terms of the Eclipse Public License v1.0 +# which accompanies this distribution, and is available at +# http://www.eclipse.org/legal/epl-v10.html +# +# Contributors: +# IBM Corporation - initial API and implementation +############################################################################### + +p2.gathering = true +p2.build.repo = file:${buildDirectory}/buildRepo +p2.metadata.repo.name = MOTODEV Studio Application Validator +p2.artifact.repo.name = MOTODEV Studio Application Validator +p2.category.site = file:${buildDirectory}/site.xml +skipDirector=true +skipMirroring=true + +#generatedBuildProperties = ${buildDirectory}/root.properties + +##################### +# App Validator Javadoc properties + +appValidatorSourceCodeDirectories = ${buildDirectory}/plugins/preflighting.core/src;${buildDirectory}/plugins/preflighting/src +javadocOutputDirectory=${buildDirectory}/plugins/preflighting.sdk/doc +appValidatorJavaAPIURLDirectory = http://download.oracle.com/javase/1.5.0/docs/api/ +appValidatorExcludedPackages = **.internal.*, **.i18n** + +##################### +# Parameters describing how and where to execute the build. +# Typical users need only update the following properties: +# baseLocation - where things you are building against are installed +# bootclasspath - The base jars to compile against (typicaly rt.jar) +# configs - the list of {os, ws, arch} configurations to build. +# +# Of course any of the settings here can be overridden by spec'ing +# them on the command line (e.g., -DbaseLocation=d:/eclipse + +#The type of the top level element we are building, generally "feature" +topLevelElementType = feature +#The id of the top level element we are building +topLevelElementId = com.motorolamobility.preflighting.ui.feature +featureList = com.motorolamobility.preflighting.feature + +############# PRODUCT/PACKAGING CONTROL ############# +product = ${GIT_REPOSITORY_PATH}/android/makefile/preflighting/preflighting.product +runPackager=true + +#Set the name of the archive that will result from the product build. +#archiveNamePrefix= + +# The prefix that will be used in the generated archive. +archivePrefix=preflighting + +# The location underwhich all of the build output will be collected. +collectingFolder=${archivePrefix} + +# The list of {os, ws, arch} configurations to build. This +# value is a '&' separated list of ',' separate triples. For example, +# configs=win32,win32,x86 & linux,motif,x86 +# By default the value is *,*,* +configs = *, *, * +#configs=win32, win32, x86 & \ +# win32,win32,x86_64 & \ +# win32,win32,wpf & \ +# linux, gtk, ppc & \ +# linux, gtk, x86 & \ +# linux, gtk, x86_64 & \ +# linux, motif, x86 & \ +# solaris, motif, sparc & \ +# solaris, gtk, sparc & \ +# aix, motif, ppc & \ +# hpux, motif, ia64_32 & \ +# macosx, carbon, ppc & \ +# macosx, carbon, x86 & \ +# macosx, cocoa, ppc & \ +# macosx, cocoa, x86 & \ +# macosx, cocoa, x86_64 + +# By default PDE creates one archive (result) per entry listed in the configs property. +# Setting this value to true will cause PDE to only create one output containing all +# artifacts for all the platforms listed in the configs property. +# To control the output format for the group, add a "group, group, group - <format>" entry to the +# archivesFormat. +#groupConfigurations=true + +#The format of the archive. By default a zip is created using antZip. +#The list can only contain the configuration for which the desired format is different than zip. +#archivesFormat=win32, win32, x86 - antZip& \ +# linux, gtk, ppc - antZip &\ +# linux, gtk, x86 - antZip& \ +# linux, gtk, x86_64 - antZip& \ +# linux, motif, x86 - antZip& \ +# solaris, motif, sparc - antZip& \ +# solaris, gtk, sparc - antZip& \ +# aix, motif, ppc - antZip& \ +# hpux, motif, PA_RISC - antZip& \ +# macosx, carbon, ppc - antZip + +#Allow cycles involving at most one bundle that needs to be compiled with the rest being binary bundles. +allowBinaryCycles = true + +#Sort bundles depenedencies across all features instead of just within a given feature. +#flattenDependencies = true + +#Parallel compilation, requires flattenedDependencies=true +#parallelCompilation=true +#parallelThreadCount= +#parallelThreadsPerProcessor= + +#Set to true if you want the output to be ready for an update jar (no site.xml generated) +#outputUpdateJars = false + +#Set to true for Jnlp generation +#codebase should be a URL that will be used as the root of all relative URLs in the output. +#generateJnlp=false +#jnlp.codebase=<codebase url> +#jnlp.j2se=<j2se version> +#jnlp.locale=<a locale> +#jnlp.generateOfflineAllowed=true or false generate <offlineAllowed/> attribute in the generated features +#jnlp.configs=${configs} #uncomment to filter the content of the generated jnlp files based on the configuration being built + +#Set to true if you want to sign jars +#signJars=false +#sign.alias=<alias> +#sign.keystore=<keystore location> +#sign.storepass=<keystore password> +#sign.keypass=<key password> + +#Arguments to send to the zip executable +zipargs= + +#Arguments to send to the tar executable +tarargs= + +#Control the creation of a file containing the version included in each configuration - on by default +#generateVersionsLists=false + +############## BUILD NAMING CONTROL ################ +# The directory into which the build elements are fetched and where +# the build takes place. +#buildDirectory=/tmp/appvalidatorbuild071 + +# Type of build. Used in naming the build output. Typically this value is +# one of I, N, M, S, ... +buildType=I + +# ID of the build. Used in naming the build output. +buildId=TestBuild + +# Label for the build. Used in naming the build output +buildLabel=${buildType}.${buildId} + +# Timestamp for the build. Used in naming the build output +#timestamp=007 + +#The value to be used for the qualifier of a plugin or feature when you want to override the value computed by pde. +#The value will only be applied to plugin or features indicating build.properties, qualifier = context +#forceContextQualifier=<the value for the qualifier> + +#Enable / disable the generation of a suffix for the features that use .qualifier. +#The generated suffix is computed according to the content of the feature +#generateFeatureVersionSuffix=true + +############# BASE CONTROL ############# +# Settings for the base Eclipse components and Java class libraries +# against which you are building. +# Base location for anything the build needs to compile against. For example, +# in most RCP app or a plug-in, the baseLocation should be the location of a previously +# installed Eclipse against which the application or plug-in code will be compiled and the RCP delta pack. + +base=${BASE_DIR} +#baseLocation=${base}/env/eclipse + +#Folder containing repositories whose content is needed to compile against +#repoBaseLocation=${INPUT_DIR}/repository +#Folder where the content of the repositories from ${repoBaseLocation} will be made available as a form suitable to be compiled against +#transformedRepoLocation=${INPUT_DIR}/transformedRepos + +#Os/Ws/Arch/nl of the eclipse specified by baseLocation +baseos=linux +basews=gtk +basearch=x86_64 + +#this property indicates whether you want the set of plug-ins and features to be considered during the build to be limited to the ones reachable from the features / plugins being built +filteredDependencyCheck=false + +#this property indicates whether the resolution should be done in development mode (i.e. ignore multiple bundles with singletons) +resolution.devMode=false + +#pluginPath is a list of locations in which to find plugins and features. This list is separated by the platform file separator (; or :) +#a location is one of: +#- the location of the jar or folder that is the plugin or feature : /path/to/foo.jar or /path/to/foo +#- a directory that contains a /plugins or /features subdirectory +#- the location of a feature.xml, or for 2.1 style plugins, the plugin.xml or fragment.xml +#pluginPath= + +skipBase=true +eclipseURL=<url for eclipse download site> +eclipseBuildId=<Id of Eclipse build to get> +eclipseBaseURL=${eclipseURL}/eclipse-platform-${eclipseBuildId}-win32.zip + + +############# MAP FILE CONTROL ################ +# This section defines CVS tags to use when fetching the map files from the repository. +# If you want to fetch the map file from repository / location, change the getMapFiles target in the customTargets.xml + +skipMaps=true +mapsRepo=:pserver:anonymous@example.com/path/to/repo +mapsRoot=path/to/maps +mapsCheckoutTag=HEAD + +#tagMaps=true +mapsTagTag=v${buildId} + + +############ REPOSITORY CONTROL ############### +# This section defines properties parameterizing the repositories where plugins, fragments +# bundles and features are being obtained from. + +# The tags to use when fetching elements to build. +# By default thebuilder will use whatever is in the maps. +# This value takes the form of a comma separated list of repository identifier (like used in the map files) and the +# overriding value +# For example fetchTag=CVS=HEAD, SVN=v20050101 +# fetchTag=HEAD +skipFetch=true + + +############# JAVA COMPILER OPTIONS ############## +# The location of the Java jars to compile against. Typically the rt.jar for your JDK/JRE +#bootclasspath=${java.home}/lib/rt.jar + +# specific JRE locations to compile against. These values are used to compile bundles specifying a +# Bundle-RequiredExecutionEnvironment. Uncomment and set values for environments that you support +#CDC-1.0/Foundation-1.0= /path/to/rt.jar +#CDC-1.1/Foundation-1.1= +#OSGi/Minimum-1.0= +#OSGi/Minimum-1.1= +#JRE-1.1= +#J2SE-1.2= +#J2SE-1.3= +#J2SE-1.4= +#J2SE-1.5= +#JavaSE-1.6= +#PersonalJava-1.1= +#PersonalJava-1.2= +#CDC-1.0/PersonalBasis-1.0= +#CDC-1.0/PersonalJava-1.0= +#CDC-1.1/PersonalBasis-1.1= +#CDC-1.1/PersonalJava-1.1= + +# Specify the output format of the compiler log when eclipse jdt is used +logExtension=.log + +# Whether or not to include debug info in the output jars +javacDebugInfo=true + +# Whether or not to fail the build if there are compiler errors +javacFailOnError=true + +# Enable or disable verbose mode of the compiler +javacVerbose=true + +# Extra arguments for the compiler. These are specific to the java compiler being used. +#compilerArg= + +# Default value for the version of the source code. This value is used when compiling plug-ins that do not set the Bundle-RequiredExecutionEnvironment or set javacSource in build.properties +javacSource=1.5 + +# Default value for the version of the byte code targeted. This value is used when compiling plug-ins that do not set the Bundle-RequiredExecutionEnvironment or set javacTarget in build.properties. +javacTarget=1.5 + + diff --git a/makefile/preflighting/customTargets.xml b/makefile/preflighting/customTargets.xml new file mode 100644 index 0000000..958fda4 --- /dev/null +++ b/makefile/preflighting/customTargets.xml @@ -0,0 +1,248 @@ +<project name="Build specific targets and properties" default="noDefault"> + + <!-- ===================================================================== --> + <!-- Run a given ${target} on all elements being built --> + <!-- Add on <ant> task for each top level element being built. --> + <!-- ===================================================================== --> + <available property="allElementsFile" file="${builder}/allElements.xml" value="${builder}/allElements.xml" /> + <property name="allElementsFile" location="${eclipse.pdebuild.templates}/headless-build/allElements.xml" /> + + <import file="${allElementsFile}" /> + <target name="allElements"> + <antcall target="allElementsDelegator" /> + </target> + + <!-- ===================================================================== --> + <!-- ===================================================================== --> + <target name="getBaseComponents" depends="checkLocalBase" unless="skipBase"> + <get src="${eclipseBaseURL}" dest="${buildDirectory}/../temp-base.zip" /> + <unzip dest="${base}" overwrite="true" src="${buildDirectory}/../temp-base.zip" /> + </target> + + <target name="checkLocalBase"> + <available file="${base}" property="skipBase" /> + </target> + + <!-- ===================================================================== --> + <!-- Check out map files from correct repository --> + <!-- Replace values for mapsCheckoutTag as desired. --> + <!-- ===================================================================== --> + <target name="getMapFiles" depends="checkLocalMaps" unless="skipMaps"> + <property name="mapsCheckoutTag" value="HEAD" /> + <cvs cvsRoot="${mapsRepo}" package="${mapsRoot}" dest="${buildDirectory}/maps" tag="${mapsCheckoutTag}" /> + </target> + + <target name="checkLocalMaps"> + <available property="skipMaps" file="${buildDirectory}/maps" /> + </target> + + <target name="tagMapFiles" if="tagMaps"> + <cvs dest="${buildDirectory}/maps/${mapsRoot}" command="tag ${mapsTagTag}" /> + </target> + + <!-- ===================================================================== --> + + <target name="clean" unless="noclean"> + <antcall target="allElements"> + <param name="target" value="cleanElement" /> + </antcall> + </target> + + <target name="gatherLogs"> + <mkdir dir="${buildDirectory}/${buildLabel}/compilelogs" /> + <antcall target="allElements"> + <param name="target" value="gatherLogs" /> + </antcall> + <unzip dest="${buildDirectory}/${buildLabel}/compilelogs" overwrite="true"> + <fileset dir="${buildDirectory}/features"> + <include name="**/*.log.zip" /> + </fileset> + </unzip> + </target> + + <!-- ===================================================================== --> + <!-- Steps to do before setup --> + <!-- ===================================================================== --> + <target name="preSetup"> + + <copy todir="${buildDirectory}"> + <fileset dir="${SOURCE_DIR}/" includes="**/preflighting*/**" /> + <fileset dir="${SOURCE_DIR}/" includes="**/common*/**" /> + <fileset dir="${SOURCE_DIR}/" includes="**/logger*/**" /> + </copy> + <echo message="0=${timestamp}" file="${buildDirectory}/plugins/preflighting.core/about.mappings" /> + <echo message="0=${timestamp}" file="${buildDirectory}/plugins/preflighting.ui/about.mappings" /> + <echoxml file="${buildDirectory}/site.xml"> + <site> + <feature url="features/${appValidatorFeatureName}.${appValidatorFeatureVersion}.jar" id="${appValidatorFeatureName}" version="${appValidatorFeatureVersion}"> + <category name="MOTODEVStudioforAndroid" /> + </feature> + <feature url="features/${appValidatorUIFeatureName}.${appValidatorUIFeatureVersion}.jar" id="${appValidatorUIFeatureName}" version="${appValidatorUIFeatureVersion}"> + <category name="MOTODEVStudioforAndroid" /> + </feature> + <feature url="features/${appValidatorSDKFeatureName}.${appValidatorSDKFeatureVersion}.jar" id="${appValidatorSDKFeatureName}" version="${appValidatorSDKFeatureVersion}"> + <category name="MOTODEVStudioforAndroid" /> + </feature> + <category-def name="MOTODEVStudioforAndroid" label="MOTODEV Studio for Android" /> + </site> + </echoxml> + </target> + + <!-- ===================================================================== --> + <!-- Steps to do after setup but before starting the build proper --> + <!-- ===================================================================== --> + <target name="postSetup"> + <antcall target="getBaseComponents" /> + </target> + + <!-- ===================================================================== --> + <!-- Steps to do before fetching the build elements --> + <!-- ===================================================================== --> + <target name="preFetch"> + </target> + + <!-- ===================================================================== --> + <!-- Steps to do after fetching the build elements --> + <!-- ===================================================================== --> + <target name="postFetch"> + </target> + + <!-- ===================================================================== --> + <!-- Steps to do before the repositories are being processed --> + <!-- ===================================================================== --> + <target name="preProcessRepos"> + </target> + + <!-- ===================================================================== --> + <!-- Steps to do after the repositories have been processed --> + <!-- ===================================================================== --> + <target name="postProcessRepos"> + + </target> + + <!-- ===================================================================== --> + <!-- Steps to do before generating the build scripts. --> + <!-- ===================================================================== --> + <target name="preGenerate"> + <ant antfile="${MAKEFILE}/preflighting/javadoc.xml" target="javadoc"> + <property name="sourceCodeDirectories" value="${appValidatorSourceCodeDirectories}" /> + <property name="excludePackages" value="${appValidatorExcludedPackages}" /> + <property name="javadocOutputDirectory" value="${javadocOutputDirectory}" /> + <property name="javaAPIPackageLocationDirectory" value="${MAKEFILE}/preflighting/" /> + <property name="javaAPIURLDirectory" value="${appValidatorJavaAPIURLDirectory}" /> + </ant> + <copy todir="${appValidatorJavadocOutputDirectory}" > + <fileset dir="${javadocOutputDirectory}" /> + </copy> + <mkdir dir="${buildDirectory}/tmp/plugins" /> + <copy todir="${buildDirectory}/tmp/plugins"> + <fileset dir="${GIT_REPOSITORY_PATH}/android/docs/manuals/" includes="*.jar" /> + </copy> + <delete> + <fileset dir="${transformedRepoLocation}" includes="com.motorola*helpbase*" /> + </delete> + <p2.generator append="true" source="${buildDirectory}/tmp/" artifactrepository="file:${transformedRepoLocation}" metadatarepository="file:${transformedRepoLocation}" publishartifacts="true" /> + </target> + + <!-- ===================================================================== --> + <!-- Steps to do after generating the build scripts. --> + <!-- ===================================================================== --> + <target name="postGenerate"> + <antcall target="clean" /> + </target> + + <!-- ===================================================================== --> + <!-- Steps to do before running the build.xmls for the elements being built. --> + <!-- ===================================================================== --> + <target name="preProcess"> + </target> + + <!-- ===================================================================== --> + <!-- Steps to do after running the build.xmls for the elements being built. --> + <!-- ===================================================================== --> + <target name="postProcess"> + </target> + + <!-- ===================================================================== --> + <!-- Steps to do before running assemble. --> + <!-- ===================================================================== --> + <target name="preAssemble"> + <copy todir="${transformedRepoLocation}/plugins" failonerror="false" overwrite="true"> + <fileset dir="${BASE_REPOSITORIES_DIR}/REPO_ADT/plugins/" includes="*.jar" /> + </copy> + <copy todir="${transformedRepoLocation}/features" failonerror="false" overwrite="true"> + <fileset dir="${BASE_REPOSITORIES_DIR}/REPO_ADT/features/" includes="*.jar" /> + </copy> + </target> + + <!-- ===================================================================== --> + <!-- Steps to do after running assemble. --> + <!-- ===================================================================== --> + <target name="postAssemble"> + </target> + + <!-- ===================================================================== --> + <!-- Steps to do before running package. --> + <!-- ===================================================================== --> + <target name="prePackage"> + </target> + + <!-- ===================================================================== --> + <!-- Steps to do after running package. --> + <!-- ===================================================================== --> + <target name="postPackage"> + </target> + + <!-- ===================================================================== --> + <!-- Steps to do after the build is done. --> + <!-- ===================================================================== --> + <target name="postBuild"> + <antcall target="gatherLogs" /> + <p2.mirror destination="file:${outputDirectory}"> + <slicingoptions followstrict="true" /> + <source> + <repository location="${p2.build.repo}" /> + </source> + <iu id="com.motorolamobility.preflighting.ui.feature.feature.group" /> + <iu id="com.motorolamobility.preflighting.sdk.feature.feature.group" /> + <iu id="com.motorolamobility.preflighting.feature.feature.group" /> + </p2.mirror> + <!-- antcall target="signStudio" / --> + <!-- run the category publisher.. there is no ant task to execute it --> + <java failonerror="true" jar="${eclipse.builder.path}/plugins/${eclipse.builder.launcher}" fork="true"> + <arg value="-application" /> + <arg value="org.eclipse.equinox.p2.publisher.CategoryPublisher" /> + <arg value="-metadataRepository" /> + <arg value="file:${outputDirectory}" /> + <arg value="-categoryDefinition" /> + <arg value="file:${buildDirectory}/site.xml" /> + </java> + </target> + + <!-- target name="signStudio" if="motodev.keypass"> + <p2.process.artifacts repositorypath="file:${outputDirectory}"> + <sign keystore="${motodev.keystore}" alias="motodev" keypass="${motodev.keypass}" storepass="${motodev.storepass}" /> + </p2.process.artifacts> + </target --> + + <!-- ===================================================================== --> + <!-- Steps to do to test the build results --> + <!-- ===================================================================== --> + <target name="test"> + <echo level="info" message="PreFlighting Custom Targets Test"/> + </target> + + <!-- ===================================================================== --> + <!-- Steps to do to publish the build results --> + <!-- ===================================================================== --> + <target name="publish"> + </target> + + <!-- ===================================================================== --> + <!-- Default target --> + <!-- ===================================================================== --> + <target name="noDefault"> + <echo message="You must specify a target when invoking this file" /> + </target> + +</project> diff --git a/makefile/preflighting/javadoc.xml b/makefile/preflighting/javadoc.xml new file mode 100644 index 0000000..72fe3ca --- /dev/null +++ b/makefile/preflighting/javadoc.xml @@ -0,0 +1,35 @@ +<?xml version="1.0" encoding="UTF-8"?>
+
+<project name="JavaDoc">
+
+ <!-- Here are expected the following properties:
+
+ sourceCodeDirectories = Semi-colon separated directories which holds the classes where the Javadocs will
+ be generated from.
+
+ excludePackages = Packages which are to be excluded from the generated Javadoc document.
+
+ javadocOutputDirectory = The directory where the generated Javadocs will be placed.
+
+ javaAPIPackageLocationDirectory = The directory location of the API reference file. The file must
+ be named package-list.
+
+ javaAPIURLDirectory = The URL of the Java API.
+ -->
+
+ <target name="javadoc">
+ <javadoc packagenames="*.*"
+ sourcepath="${sourceCodeDirectories}"
+ excludepackagenames="${excludePackages}"
+ defaultexcludes="yes"
+ destdir="${javadocOutputDirectory}"
+ author="false"
+ version="true"
+ use="true"
+ windowtitle="App Validator Javadoc">
+ <link offline="true" href="${javaAPIURLDirectory}" packagelistloc="${javaAPIPackageLocationDirectory}" />
+ <doctitle><![CDATA[<h1>App Validator</h1>]]></doctitle>
+ <bottom><![CDATA[<i>Copyright © 2011, Motorola Mobility, Inc. All rights reserved.</i>]]></bottom>
+ </javadoc>
+ </target>
+</project>
diff --git a/makefile/preflighting/l10n/build.properties b/makefile/preflighting/l10n/build.properties new file mode 100644 index 0000000..15d263d --- /dev/null +++ b/makefile/preflighting/l10n/build.properties @@ -0,0 +1,238 @@ +############################################################################### +# Copyright (c) 2003, 2006 IBM Corporation and others. +# All rights reserved. This program and the accompanying materials +# are made available under the terms of the Eclipse Public License v1.0 +# which accompanies this distribution, and is available at +# http://www.eclipse.org/legal/epl-v10.html +# +# Contributors: +# IBM Corporation - initial API and implementation +############################################################################### +##################### +# Parameters describing how and where to execute the build. +# Typical users need only update the following properties: +# baseLocation - where things you are building against are installed +# bootclasspath - The base jars to compile against (typicaly rt.jar) +# configs - the list of {os, ws, arch} configurations to build. +# +# Of course any of the settings here can be overridden by spec'ing +# them on the command line (e.g., -DbaseLocation=d:/eclipse + +#The type of the top level element we are building, generally "feature" +topLevelElementType = feature +#The id of the top level element we are building +topLevelElementId = com.motorolamobility.preflighting.feature.nl_@langcode + +############# PRODUCT/PACKAGING CONTROL ############# +runPackager=true + +#Set the name of the archive that will result from the product build. +archiveNamePrefix=AppValidator + +# The prefix that will be used in the generated archive. +archivePrefix=application_validator + +# The location underwhich all of the build output will be collected. +collectingFolder=${archivePrefix} + +# The list of {os, ws, arch} configurations to build. This +# value is a '&' separated list of ',' separate triples. For example, +# configs=win32,win32,x86 & linux,motif,x86 +# By default the value is *,*,* +configs = *, *, * +#configs=win32, win32, x86 & \ +# win32,win32,x86_64 & \ +# win32,win32,wpf & \ +# linux, gtk, ppc & \ +# linux, gtk, x86 & \ +# linux, gtk, x86_64 & \ +# linux, motif, x86 & \ +# solaris, motif, sparc & \ +# solaris, gtk, sparc & \ +# aix, motif, ppc & \ +# hpux, motif, ia64_32 & \ +# macosx, carbon, ppc & \ +# macosx, carbon, x86 & \ +# macosx, cocoa, ppc & \ +# macosx, cocoa, x86 & \ +# macosx, cocoa, x86_64 + +# By default PDE creates one archive (result) per entry listed in the configs property. +# Setting this value to true will cause PDE to only create one output containing all +# artifacts for all the platforms listed in the configs property. +# To control the output format for the group, add a "group, group, group - <format>" entry to the +# archivesFormat. +groupConfigurations=true + +#Allow cycles involving at most one bundle that needs to be compiled with the rest being binary bundles. +allowBinaryCycles = true + +#Sort bundles depenedencies across all features instead of just within a given feature. +#flattenDependencies = true + +#Parallel compilation, requires flattenedDependencies=true +#parallelCompilation=true +#parallelThreadCount= +#parallelThreadsPerProcessor= + +#Set to true if you want the output to be ready for an update jar (no site.xml generated) +#outputUpdateJars = false + +#Set to true for Jnlp generation +#codebase should be a URL that will be used as the root of all relative URLs in the output. +#generateJnlp=false +#jnlp.codebase=<codebase url> +#jnlp.j2se=<j2se version> +#jnlp.locale=<a locale> +#jnlp.generateOfflineAllowed=true or false generate <offlineAllowed/> attribute in the generated features +#jnlp.configs=${configs} #uncomment to filter the content of the generated jnlp files based on the configuration being built + +#Set to true if you want to sign jars +#signJars=true +#sign.alias=<alias> +#sign.keystore=<keystore location> +#sign.storepass=<keystore password> +#sign.keypass=<key password> + +#Arguments to send to the zip executable +zipargs= + +#Arguments to send to the tar executable +tarargs= + +#Control the creation of a file containing the version included in each configuration - on by default +#generateVersionsLists=false + +############## BUILD NAMING CONTROL ################ +# The directory into which the build elements are fetched and where +# the build takes place. +#buildDirectory=/tmp/android_build + +# Type of build. Used in naming the build output. Typically this value is +# one of I, N, M, S, ... +buildType= + +# ID of the build. Used in naming the build output. +buildId=dist + +# Label for the build. Used in naming the build output +buildLabel=${buildId} + +#The value to be used for the qualifier of a plugin or feature when you want to override the value computed by pde. +#The value will only be applied to plugin or features indicating build.properties, qualifier = context +#forceContextQualifier=<the value for the qualifier> + +#Enable / disable the generation of a suffix for the features that use .qualifier. +#The generated suffix is computed according to the content of the feature +#generateFeatureVersionSuffix=true + +############# BASE CONTROL ############# +# Settings for the base Eclipse components and Java class libraries +# against which you are building. +# Base location for anything the build needs to compile against. For example, +# in most RCP app or a plug-in, the baseLocation should be the location of a previously +# installed Eclipse against which the application or plug-in code will be compiled and the RCP delta pack. + +#base=${buildDirectory} +#baseLocation=${buildDirectory}/${p2.build.dir} + +#Folder containing repositories whose content is needed to compile against +repoBaseLocation=${buildDirectory}/repositories +#Folder where the content of the repositories from ${repoBaseLocation} will be made available as a form suitable to be compiled against +transformedRepoLocation=${buildDirectory}/transformed + +#Os/Ws/Arch/nl of the eclipse specified by baseLocation +baseos=linux +basews=gtk +basearch=x86_64 + +#this property indicates whether you want the set of plug-ins and features to be considered during the build to be limited to the ones reachable from the features / plugins being built +filteredDependencyCheck=false + +#this property indicates whether the resolution should be done in development mode (i.e. ignore multiple bundles with singletons) +resolution.devMode=false + +#pluginPath is a list of locations in which to find plugins and features. This list is separated by the platform file separator (; or :) +#a location is one of: +#- the location of the jar or folder that is the plugin or feature : /path/to/foo.jar or /path/to/foo +#- a directory that contains a /plugins or /features subdirectory +#- the location of a feature.xml, or for 2.1 style plugins, the plugin.xml or fragment.xml +#pluginPath= + +skipBase=true +eclipseURL=<url for eclipse download site> +eclipseBuildId=<Id of Eclipse build to get> +eclipseBaseURL=${eclipseURL}/eclipse-platform-${eclipseBuildId}-win32.zip + + +############# MAP FILE CONTROL ################ +# This section defines CVS tags to use when fetching the map files from the repository. +# If you want to fetch the map file from repository / location, change the getMapFiles target in the customTargets.xml + +skipMaps=true +mapsRepo=:pserver:anonymous@example.com/path/to/repo +mapsRoot=path/to/maps +mapsCheckoutTag=HEAD + +#tagMaps=true +mapsTagTag=v${buildId} + + +############ REPOSITORY CONTROL ############### +# This section defines properties parameterizing the repositories where plugins, fragments +# bundles and features are being obtained from. + +# The tags to use when fetching elements to build. +# By default thebuilder will use whatever is in the maps. +# This value takes the form of a comma separated list of repository identifier (like used in the map files) and the +# overriding value +# For example fetchTag=CVS=HEAD, SVN=v20050101 +# fetchTag=HEAD +skipFetch=true + + +############# JAVA COMPILER OPTIONS ############## +# The location of the Java jars to compile against. Typically the rt.jar for your JDK/JRE +#bootclasspath=${java.home}/lib/rt.jar + +# specific JRE locations to compile against. These values are used to compile bundles specifying a +# Bundle-RequiredExecutionEnvironment. Uncomment and set values for environments that you support +#CDC-1.0/Foundation-1.0= /path/to/rt.jar +#CDC-1.1/Foundation-1.1= +#OSGi/Minimum-1.0= +#OSGi/Minimum-1.1= +#JRE-1.1= +#J2SE-1.2= +#J2SE-1.3= +#J2SE-1.4= +#J2SE-1.5= +#JavaSE-1.6= +#PersonalJava-1.1= +#PersonalJava-1.2= +#CDC-1.0/PersonalBasis-1.0= +#CDC-1.0/PersonalJava-1.0= +#CDC-1.1/PersonalBasis-1.1= +#CDC-1.1/PersonalJava-1.1= + +# Specify the output format of the compiler log when eclipse jdt is used +logExtension=.log + +# Whether or not to include debug info in the output jars +javacDebugInfo=true + +# Whether or not to fail the build if there are compiler errors +javacFailOnError=true + +# Enable or disable verbose mode of the compiler +javacVerbose=true + +# Extra arguments for the compiler. These are specific to the java compiler being used. +#compilerArg= + +# Default value for the version of the source code. This value is used when compiling plug-ins that do not set the Bundle-RequiredExecutionEnvironment or set javacSource in build.properties +javacSource=1.5 + +# Default value for the version of the byte code targeted. This value is used when compiling plug-ins that do not set the Bundle-RequiredExecutionEnvironment or set javacTarget in build.properties. +javacTarget=1.5 + + diff --git a/makefile/preflighting/l10n/build.xml b/makefile/preflighting/l10n/build.xml new file mode 100644 index 0000000..7b7356d --- /dev/null +++ b/makefile/preflighting/l10n/build.xml @@ -0,0 +1,236 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- ====================================================================== + 03/05/2010 16:08:47 + + build_l10n + Build App Validator localization features + + rdbp36 + ====================================================================== --> +<project name="build_l10n" default="main"> + <description> + Build Studio for Android localization features + All parameters come from studioBuild.xml since all properties are inherited + You should not call this build file directly + </description> + + <property name="buildDirectoryl10n" value="/tmp/application_validator_l10n_${appvalidatorLangpackVersion}" /> + <property name="archivePrefix" value="application_validator" /> + + <target name="main" description="Build AppValidator localization features"> + <antcall target="setup" /> + <antcall target="buildNL"> + <param name="langID" value="pt" /> + <param name="countryID" value="_BR" /> + <param name="langlabel" value="Brazilian Portuguese (Portugu\u00eas do Brasil)" /> + </antcall> + <antcall target="buildNL"> + <param name="langID" value="es" /> + <param name="countryID" value="" /> + <param name="langlabel" value="Spanish (Espa\u00f1ol)" /> + </antcall> + <antcall target="buildNL"> + <param name="langID" value="zh" /> + <param name="countryID" value="" /> + <param name="langlabel" value="Chinese (\u4e2d\u6587)" /> + </antcall> + + <!-- Generate structure for plug-ins that are not yet translated --> + <antcall target="buildNL"> + <param name="langID" value="fr" /> + <param name="countryID" value="" /> + <param name="langlabel" value="French (Fran\u00e7ais) Eclipse Only" /> + </antcall> + <antcall target="buildNL"> + <param name="langID" value="de" /> + <param name="countryID" value="" /> + <param name="langlabel" value="German (Deutsch) Eclipse Only" /> + </antcall> + <antcall target="buildNL"> + <param name="langID" value="ru" /> + <param name="countryID" value="" /> + <param name="langlabel" value="Russian (\u0420\u0443\u0441\u0441\u043a\u0438\u0439) Eclipse Only" /> + </antcall> + <antcall target="buildNL"> + <param name="langID" value="ko" /> + <param name="countryID" value="" /> + <param name="langlabel" value="Korean (\ud55c\uad6d\uc758) Eclipse Only" /> + </antcall> + <antcall target="buildNL"> + <param name="langID" value="ar" /> + <param name="countryID" value="" /> + <param name="langlabel" value="Arabic (\u0627\u0644\u0639\u0631\u0628\u064a\u0629) Eclipse Only" /> + </antcall> + <antcall target="buildNL"> + <param name="langID" value="iw" /> + <param name="countryID" value="" /> + <param name="langlabel" value="Hebrew (\u05e2\u05d1\u05e8\u05d9\u05ea) Eclipse Only" /> + </antcall> + <antcall target="buildNL"> + <param name="langID" value="it" /> + <param name="countryID" value="" /> + <param name="langlabel" value="Italian (Italiano) Eclipse Only" /> + </antcall> + + <antcall target="createUpdateSitePackage" /> + + </target> + + <!-- Copy some build of MOTODEV Studio for Android to the base folder of transformed repos --> + <target name="setup" description="Copy need information from Studio Android Build Process"> + <delete dir="${buildDirectoryl10n}/" includes="**" includeemptydirs="true" /> + <mkdir dir="${buildDirectoryl10n}" /> + <mkdir dir="${buildDirectoryl10n}/repositories" /> + + <copy todir="${buildDirectoryl10n}/repositories"> + <fileset dir="${BASE_REPOSITORIES_DIR}" includes="**" /> + </copy> + <copy todir="${buildDirectoryl10n}/repositories/REPO_APPVALIDATOR"> + <fileset dir="${APPVALIDATOR_OUTPUT}" includes="**" /> + </copy> + + <delete includeemptydirs="true" failonerror="false"> + <fileset dir="${OUTPUT_LANGPACK_APPVALIDATOR}" includes="**" /> + </delete> + <mkdir dir="${OUTPUT_LANGPACK_APPVALIDATOR}" /> + </target> + + <target name="buildNL" description="Build language pack for an specific language"> + <antcall target="clean" /> + <antcall target="copySource" /> + <antcall target="removeExtraLanguages"> + <param name="langID" value="${langID}" /> + <param name="countryID" value="${countryID}" /> + </antcall> + <antcall target="adjustBundles"> + <param name="langID" value="${langID}" /> + <param name="countryID" value="${countryID}" /> + <param name="langlabel" value="${langlabel}" /> + </antcall> + <antcall target="build"> + <param name="langID" value="${langID}" /> + <param name="countryID" value="${countryID}" /> + </antcall> + <antcall target="publish"> + <param name="langID" value="${langID}" /> + <param name="countryID" value="${countryID}" /> + </antcall> + </target> + + <target name="clean" description="Prepare the place to the next language pack"> + <delete includeemptydirs="true"> + <fileset dir="${buildDirectoryl10n}"> + <include name="**" /> + <exclude name="**/repositories/**" /> + <exclude name="**/transformed/**" /> + <exclude name="**/output/**" /> + </fileset> + </delete> + </target> + + <target name="copySource" description="Copy source code from repository to a temporary location"> + <echo message="Copying source to a temporary location" /> + <copy todir="${buildDirectoryl10n}"> + <fileset dir="${SOURCE_DIR}" includes="**/*.nl/**" /> + </copy> + <copy todir="${buildDirectoryl10n}"> + <fileset dir="${MAKEFILE}/preflighting/l10n/" includes="*" /> + </copy> + <delete file="${buildDirectoryl10n}/build.xml" /> + </target> + + <target name="removeExtraLanguages" description="Remove the extra languages of the fragments"> + <echo message="Removing extra languages" /> + <delete failonerror="false" includeEmptyDirs="true"> + <fileset dir="${buildDirectoryl10n}"> + <exclude name="**/*.nl/**/*_${langID}${countryID}.properties" /> + <exclude name="**/*.nl/**/*_${langID}.properties" /> + <exclude name="**/*.nl/**/build.properties" /> + <exclude name="**/*.nl/**/feature.properties" /> + <include name="**/*.nl/**/*.properties" /> + </fileset> + </delete> + </target> + + <target name="adjustBundles" description="Adjust bundles names/ids to have the correct one"> + <echo message="Adding language id to bundles: ${langID}" /> + <echo message="Adding country id to bundles: ${countryID}" /> + <replace dir="${buildDirectoryl10n}"> + <include name="**/*.nl/META-INF/MANIFEST.MF" /> + <replacefilter token="@langcode" value="${langID}${countryID}" /> + </replace> + <replace dir="${buildDirectoryl10n}"> + <include name="**/*.nl/feature*" /> + <replacefilter token="@langcode" value="${langID}${countryID}" /> + <replacefilter token="@langlabel" value="${langlabel}" /> + </replace> + <replace dir="${buildDirectoryl10n}"> + <include name="build.properties" /> + <replacefilter token="@langcode" value="${langID}${countryID}" /> + </replace> + <move tofile="${buildDirectoryl10n}/features/com.motorolamobility.preflighting.feature.nl_${langID}${countryID}" file="${buildDirectoryl10n}/features/preflighting.nl" /> + </target> + + <target name="build" description="Build the language pack"> + <echo message="Building" /> + <java failonerror="true" jar="${eclipse.builder.path}/plugins/${eclipse.builder.launcher}" fork="true"> + <jvmarg value="-Xmx1024m" /> + <jvmarg value="-Xms80m" /> + <arg value="-application" /> + <arg value="org.eclipse.ant.core.antRunner" /> + <arg value="-buildfile" /> + <arg value="${eclipse.builder.path}/plugins/${eclipse.builder.pde}/scripts/build.xml" /> + <arg value="-Dbuilder=${buildDirectoryl10n}" /> + <arg value="-Dtimestamp=${timestamp}" /> + <arg value="-DforceContextQualifier=${forceContextQualifier}" /> + <arg value="-Dbase=${BASE_DIR}" /> + <arg value="-DbaseLocation=${eclipse.builder.path}" /> + <arg value="-DarchivePrefix=${archivePrefix}" /> + <arg value="-DbuildDirectory=${buildDirectoryl10n}" /> + </java> + </target> + + <!-- target name="signStudio"> + <p2.process.artifacts repositorypath="file:/${buildDirectoryl10n}/output"> + <sign keystore="${MAKEFILE}/MOTODEV.keystore" alias="motodev" keypass="${motodev.keypass}" storepass="${motodev.storepass}" /> + </p2.process.artifacts> + </target --> + + <target name="publish" description="Publish the language pack to a certain folder"> + <unzip dest="${buildDirectoryl10n}" src="${buildDirectoryl10n}/dist/com.motorolamobility.preflighting.feature.nl_${langID}${countryID}-dist-group.group.group.zip" /> + + <p2.publish.featuresAndBundles append="true" artifactrepository="file:/${buildDirectoryl10n}/output" artifactrepositoryname="MOTODEV App Validator Language Packs" metadatarepository="file:/${buildDirectoryl10n}/output" metadatarepositoryname="MOTODEV App Validator Language Packs" source="${buildDirectoryl10n}/${archivePrefix}" /> + </target> + + + + <target name="createUpdateSitePackage"> + <!-- antcall target="signStudio" / --> + + <!-- Adjusting site.xml --> + <replace dir="${buildDirectoryl10n}"> + <include name="site.xml" /> + <replacefilter token="@featureversion" value="${appvalidatorLangpackVersion}.${forceContextQualifier}" /> + </replace> + + <!-- mirror babel languages (copy is quicker than p2.mirror task--> + + <copy todir="${OUTPUT_LANGPACK_APPVALIDATOR}"> + <fileset dir="${buildDirectoryl10n}/output/" includes="**" /> + </copy> + + <!-- categorize --> + + <!-- run the category publisher.. there is no ant task to execute it --> + <java failonerror="true" jar="${eclipse.builder.path}/plugins/${eclipse.builder.launcher}" fork="true"> + <arg value="-application" /> + <arg value="org.eclipse.equinox.p2.publisher.CategoryPublisher" /> + <arg value="-metadataRepository" /> + <arg value="file:/${OUTPUT_LANGPACK_APPVALIDATOR}" /> + <arg value="-categoryDefinition" /> + <arg value="file:/${buildDirectoryl10n}/site.xml" /> + </java> + + </target> + +</project> diff --git a/makefile/preflighting/l10n/customTargets.xml b/makefile/preflighting/l10n/customTargets.xml new file mode 100644 index 0000000..a93ea0d --- /dev/null +++ b/makefile/preflighting/l10n/customTargets.xml @@ -0,0 +1,175 @@ +<project name="Build specific targets and properties" default="noDefault">
+
+ <!-- ===================================================================== -->
+ <!-- Run a given ${target} on all elements being built -->
+ <!-- Add on <ant> task for each top level element being built. -->
+ <!-- ===================================================================== -->
+ <available property="allElementsFile" file="${builder}/allElements.xml" value="${builder}/allElements.xml" />
+ <property name="allElementsFile" location="${eclipse.pdebuild.templates}/headless-build/allElements.xml" />
+
+ <import file="${allElementsFile}" />
+ <target name="allElements">
+ <antcall target="allElementsDelegator" />
+ </target>
+
+ <!-- ===================================================================== -->
+ <!-- ===================================================================== -->
+ <target name="getBaseComponents" depends="checkLocalBase" unless="skipBase">
+ <get src="${eclipseBaseURL}" dest="${buildDirectory}/../temp-base.zip" />
+ <unzip dest="${base}" overwrite="true" src="${buildDirectory}/../temp-base.zip" />
+ </target>
+
+ <target name="checkLocalBase">
+ <available file="${base}" property="skipBase" />
+ </target>
+
+ <!-- ===================================================================== -->
+ <!-- Check out map files from correct repository -->
+ <!-- Replace values for mapsCheckoutTag as desired. -->
+ <!-- ===================================================================== -->
+ <target name="getMapFiles" depends="checkLocalMaps" unless="skipMaps">
+ <property name="mapsCheckoutTag" value="HEAD" />
+ <cvs cvsRoot="${mapsRepo}" package="${mapsRoot}" dest="${buildDirectory}/maps" tag="${mapsCheckoutTag}" />
+ </target>
+
+ <target name="checkLocalMaps">
+ <available property="skipMaps" file="${buildDirectory}/maps" />
+ </target>
+
+ <target name="tagMapFiles" if="tagMaps">
+ <cvs dest="${buildDirectory}/maps/${mapsRoot}" command="tag ${mapsTagTag}" />
+ </target>
+
+ <!-- ===================================================================== -->
+
+ <target name="clean" unless="noclean">
+ <antcall target="allElements">
+ <param name="target" value="cleanElement" />
+ </antcall>
+ </target>
+
+ <target name="gatherLogs">
+ <mkdir dir="${buildDirectory}/${buildLabel}/compilelogs" />
+ <antcall target="allElements">
+ <param name="target" value="gatherLogs" />
+ </antcall>
+ <unzip dest="${buildDirectory}/${buildLabel}/compilelogs" overwrite="true">
+ <fileset dir="${buildDirectory}/features">
+ <include name="**/*.log.zip" />
+ </fileset>
+ </unzip>
+ </target>
+
+ <!-- ===================================================================== -->
+ <!-- Steps to do before setup -->
+ <!-- ===================================================================== -->
+ <target name="preSetup">
+ </target>
+
+ <!-- ===================================================================== -->
+ <!-- Steps to do after setup but before starting the build proper -->
+ <!-- ===================================================================== -->
+ <target name="postSetup">
+ <antcall target="getBaseComponents" />
+ </target>
+
+ <!-- ===================================================================== -->
+ <!-- Steps to do before fetching the build elements -->
+ <!-- ===================================================================== -->
+ <target name="preFetch">
+ </target>
+
+ <!-- ===================================================================== -->
+ <!-- Steps to do after fetching the build elements -->
+ <!-- ===================================================================== -->
+ <target name="postFetch">
+ </target>
+
+ <!-- ===================================================================== -->
+ <!-- Steps to do before the repositories are being processed -->
+ <!-- ===================================================================== -->
+ <target name="preProcessRepos">
+ </target>
+
+ <!-- ===================================================================== -->
+ <!-- Steps to do after the repositories have been processed -->
+ <!-- ===================================================================== -->
+ <target name="postProcessRepos">
+ </target>
+
+ <!-- ===================================================================== -->
+ <!-- Steps to do before generating the build scripts. -->
+ <!-- ===================================================================== -->
+ <target name="preGenerate">
+ </target>
+
+ <!-- ===================================================================== -->
+ <!-- Steps to do after generating the build scripts. -->
+ <!-- ===================================================================== -->
+ <target name="postGenerate">
+ <antcall target="clean" />
+ </target>
+
+ <!-- ===================================================================== -->
+ <!-- Steps to do before running the build.xmls for the elements being built. -->
+ <!-- ===================================================================== -->
+ <target name="preProcess">
+ </target>
+
+ <!-- ===================================================================== -->
+ <!-- Steps to do after running the build.xmls for the elements being built. -->
+ <!-- ===================================================================== -->
+ <target name="postProcess">
+ </target>
+
+ <!-- ===================================================================== -->
+ <!-- Steps to do before running assemble. -->
+ <!-- ===================================================================== -->
+ <target name="preAssemble">
+ </target>
+
+ <!-- ===================================================================== -->
+ <!-- Steps to do after running assemble. -->
+ <!-- ===================================================================== -->
+ <target name="postAssemble">
+ </target>
+
+ <!-- ===================================================================== -->
+ <!-- Steps to do before running package. -->
+ <!-- ===================================================================== -->
+ <target name="prePackage">
+ </target>
+
+ <!-- ===================================================================== -->
+ <!-- Steps to do after running package. -->
+ <!-- ===================================================================== -->
+ <target name="postPackage">
+ </target>
+
+ <!-- ===================================================================== -->
+ <!-- Steps to do after the build is done. -->
+ <!-- ===================================================================== -->
+ <target name="postBuild">
+ <antcall target="gatherLogs" />
+ </target>
+
+ <!-- ===================================================================== -->
+ <!-- Steps to do to test the build results -->
+ <!-- ===================================================================== -->
+ <target name="test">
+ </target>
+
+ <!-- ===================================================================== -->
+ <!-- Steps to do to publish the build results -->
+ <!-- ===================================================================== -->
+ <target name="publish">
+ </target>
+
+ <!-- ===================================================================== -->
+ <!-- Default target -->
+ <!-- ===================================================================== -->
+ <target name="noDefault">
+ <echo message="You must specify a target when invoking this file" />
+ </target>
+
+</project>
diff --git a/makefile/preflighting/l10n/site.xml b/makefile/preflighting/l10n/site.xml new file mode 100644 index 0000000..5a82005 --- /dev/null +++ b/makefile/preflighting/l10n/site.xml @@ -0,0 +1,43 @@ +<site>
+ <feature url="features/com.motorolamobility.preflighting.feature.nl_es_@featureversion.jar" id="com.motorolamobility.preflighting.feature.nl_es"
+ version="@featureversion">
+ <category name="MOTODEVAppValidatorLangPack" />
+ </feature>
+ <feature url="features/com.motorolamobility.preflighting.feature.nl_pt_BR_@featureversion.jar" id="com.motorolamobility.preflighting.feature.nl_pt_BR"
+ version="@featureversion">
+ <category name="MOTODEVAppValidatorLangPack" />
+ </feature>
+ <feature url="features/com.motorolamobility.preflighting.feature.nl_zh_@featureversion.jar" id="com.motorolamobility.preflighting.feature.nl_zh"
+ version="@featureversion">
+ <category name="MOTODEVAppValidatorLangPack" />
+ </feature>
+ <feature url="features/com.motorolamobility.preflighting.feature.nl_fr_@featureversion.jar" id="com.motorolamobility.preflighting.feature.nl_fr"
+ version="@featureversion">
+ <category name="MOTODEVAppValidatorLangPack" />
+ </feature>
+ <feature url="features/com.motorolamobility.preflighting.feature.nl_de_@featureversion.jar" id="com.motorolamobility.preflighting.feature.nl_de"
+ version="@featureversion">
+ <category name="MOTODEVAppValidatorLangPack" />
+ </feature>
+ <feature url="features/com.motorolamobility.preflighting.feature.nl_ru_@featureversion.jar" id="com.motorolamobility.preflighting.feature.nl_ru"
+ version="@featureversion">
+ <category name="MOTODEVAppValidatorLangPack" />
+ </feature>
+ <feature url="features/com.motorolamobility.preflighting.feature.nl_ko_@featureversion.jar" id="com.motorolamobility.preflighting.feature.nl_ko"
+ version="@featureversion">
+ <category name="MOTODEVAppValidatorLangPack" />
+ </feature>
+ <feature url="features/com.motorolamobility.preflighting.feature.nl_ar_@featureversion.jar" id="com.motorolamobility.preflighting.feature.nl_ar"
+ version="@featureversion">
+ <category name="MOTODEVAppValidatorLangPack" />
+ </feature>
+ <feature url="features/com.motorolamobility.preflighting.feature.nl_iw_@featureversion.jar" id="com.motorolamobility.preflighting.feature.nl_iw"
+ version="@featureversion">
+ <category name="MOTODEVAppValidatorLangPack" />
+ </feature>
+ <feature url="features/com.motorolamobility.preflighting.feature.nl_it_@featureversion.jar" id="com.motorolamobility.preflighting.feature.nl_it"
+ version="@featureversion">
+ <category name="MOTODEVAppValidatorLangPack" />
+ </feature>
+ <category-def name="MOTODEVAppValidatorLangPack" label="MOTODEV App Validator Language Packages" />
+</site>
\ No newline at end of file diff --git a/makefile/preflighting/linux/appvalidator.sh b/makefile/preflighting/linux/appvalidator.sh new file mode 100644 index 0000000..082d449 --- /dev/null +++ b/makefile/preflighting/linux/appvalidator.sh @@ -0,0 +1,10 @@ +#!/bin/sh + +wdir=`dirname $0` + +[ -e $wdir/motodevstudio ] && exe="motodevstudio" || exe="eclipse" + +$wdir/$exe -nosplash --launcher.suppressErrors -nl en -application com.motorolamobility.preflighting.MOTODEVApplicationValidator $@ -vmargs -Xms128m -Xmx512m -Declipse.exitdata="" +err=$? + +exit $err
\ No newline at end of file diff --git a/makefile/preflighting/macosx/appvalidator.app b/makefile/preflighting/macosx/appvalidator.app Binary files differnew file mode 100644 index 0000000..d07649a --- /dev/null +++ b/makefile/preflighting/macosx/appvalidator.app diff --git a/makefile/preflighting/macosx/appvalidator.sh b/makefile/preflighting/macosx/appvalidator.sh new file mode 100644 index 0000000..b1a7021 --- /dev/null +++ b/makefile/preflighting/macosx/appvalidator.sh @@ -0,0 +1,27 @@ +#!/bin/bash + +exe="" + +pwd=`pwd` +wdir=`dirname $0` + +cd $wdir +fullwdir=`pwd` +if [ -e motodevstudio.app ] +then + exe="motodevstudio" + + if [ ! -e motodevstudio ] + then + ln -s "motodevstudio.app/Contents/MacOS/motodevstudio" . + fi +else + exe="eclipse" +fi + +cd $pwd + +$fullwdir/$exe -nosplash --launcher.suppressErrors -nl en -application com.motorolamobility.preflighting.MOTODEVApplicationValidator $@ -vmargs -Xms128m -Xmx512m -Declipse.exitdata="" -Djava.awt.headless=true | tee +err=$PIPESTATUS + +exit $err diff --git a/makefile/preflighting/package-list b/makefile/preflighting/package-list new file mode 100644 index 0000000..3e918cd --- /dev/null +++ b/makefile/preflighting/package-list @@ -0,0 +1,203 @@ +java.applet +java.awt +java.awt.color +java.awt.datatransfer +java.awt.dnd +java.awt.event +java.awt.font +java.awt.geom +java.awt.im +java.awt.im.spi +java.awt.image +java.awt.image.renderable +java.awt.print +java.beans +java.beans.beancontext +java.io +java.lang +java.lang.annotation +java.lang.instrument +java.lang.management +java.lang.ref +java.lang.reflect +java.math +java.net +java.nio +java.nio.channels +java.nio.channels.spi +java.nio.charset +java.nio.charset.spi +java.rmi +java.rmi.activation +java.rmi.dgc +java.rmi.registry +java.rmi.server +java.security +java.security.acl +java.security.cert +java.security.interfaces +java.security.spec +java.sql +java.text +java.text.spi +java.util +java.util.concurrent +java.util.concurrent.atomic +java.util.concurrent.locks +java.util.jar +java.util.logging +java.util.prefs +java.util.regex +java.util.spi +java.util.zip +javax.accessibility +javax.activation +javax.activity +javax.annotation +javax.annotation.processing +javax.crypto +javax.crypto.interfaces +javax.crypto.spec +javax.imageio +javax.imageio.event +javax.imageio.metadata +javax.imageio.plugins.bmp +javax.imageio.plugins.jpeg +javax.imageio.spi +javax.imageio.stream +javax.jws +javax.jws.soap +javax.lang.model +javax.lang.model.element +javax.lang.model.type +javax.lang.model.util +javax.management +javax.management.loading +javax.management.modelmbean +javax.management.monitor +javax.management.openmbean +javax.management.relation +javax.management.remote +javax.management.remote.rmi +javax.management.timer +javax.naming +javax.naming.directory +javax.naming.event +javax.naming.ldap +javax.naming.spi +javax.net +javax.net.ssl +javax.print +javax.print.attribute +javax.print.attribute.standard +javax.print.event +javax.rmi +javax.rmi.CORBA +javax.rmi.ssl +javax.script +javax.security.auth +javax.security.auth.callback +javax.security.auth.kerberos +javax.security.auth.login +javax.security.auth.spi +javax.security.auth.x500 +javax.security.cert +javax.security.sasl +javax.sound.midi +javax.sound.midi.spi +javax.sound.sampled +javax.sound.sampled.spi +javax.sql +javax.sql.rowset +javax.sql.rowset.serial +javax.sql.rowset.spi +javax.swing +javax.swing.border +javax.swing.colorchooser +javax.swing.event +javax.swing.filechooser +javax.swing.plaf +javax.swing.plaf.basic +javax.swing.plaf.metal +javax.swing.plaf.multi +javax.swing.plaf.synth +javax.swing.table +javax.swing.text +javax.swing.text.html +javax.swing.text.html.parser +javax.swing.text.rtf +javax.swing.tree +javax.swing.undo +javax.tools +javax.transaction +javax.transaction.xa +javax.xml +javax.xml.bind +javax.xml.bind.annotation +javax.xml.bind.annotation.adapters +javax.xml.bind.attachment +javax.xml.bind.helpers +javax.xml.bind.util +javax.xml.crypto +javax.xml.crypto.dom +javax.xml.crypto.dsig +javax.xml.crypto.dsig.dom +javax.xml.crypto.dsig.keyinfo +javax.xml.crypto.dsig.spec +javax.xml.datatype +javax.xml.namespace +javax.xml.parsers +javax.xml.soap +javax.xml.stream +javax.xml.stream.events +javax.xml.stream.util +javax.xml.transform +javax.xml.transform.dom +javax.xml.transform.sax +javax.xml.transform.stax +javax.xml.transform.stream +javax.xml.validation +javax.xml.ws +javax.xml.ws.handler +javax.xml.ws.handler.soap +javax.xml.ws.http +javax.xml.ws.soap +javax.xml.ws.spi +javax.xml.ws.wsaddressing +javax.xml.xpath +org.ietf.jgss +org.omg.CORBA +org.omg.CORBA.DynAnyPackage +org.omg.CORBA.ORBPackage +org.omg.CORBA.TypeCodePackage +org.omg.CORBA.portable +org.omg.CORBA_2_3 +org.omg.CORBA_2_3.portable +org.omg.CosNaming +org.omg.CosNaming.NamingContextExtPackage +org.omg.CosNaming.NamingContextPackage +org.omg.Dynamic +org.omg.DynamicAny +org.omg.DynamicAny.DynAnyFactoryPackage +org.omg.DynamicAny.DynAnyPackage +org.omg.IOP +org.omg.IOP.CodecFactoryPackage +org.omg.IOP.CodecPackage +org.omg.Messaging +org.omg.PortableInterceptor +org.omg.PortableInterceptor.ORBInitInfoPackage +org.omg.PortableServer +org.omg.PortableServer.CurrentPackage +org.omg.PortableServer.POAManagerPackage +org.omg.PortableServer.POAPackage +org.omg.PortableServer.ServantLocatorPackage +org.omg.PortableServer.portable +org.omg.SendingContext +org.omg.stub.java.rmi +org.w3c.dom +org.w3c.dom.bootstrap +org.w3c.dom.events +org.w3c.dom.ls +org.xml.sax +org.xml.sax.ext +org.xml.sax.helpers diff --git a/makefile/preflighting/preflighting.product b/makefile/preflighting/preflighting.product new file mode 100644 index 0000000..2b1a83f --- /dev/null +++ b/makefile/preflighting/preflighting.product @@ -0,0 +1,27 @@ +<?xml version="1.0" encoding="UTF-8"?>
+<?pde version="3.5"?>
+
+<product name="MOTODEV Studio Application Validator" uid="com.motorolamobility.preflighting" application="com.motorolamobility.preflighting.MOTODEVApplicationValidator" version="0.7.1" useFeatures="true" includeLaunchers="false">
+
+
+ <configIni use="default">
+ </configIni>
+
+ <launcherArgs>
+ <vmArgsMac>-XstartOnFirstThread -Dorg.eclipse.swt.internal.carbon.smallFonts</vmArgsMac>
+ </launcherArgs>
+
+ <windowImages/>
+
+
+ <plugins>
+ </plugins>
+
+ <features>
+ <feature id="com.motorolamobility.preflighting.feature"/>
+ <feature id="com.motorolamobility.preflighting.ui.feature"/>
+ <feature id="com.motorolamobility.preflighting.sdk.feature"/>
+ </features>
+
+
+</product>
diff --git a/makefile/preflighting/product/build.properties b/makefile/preflighting/product/build.properties new file mode 100644 index 0000000..c3ed7cb --- /dev/null +++ b/makefile/preflighting/product/build.properties @@ -0,0 +1,258 @@ +############################################################################### +# Copyright (c) 2003, 2009 IBM Corporation and others. +# All rights reserved. This program and the accompanying materials +# are made available under the terms of the Eclipse Public License v1.0 +# which accompanies this distribution, and is available at +# http://www.eclipse.org/legal/epl-v10.html +# +# Contributors: +# IBM Corporation - initial API and implementation +############################################################################### + +p2.gathering = true +p2.metadata.repo.name = MOTODEV Studio Application Validator +p2.artifact.repo.name = MOTODEV Studio Application Validator +p2.category.site = file:${buildDirectory}/site.xml + +#generatedBuildProperties = ${buildDirectory}/root.properties + +##################### +# Parameters describing how and where to execute the build. +# Typical users need only update the following properties: +# baseLocation - where things you are building against are installed +# bootclasspath - The base jars to compile against (typicaly rt.jar) +# configs - the list of {os, ws, arch} configurations to build. +# +# Of course any of the settings here can be overridden by spec'ing +# them on the command line (e.g., -DbaseLocation=d:/eclipse + +#The type of the top level element we are building, generally "feature" +topLevelElementType = feature +#The id of the top level element we are building +topLevelElementId = com.motorolamobility.preflighting.feature +#featureList = com.motorolamobility.preflighting.feature + +############# PRODUCT/PACKAGING CONTROL ############# +product = ${GIT_REPOSITORY_PATH}/android/makefile/preflighting/product/preflighting.product +runPackager=true + +#Set the name of the archive that will result from the product build. +#archiveNamePrefix= + +# The prefix that will be used in the generated archive. +archivePrefix=MOTODEV_App_Validator + +# The location underwhich all of the build output will be collected. +collectingFolder=${archivePrefix} + +# The list of {os, ws, arch} configurations to build. This +# value is a '&' separated list of ',' separate triples. For example, +# configs=win32,win32,x86 & linux,motif,x86 +# By default the value is *,*,* +#configs = *, *, * +configs=win32, win32, x86 & \ + win32,win32,x86_64 & \ + linux, gtk, x86 & \ + linux, gtk, x86_64 & \ + macosx, cocoa, x86 & \ + macosx, cocoa, x86_64 + +# linux, motif, x86 & \ +# solaris, motif, sparc & \ +# solaris, gtk, sparc & \ +# aix, motif, ppc & \ +# hpux, motif, ia64_32 & \ +# macosx, carbon, ppc & \ +# macosx, carbon, x86 & \ +# win32,win32,wpf & \ +# linux, gtk, ppc & \ + +# By default PDE creates one archive (result) per entry listed in the configs property. +# Setting this value to true will cause PDE to only create one output containing all +# artifacts for all the platforms listed in the configs property. +# To control the output format for the group, add a "group, group, group - <format>" entry to the +# archivesFormat. +groupConfigurations=true + +#The format of the archive. By default a zip is created using antZip. +#The list can only contain the configuration for which the desired format is different than zip. +archivesFormat=linux, gtk, x86 - tar & \ + linux, gtk, x86_64 - tar & \ + macosx, cocoa, x86 - tar & \ + macosx, cocoa, x86_64 - tar + +#Allow cycles involving at most one bundle that needs to be compiled with the rest being binary bundles. +allowBinaryCycles = true + +#Sort bundles depenedencies across all features instead of just within a given feature. +#flattenDependencies = true + +#Parallel compilation, requires flattenedDependencies=true +#parallelCompilation=true +#parallelThreadCount= +#parallelThreadsPerProcessor= + +#Set to true if you want the output to be ready for an update jar (no site.xml generated) +#outputUpdateJars = false + +#Set to true for Jnlp generation +#codebase should be a URL that will be used as the root of all relative URLs in the output. +#generateJnlp=false +#jnlp.codebase=<codebase url> +#jnlp.j2se=<j2se version> +#jnlp.locale=<a locale> +#jnlp.generateOfflineAllowed=true or false generate <offlineAllowed/> attribute in the generated features +#jnlp.configs=${configs} #uncomment to filter the content of the generated jnlp files based on the configuration being built + +#Set to true if you want to sign jars +#signJars=true +#sign.alias=motodev +#sign.keystore=${motodev.keystore} +#sign.storepass=${motodev.storepass} +#sign.keypass=${motodev.keypass} + +#Arguments to send to the zip executable +zipargs= + +#Arguments to send to the tar executable +tarargs= + +#Control the creation of a file containing the version included in each configuration - on by default +#generateVersionsLists=false + +############## BUILD NAMING CONTROL ################ +# The directory into which the build elements are fetched and where +# the build takes place. +#buildDirectory=/tmp/appvalidatorproductbuild${appValidatorVersion} + +# Type of build. Used in naming the build output. Typically this value is +# one of I, N, M, S, ... +buildType=I + +# ID of the build. Used in naming the build output. +buildId=MOTODEV_Application_Validator_${appvalidatorVersion} + +# Label for the build. Used in naming the build output +buildLabel=${buildId}_${timestamp} + +# Timestamp for the build. Used in naming the build output +#timestamp=007 + +#The value to be used for the qualifier of a plugin or feature when you want to override the value computed by pde. +#The value will only be applied to plugin or features indicating build.properties, qualifier = context +#forceContextQualifier=<the value for the qualifier> + +#Enable / disable the generation of a suffix for the features that use .qualifier. +#The generated suffix is computed according to the content of the feature +#generateFeatureVersionSuffix=true + +############# BASE CONTROL ############# +# Settings for the base Eclipse components and Java class libraries +# against which you are building. +# Base location for anything the build needs to compile against. For example, +# in most RCP app or a plug-in, the baseLocation should be the location of a previously +# installed Eclipse against which the application or plug-in code will be compiled and the RCP delta pack. + +base=${BASE_DIR} +#baseLocation=${base}/env/eclipse + +#Folder containing repositories whose content is needed to compile against +#repoBaseLocation=${INPUT_DIR}/repository +#Folder where the content of the repositories from ${repoBaseLocation} will be made available as a form suitable to be compiled against +#transformedRepoLocation=${INPUT_DIR}/transformedRepos + +#Os/Ws/Arch/nl of the eclipse specified by baseLocation +baseos=linux +basews=gtk +basearch=x86_64 + +#this property indicates whether you want the set of plug-ins and features to be considered during the build to be limited to the ones reachable from the features / plugins being built +filteredDependencyCheck=false + +#this property indicates whether the resolution should be done in development mode (i.e. ignore multiple bundles with singletons) +resolution.devMode=false + +#pluginPath is a list of locations in which to find plugins and features. This list is separated by the platform file separator (; or :) +#a location is one of: +#- the location of the jar or folder that is the plugin or feature : /path/to/foo.jar or /path/to/foo +#- a directory that contains a /plugins or /features subdirectory +#- the location of a feature.xml, or for 2.1 style plugins, the plugin.xml or fragment.xml +#pluginPath= + +skipBase=true +eclipseURL=<url for eclipse download site> +eclipseBuildId=<Id of Eclipse build to get> +eclipseBaseURL=${eclipseURL}/eclipse-platform-${eclipseBuildId}-win32.zip + + +############# MAP FILE CONTROL ################ +# This section defines CVS tags to use when fetching the map files from the repository. +# If you want to fetch the map file from repository / location, change the getMapFiles target in the customTargets.xml + +skipMaps=true +mapsRepo=:pserver:anonymous@example.com/path/to/repo +mapsRoot=path/to/maps +mapsCheckoutTag=HEAD + +#tagMaps=true +mapsTagTag=v${buildId} + + +############ REPOSITORY CONTROL ############### +# This section defines properties parameterizing the repositories where plugins, fragments +# bundles and features are being obtained from. + +# The tags to use when fetching elements to build. +# By default thebuilder will use whatever is in the maps. +# This value takes the form of a comma separated list of repository identifier (like used in the map files) and the +# overriding value +# For example fetchTag=CVS=HEAD, SVN=v20050101 +# fetchTag=HEAD +skipFetch=true + + +############# JAVA COMPILER OPTIONS ############## +# The location of the Java jars to compile against. Typically the rt.jar for your JDK/JRE +#bootclasspath=${java.home}/lib/rt.jar + +# specific JRE locations to compile against. These values are used to compile bundles specifying a +# Bundle-RequiredExecutionEnvironment. Uncomment and set values for environments that you support +#CDC-1.0/Foundation-1.0= /path/to/rt.jar +#CDC-1.1/Foundation-1.1= +#OSGi/Minimum-1.0= +#OSGi/Minimum-1.1= +#JRE-1.1= +#J2SE-1.2= +#J2SE-1.3= +#J2SE-1.4= +#J2SE-1.5= +#JavaSE-1.6= +#PersonalJava-1.1= +#PersonalJava-1.2= +#CDC-1.0/PersonalBasis-1.0= +#CDC-1.0/PersonalJava-1.0= +#CDC-1.1/PersonalBasis-1.1= +#CDC-1.1/PersonalJava-1.1= + +# Specify the output format of the compiler log when eclipse jdt is used +logExtension=.log + +# Whether or not to include debug info in the output jars +javacDebugInfo=true + +# Whether or not to fail the build if there are compiler errors +javacFailOnError=true + +# Enable or disable verbose mode of the compiler +javacVerbose=true + +# Extra arguments for the compiler. These are specific to the java compiler being used. +#compilerArg= + +# Default value for the version of the source code. This value is used when compiling plug-ins that do not set the Bundle-RequiredExecutionEnvironment or set javacSource in build.properties +javacSource=1.5 + +# Default value for the version of the byte code targeted. This value is used when compiling plug-ins that do not set the Bundle-RequiredExecutionEnvironment or set javacTarget in build.properties. +javacTarget=1.5 + + diff --git a/makefile/preflighting/product/customAssembly.xml b/makefile/preflighting/product/customAssembly.xml new file mode 100644 index 0000000..c3341d4 --- /dev/null +++ b/makefile/preflighting/product/customAssembly.xml @@ -0,0 +1,71 @@ +<project name="Build specific targets and properties" default="noDefault"> + + <!-- ===================================================================== + + The Following Properties are available in all targets: + - eclipse.base : the base folder everything will be collected into + - eclipse.plugins : the plugins folder + - eclipse.features: the features folder + - archiveFullPath : the full path of the final archive once it is created + + ===================================================================== --> + + <!-- ===================================================================== --> + <!-- Called after each invocation of the gather.bin.parts target on the --> + <!-- individual plugins and features. --> + <!-- Available properties are: --> + <!-- projectLocation: location of the project being gathered --> + <!-- projectName: symbolic name with version (org.eclipse.foo_1.0.0.v123) --> + <!-- target.folder: the destination, eclipse/plugins or eclipse/features --> + <!-- --> + <!-- The generated pattern is that plugins/features are gathered into the --> + <!-- folder ${target.folder}/${projectName} --> + <!-- ===================================================================== --> + <target name="gather.bin.parts"> + </target> + + <!-- ===================================================================== --> + <!-- Called after invoking the gather.bin.parts targets for all plugins --> + <!-- and features. Results exist as folders and have not yet been jarred. --> + <!-- ===================================================================== --> + <target name="post.gather.bin.parts"> + </target> + + <!-- ===================================================================== --> + <!-- Called just prior to signing a jar --> + <!-- In addititon to the properties listed above: --> + <!-- - source : plugins or features directory --> + <!-- - elementName: element being signed without .jar --> + <!-- (eg "org.eclipse.foo_1.0.0" --> + <!-- ===================================================================== --> + <target name="pre.jarSigning"> + </target> + + <!-- ===================================================================== --> + <!-- Called after all plugins and features have been jarred --> + <!-- (and potentially signed) --> + <!-- ===================================================================== --> + <target name="post.jarUp"> + </target> + + <!-- ===================================================================== --> + <!-- Called just before the archive file is built --> + <!-- In addititon to the properties listed above: --> + <!-- - rootFolder : the folder containing the root files --> + <!-- ===================================================================== --> + <target name="pre.archive"> + <!-- copy windows console executables (will fail on macosx and linux) --> + <copy file="${eclipse.builder.path}/features/${eclipse.builder.executable}/bin/${os}/${ws}/${arch}/eclipsec.exe" tofile="${eclipse.base}/motodevstudioc.exe" overwrite="true" failonerror="false" /> + + <!-- remove appvalidator.app from macosx products (will fail on windows and linux)--> + <delete file="${eclipse.base}/appvalidator.app" failonerror="false" /> + </target> + + <!-- ===================================================================== --> + <!-- Default target --> + <!-- ===================================================================== --> + <target name="noDefault"> + <echo message="You must specify a target when invoking this file" /> + </target> + +</project> diff --git a/makefile/preflighting/product/customTargets.xml b/makefile/preflighting/product/customTargets.xml new file mode 100644 index 0000000..21c7c2e --- /dev/null +++ b/makefile/preflighting/product/customTargets.xml @@ -0,0 +1,217 @@ +<project name="Build specific targets and properties" default="noDefault"> + + <!-- ===================================================================== --> + <!-- Run a given ${target} on all elements being built --> + <!-- Add on <ant> task for each top level element being built. --> + <!-- ===================================================================== --> + <available property="allElementsFile" file="${builder}/allElements.xml" value="${builder}/allElements.xml" /> + <property name="allElementsFile" location="${eclipse.pdebuild.templates}/headless-build/allElements.xml" /> + + <import file="${allElementsFile}" /> + <target name="allElements"> + <antcall target="allElementsDelegator" /> + </target> + + <!-- ===================================================================== --> + <!-- ===================================================================== --> + <target name="getBaseComponents" depends="checkLocalBase" unless="skipBase"> + <get src="${eclipseBaseURL}" dest="${buildDirectory}/../temp-base.zip" /> + <unzip dest="${base}" overwrite="true" src="${buildDirectory}/../temp-base.zip" /> + </target> + + <target name="checkLocalBase"> + <available file="${base}" property="skipBase" /> + </target> + + <!-- ===================================================================== --> + <!-- Check out map files from correct repository --> + <!-- Replace values for mapsCheckoutTag as desired. --> + <!-- ===================================================================== --> + <target name="getMapFiles" depends="checkLocalMaps" unless="skipMaps"> + <property name="mapsCheckoutTag" value="HEAD" /> + <cvs cvsRoot="${mapsRepo}" package="${mapsRoot}" dest="${buildDirectory}/maps" tag="${mapsCheckoutTag}" /> + </target> + + <target name="checkLocalMaps"> + <available property="skipMaps" file="${buildDirectory}/maps" /> + </target> + + <target name="tagMapFiles" if="tagMaps"> + <cvs dest="${buildDirectory}/maps/${mapsRoot}" command="tag ${mapsTagTag}" /> + </target> + + <!-- ===================================================================== --> + + <target name="clean" unless="noclean"> + <antcall target="allElements"> + <param name="target" value="cleanElement" /> + </antcall> + </target> + + <target name="gatherLogs"> + <mkdir dir="${buildDirectory}/${buildLabel}/compilelogs" /> + <antcall target="allElements"> + <param name="target" value="gatherLogs" /> + </antcall> + <unzip dest="${buildDirectory}/${buildLabel}/compilelogs" overwrite="true"> + <fileset dir="${buildDirectory}/features"> + <include name="**/*.log.zip" /> + </fileset> + </unzip> + </target> + + <!-- ===================================================================== --> + <!-- Steps to do before setup --> + <!-- ===================================================================== --> + <target name="preSetup"> + + <copy todir="${buildDirectory}"> + <fileset dir="${SOURCE_DIR}/" includes="**/preflighting*/**" /> + </copy> + <echo message="0=${timestamp}" file="${buildDirectory}/plugins/preflighting.core/about.mappings" /> + <echoxml file="${buildDirectory}/site.xml"> + <site> + <feature url="features/${appValidatorFeatureName}.${appValidatorFeatureVersion}.jar" id="${appValidatorFeatureName}" version="${appValidatorFeatureVersion}"> + <category name="MOTODEVStudioforAndroid" /> + </feature> + <category-def name="MOTODEVStudioforAndroid" label="MOTODEV Studio for Android" /> + </site> + </echoxml> + </target> + + <!-- ===================================================================== --> + <!-- Steps to do after setup but before starting the build proper --> + <!-- ===================================================================== --> + <target name="postSetup"> + <antcall target="getBaseComponents" /> + </target> + + <!-- ===================================================================== --> + <!-- Steps to do before fetching the build elements --> + <!-- ===================================================================== --> + <target name="preFetch"> + </target> + + <!-- ===================================================================== --> + <!-- Steps to do after fetching the build elements --> + <!-- ===================================================================== --> + <target name="postFetch"> + </target> + + <!-- ===================================================================== --> + <!-- Steps to do before the repositories are being processed --> + <!-- ===================================================================== --> + <target name="preProcessRepos"> + </target> + + <!-- ===================================================================== --> + <!-- Steps to do after the repositories have been processed --> + <!-- ===================================================================== --> + <target name="postProcessRepos"> + + </target> + + <!-- ===================================================================== --> + <!-- Steps to do before generating the build scripts. --> + <!-- ===================================================================== --> + <target name="preGenerate"> + <mkdir dir="${buildDirectory}/tmp/plugins" /> + <copy todir="${buildDirectory}/tmp/plugins"> + <fileset dir="${GIT_REPOSITORY_PATH}/android/docs/manuals/" includes="*.jar" /> + </copy> + <delete> + <fileset dir="${transformedRepoLocation}" includes="com.motorola*helpbase*" /> + </delete> + <p2.generator append="true" source="${buildDirectory}/tmp/" artifactrepository="file:${transformedRepoLocation}" metadatarepository="file:${transformedRepoLocation}" publishartifacts="true" /> + </target> + + <!-- ===================================================================== --> + <!-- Steps to do after generating the build scripts. --> + <!-- ===================================================================== --> + <target name="postGenerate"> + <antcall target="clean" /> + </target> + + <!-- ===================================================================== --> + <!-- Steps to do before running the build.xmls for the elements being built. --> + <!-- ===================================================================== --> + <target name="preProcess"> + </target> + + <!-- ===================================================================== --> + <!-- Steps to do after running the build.xmls for the elements being built. --> + <!-- ===================================================================== --> + <target name="postProcess"> + </target> + + <!-- ===================================================================== --> + <!-- Steps to do before running assemble. --> + <!-- ===================================================================== --> + <target name="preAssemble"> + <copy todir="${transformedRepoLocation}/plugins" failonerror="false" overwrite="true"> + <fileset dir="${BASE_REPOSITORIES_DIR}/REPO_ADT/plugins/" includes="*.jar" /> + </copy> + <copy todir="${transformedRepoLocation}/features" failonerror="false" overwrite="true"> + <fileset dir="${BASE_REPOSITORIES_DIR}/REPO_ADT/features/" includes="*.jar" /> + </copy> + </target> + + <!-- ===================================================================== --> + <!-- Steps to do after running assemble. --> + <!-- ===================================================================== --> + <target name="postAssemble"> + </target> + + <!-- ===================================================================== --> + <!-- Steps to do before running package. --> + <!-- ===================================================================== --> + <target name="prePackage"> + </target> + + <!-- ===================================================================== --> + <!-- Steps to do after running package. --> + <!-- ===================================================================== --> + <target name="postPackage"> + </target> + + <!-- ===================================================================== --> + <!-- Steps to do after the build is done. --> + <!-- ===================================================================== --> + <target name="postBuild"> + <antcall target="renameOutputs" /> + <antcall target="copyResults" /> + </target> + + <target name="renameOutputs"> + <move file="${buildDirectory}/${buildLabel}/${buildId}-linux.gtk.x86.zip" tofile="${buildDirectory}/${buildLabel}/${buildId}-linux.gtk.x86.tar.gz" /> + <move file="${buildDirectory}/${buildLabel}/${buildId}-linux.gtk.x86_64.zip" tofile="${buildDirectory}/${buildLabel}/${buildId}-linux.gtk.x86_64.tar.gz" /> + <move file="${buildDirectory}/${buildLabel}/${buildId}-macosx.cocoa.x86.zip" tofile="${buildDirectory}/${buildLabel}/${buildId}-macosx.cocoa.x86.tar.gz" /> + <move file="${buildDirectory}/${buildLabel}/${buildId}-macosx.cocoa.x86_64.zip" tofile="${buildDirectory}/${buildLabel}/${buildId}-macosx.cocoa.x86_64.tar.gz" /> + </target> + + <target name="copyResults" if="outputDirectory"> + <copy todir="${outputDirectory}"> + <fileset dir="${buildDirectory}/${buildLabel}" includes="**" excludes="compilelogs/" /> + </copy> + </target> + + <!-- ===================================================================== --> + <!-- Steps to do to test the build results --> + <!-- ===================================================================== --> + <target name="test"> + </target> + + <!-- ===================================================================== --> + <!-- Steps to do to publish the build results --> + <!-- ===================================================================== --> + <target name="publish"> + </target> + + <!-- ===================================================================== --> + <!-- Default target --> + <!-- ===================================================================== --> + <target name="noDefault"> + <echo message="You must specify a target when invoking this file" /> + </target> + +</project> diff --git a/makefile/preflighting/product/eant b/makefile/preflighting/product/eant new file mode 100644 index 0000000..9516366 --- /dev/null +++ b/makefile/preflighting/product/eant @@ -0,0 +1,9 @@ +#!/bin/bash +# Run Ant with the configuration above +export BUILD_BASE_PATH=/android/2.2.0 + +#uncomment to create dev releases (qualifier is the build date) +#export DEV_RELEASE=true + + +$BUILD_BASE_PATH/env/eclipse/eclipse -nosplash -application org.eclipse.ant.core.antRunner -data /tmp/workspace_appvalidator_product -buildfile $BUILD_BASE_PATH/env/eclipse/plugins/org.eclipse.pde.build_3.6.1.R36x_v20100823/scripts/productBuild/productBuild.xml -Dbuilder=$BUILD_BASE_PATH/env/code/android/makefile/preflighting/product/ -DBUILD_DIR=$BUILD_BASE_PATH -Dtimestamp=00000000 -DforceContextQualifier=testing -logger org.apache.tools.ant.XmlLogger -logfile /tmp/buildappvalidatorproductlog.xml -Xmx1024m -Xms80m
\ No newline at end of file diff --git a/makefile/preflighting/product/preflighting.product b/makefile/preflighting/product/preflighting.product new file mode 100644 index 0000000..56f00c9 --- /dev/null +++ b/makefile/preflighting/product/preflighting.product @@ -0,0 +1,39 @@ +<?xml version="1.0" encoding="UTF-8"?>
+<?pde version="3.5"?>
+
+<product name="MOTODEV Studio Application Validator" uid="com.motorolamobility.preflighting.product" id="com.motorolamobility.preflighting.appvalidator" application="com.motorolamobility.preflighting.MOTODEVApplicationValidator" version="1.0.0" useFeatures="true" includeLaunchers="true">
+
+ <configIni use="default">
+ </configIni>
+
+ <launcherArgs>
+ <vmArgsMac>-XstartOnFirstThread -Dorg.eclipse.swt.internal.carbon.smallFonts</vmArgsMac>
+ </launcherArgs>
+
+ <windowImages/>
+
+ <launcher name="motodevstudio">
+ <linux icon="/com.motorolamobility.preflighting/icons/AppValidator.xpm"/>
+ <macosx icon="/com.motorolamobility.preflighting/icons/Appvalidator.icns"/>
+ <solaris/>
+ <win useIco="true">
+ <ico path="/com.motorolamobility.preflighting/icons/AppValidator.ico"/>
+ <bmp/>
+ </win>
+ </launcher>
+
+ <vm>
+ </vm>
+
+ <plugins>
+ </plugins>
+
+ <features>
+ <feature id="com.motorolamobility.preflighting.feature"/>
+ </features>
+
+ <configurations>
+ <plugin id="org.eclipse.core.runtime" autoStart="true" startLevel="1" />
+ </configurations>
+
+</product>
diff --git a/makefile/preflighting/win32/appvalidator.bat b/makefile/preflighting/win32/appvalidator.bat new file mode 100644 index 0000000..0881d71 --- /dev/null +++ b/makefile/preflighting/win32/appvalidator.bat @@ -0,0 +1,20 @@ +@echo off
+
+set wdir=%0\..
+
+
+if EXIST %wdir%\motodevstudioc.exe (
+ SET exe=motodevstudioc
+) ELSE (
+ SET exe=eclipsec
+)
+
+%wdir%\%exe% -nosplash --launcher.suppressErrors -nl en -application com.motorolamobility.preflighting.MOTODEVApplicationValidator %* -vmargs -Xms128m -Xmx512m -Declipse.exitdata=""
+
+set err=%ERRORLEVEL%
+
+
+echo.
+
+
+EXIT /B %err%
\ No newline at end of file diff --git a/makefile/repository_settings/org.eclipse.equinox.p2.artifact.repository.prefs b/makefile/repository_settings/org.eclipse.equinox.p2.artifact.repository.prefs new file mode 100644 index 0000000..9dc3c91 --- /dev/null +++ b/makefile/repository_settings/org.eclipse.equinox.p2.artifact.repository.prefs @@ -0,0 +1,12 @@ +eclipse.preferences.version=1 +repositories/https\:__studio-android.motodevupdate.com_android_4.1/url=https\://studio-android.motodevupdate.com/android/4.1/ +repositories/https\:__studio-android.motodevupdate.com_android_4.1/enabled=true +repositories/https\:__studio-android.motodevupdate.com_android_4.1/isSystem=false + +repositories/http\:__download.eclipse.org_eclipse_updates_4.2/enabled=false +repositories/http\:__download.eclipse.org_eclipse_updates_4.2/isSystem=false +repositories/http\:__download.eclipse.org_eclipse_updates_4.2/url=http\://download.eclipse.org/eclipse/updates/4.2/ + +repositories/http\:__download.eclipse.org_releases_juno/enabled=false +repositories/http\:__download.eclipse.org_releases_juno/isSystem=true +repositories/http\:__download.eclipse.org_releases_juno/url=http\://download.eclipse.org/releases/juno/ diff --git a/makefile/repository_settings/org.eclipse.equinox.p2.metadata.repository.prefs b/makefile/repository_settings/org.eclipse.equinox.p2.metadata.repository.prefs new file mode 100644 index 0000000..61c0129 --- /dev/null +++ b/makefile/repository_settings/org.eclipse.equinox.p2.metadata.repository.prefs @@ -0,0 +1,15 @@ +eclipse.preferences.version=1 +repositories/https\:__studio-android.motodevupdate.com_android_4.1/nickname=MOTODEV Studio for Android 4.1 Updates +repositories/https\:__studio-android.motodevupdate.com_android_4.1/enabled=true +repositories/https\:__studio-android.motodevupdate.com_android_4.1/uri=https\://studio-android.motodevupdate.com/android/4.1/ +repositories/https\:__studio-android.motodevupdate.com_android_4.1/isSystem=false + +repositories/http\:__download.eclipse.org_eclipse_updates_4.2/nickname=Eclipse Juno Updates +repositories/http\:__download.eclipse.org_eclipse_updates_4.2/enabled=false +repositories/http\:__download.eclipse.org_eclipse_updates_4.2/isSystem=false +repositories/http\:__download.eclipse.org_eclipse_updates_4.2/uri=http\://download.eclipse.org/eclipse/updates/4.2/ + +repositories/http\:__download.eclipse.org_releases_juno/nickname=Eclipse Juno +repositories/http\:__download.eclipse.org_releases_juno/enabled=false +repositories/http\:__download.eclipse.org_releases_juno/isSystem=false +repositories/http\:__download.eclipse.org_releases_juno/uri=http\://download.eclipse.org/releases/juno/
\ No newline at end of file diff --git a/makefile/repository_skel/content.xml b/makefile/repository_skel/content.xml new file mode 100644 index 0000000..33b09db --- /dev/null +++ b/makefile/repository_skel/content.xml @@ -0,0 +1,26 @@ +<?xml version='1.0' encoding='UTF-8'?> +<?metadataRepository class='org.eclipse.equinox.internal.p2.metadata.repository.LocalMetadataRepository' version='1.0.0'?> +<repository name='MOTODEV Studio for Android' type='org.eclipse.equinox.internal.p2.metadata.repository.LocalMetadataRepository' version='1'> + <references size="16"> + <!-- Sequoyah --> + <repository url="http://download.eclipse.org/sequoyah/updates/2.1/" options="1" type="0"/> + <repository url="http://download.eclipse.org/sequoyah/updates/2.1/" options="1" type="1"/> + + <!-- proguard updates --> + <repository url="http://www.certiv.net/updates/" options="1" type="0"/> + <repository url="http://www.certiv.net/updates/" options="1" type="1"/> + + <repository url="https://studio-android.motodevupdate.com/platform/3.2/" type="0" options="1"/> + <repository url="https://studio-android.motodevupdate.com/platform/3.2/" type="1" options="1"/> + <repository url="https://studio-android.motodevupdate.com/android/4.1/adt/" type="0" options="1"/> + <repository url="https://studio-android.motodevupdate.com/android/4.1/adt/" type="1" options="1"/> + <repository url="https://studio-android.motodevupdate.com/android/4.1/basic/" type="0" options="1"/> + <repository url="https://studio-android.motodevupdate.com/android/4.1/basic/" type="1" options="1"/> + <repository url="https://studio-android.motodevupdate.com/android/4.1/studio/" type="0" options="1"/> + <repository url="https://studio-android.motodevupdate.com/android/4.1/studio/" type="1" options="1"/> + <repository url="http://download.eclipse.org/releases/juno/" type="0" options="1"/> + <repository url="http://download.eclipse.org/releases/juno/" type="1" options="1"/> + <repository url="https://studio-android.motodevupdate.com/android/4.1/rss/" type="0" options="1"/> + <repository url="https://studio-android.motodevupdate.com/android/4.1/rss/" type="1" options="1"/> + </references> +</repository> diff --git a/makefile/repository_skel/content_basic.xml b/makefile/repository_skel/content_basic.xml new file mode 100644 index 0000000..b8cfc10 --- /dev/null +++ b/makefile/repository_skel/content_basic.xml @@ -0,0 +1,10 @@ +<?xml version='1.0' encoding='UTF-8'?>
+<?metadataRepository class='org.eclipse.equinox.internal.p2.metadata.repository.LocalMetadataRepository' version='1.0.0'?>
+<repository name='MOTODEV Studio for Android Core' type='org.eclipse.equinox.internal.p2.metadata.repository.LocalMetadataRepository' version='1'>
+ <references size="4">
+ <repository url="https://studio-android.motodevupdate.com/android/4.2/basic/" type="0" options="1"/>
+ <repository url="https://studio-android.motodevupdate.com/android/4.2/basic/" type="1" options="1"/>
+ <repository url="https://studio-android.motodevupdate.com/android/4.2/" type="0" options="1"/>
+ <repository url="https://studio-android.motodevupdate.com/android/4.2/" type="1" options="1"/>
+ </references>
+</repository>
diff --git a/makefile/scripts/checkmodifications.sh b/makefile/scripts/checkmodifications.sh new file mode 100644 index 0000000..e36e974 --- /dev/null +++ b/makefile/scripts/checkmodifications.sh @@ -0,0 +1,71 @@ +#!/bin/bash +#$1 - root path to code (e.g. /android/2.1.0/env/code) +#$2 - git tag (label) to use as initial baseline to find changed files (e.g.: STUDIO-ANDROID_N_02.01.00I_B001) +#$3 - studio version (e.g.: 2.1.0) +#$4 - platform version (e.g.: 1.0.1) +#$5 - app validator version (e.g.: 0.7.0) +#$6 - app validator ui version (e.g.: 0.7.0) +#$7 - folder to send report (output file) +cd $1 +echo "The following plugins have incorrect version: " >> $7/plugins_to_update.txt +for f in `ls $1/android/src/plugins`; +do + #echo $f; + #retrieve the plugins modified and count the lines (if plugin not changed wc returns zero) + lines=`git diff --name-only $2 -- android/src/plugins/$f | wc -w | cut -d" " -f1` + #echo $lines + if [ "$lines" -gt "0" ] + then + #As plugin was modified, check if MANIFEST.MF has the version of the release, if not report + #echo $1/android/src/plugins/$f + #cat $1/android/src/plugins/$f/META-INF/MANIFEST.MF | grep "Bundle-Version:" + if [[ $1/android/src/plugins/$f == *preflighting* ]] ; + then + #echo "preflighting plugin" + if [[ $1/android/src/plugins/$f == *preflighting.ui* ]] ; + then + version=`cat $1/android/src/plugins/$f/META-INF/MANIFEST.MF | grep "Bundle-Version:" | grep $6 | cut -d":" -f2 | tr -d ' '` + if [ "$version" != "$6.qualifier" ] + then + echo android/src/plugins/$f >> $7/plugins_to_update.txt + fi + else + version=`cat $1/android/src/plugins/$f/META-INF/MANIFEST.MF | grep "Bundle-Version:" | grep $5 | cut -d":" -f2 | tr -d ' '` + if [ "$version" != "$5.qualifier" ] + then + echo android/src/plugins/$f >> $7/plugins_to_update.txt + fi + fi + + else + #echo "studio plugin" + version=`cat $1/android/src/plugins/$f/META-INF/MANIFEST.MF | grep "Bundle-Version:" | grep $3 | cut -d":" -f2 | tr -d ' '` + if [ "$version" != "$3.qualifier" ] + then + echo android/src/plugins/$f >> $7/plugins_to_update.txt + fi + fi + fi +done +for f in `ls $1/platform/code/plugins`; +do + #echo $f; + #retrieve the plugins modified and count the lines (if plugin not changed wc returns zero) + lines=`git diff --name-only $2 -- platform/code/plugins/$f | wc -w | cut -d" " -f1` + #echo $lines + if [ "$lines" -gt "0" ] + then + #As plugin was modified, check if MANIFEST.MF has the version of the release, if not report + #echo $1/platform/code/plugins/$f + #cat $1/platform/code/plugins/$f/META-INF/MANIFEST.MF | grep "Bundle-Version:" + if [[ $1/platform/code/plugins/$f == *platform* ]] ; + then + #echo "platform plugin" + version=`cat $1/platform/code/plugins/$f/META-INF/MANIFEST.MF | grep "Bundle-Version:" | grep $4 | cut -d":" -f2 | tr -d ' '` + if [ "$version" != "$4" ] + then + echo platform/code/plugins/$f >> $7/plugins_to_update.txt + fi + fi + fi +done diff --git a/makefile/scripts/find_changed_plugins.script b/makefile/scripts/find_changed_plugins.script new file mode 100644 index 0000000..8f61598 --- /dev/null +++ b/makefile/scripts/find_changed_plugins.script @@ -0,0 +1,54 @@ +previous_label=$1 + +find emd_tools/android/src -name MANIFEST.MF | sed s/".META-INF.MANIFEST.MF"//g > all_plugins.txt +cleartool find emd_tools/android/src -cview -version "!lbtype($previous_label)" -print | sed s:\\\\:/:g >changed_files.txt 2>/dev/null + +all_plugins=$(cat all_plugins.txt) +changed_files=$(cat changed_files.txt) + +echo DIRECTORY,ID,VERSION,PREVIOUS_VERSION,CHANGED/NEW/UNMODIFIED + +for plugin in $all_plugins +do + echo -n $plugin, + + pluginfile=$plugin/META-INF/MANIFEST.MF + + id=$(cat $pluginfile | grep Bundle-SymbolicName) + id=${id%%;*} + id=${id##* } + echo -n $id + + version=$(cat $pluginfile | grep Bundle-Version) + version=${version##* } + version=$(echo $version | sed s/\n//g) + echo -n ,$version + + previous_version=$(cleartool diff -diff_format $pluginfile@@/main/0 $pluginfile@@/$previous_label 2>/dev/null | grep "Bundle-Version") + previous_version=${previous_version##* } + previous_version=$(echo $previous_version | sed s/\n//g) + + if [ "$previous_version" ] + then + echo -n ,$previous_version + else + echo -n , + fi + + changed=$(echo $changed_files | grep $plugin) + + if [ "$changed" ] + then + if [ "$previous_version" ] + then + echo -n ,CHANGED + else + echo -n ,NEW + fi + else + echo -n ,UNMODIFIED + fi + + echo + +done
\ No newline at end of file diff --git a/makefile/scripts/git_update.sh b/makefile/scripts/git_update.sh new file mode 100644 index 0000000..20ca782 --- /dev/null +++ b/makefile/scripts/git_update.sh @@ -0,0 +1,8 @@ +#!/bin/bash +GIT_BRANCH=`git branch | grep "*" | cut -b 3-` +if [ x$GIT_BRANCH != "x(no branch)" ] +then + git pull origin $GIT_BRANCH +else + echo "No branch set: Have you checked out a branch?" +fi diff --git a/makefile/scripts/motodevstudio.sh b/makefile/scripts/motodevstudio.sh new file mode 100644 index 0000000..edf3e72 --- /dev/null +++ b/makefile/scripts/motodevstudio.sh @@ -0,0 +1,29 @@ +#!/bin/bash + +###################### +# Language Parameter: +###################### +# +# Value: languageID_countryID (The _countryID may be ommited) +# language_ID = An identifier from ISO 639-1 +# country_ID = An identifier from ISO 3166-1 +# +# Uncomment the "LANGUAGE" parameter below to start the MOTODEV Studio for Android in the language you want +# + +#LANGUAGE="-nl en" +#LANGUAGE="-nl pt_BR" + +START_COMMAND=${0%.sh} +unset UBUNTU_MENUPROXY + +# added duo to a eclipse bug: https://bugs.eclipse.org/bugs/show_bug.cgi?id=345979 + +export LIBOVERLAY_SCROLLBAR=0 + +if [ ${START_COMMAND:0:1} == "/" ] +then +$START_COMMAND $@ $LANGUAGE +else +./$START_COMMAND $@ $LANGUAGE +fi diff --git a/makefile/studioBuild.properties b/makefile/studioBuild.properties new file mode 100644 index 0000000..77d26a8 --- /dev/null +++ b/makefile/studioBuild.properties @@ -0,0 +1,21 @@ +#RESOURCES_DIR = ${INPUT_DIR}/resources +OUTPUT_DIR = ${BASE_DIR}/output + +APPVALIDATOR_OUTPUT = ${OUTPUT_DIR}/REPO_APPVALIDATOR +APPVALIDATOR_API_OUTPUT = ${OUTPUT_DIR}/APPVALIDATOR_API + +OUTPUT_DIRECTOR_BASE = ${OUTPUT_DIR}/product +OUTPUT_METADATA_PRODUCT = ${OUTPUT_DIR}/repository_product +OUTPUT_METADATA_STUDIO = ${OUTPUT_DIR}/repository_studio +OUTPUT_METADATA_STUDIO_BASIC = ${OUTPUT_DIR}/repository_studio_basic +OUTPUT_METADATA_STUDIO_FULL = ${OUTPUT_DIR}/repository_full +OUTPUT_UPDATESITE_NDK = ${OUTPUT_DIR}/ndk +OUTPUT_UPDATESITE_ADDITIONS = ${OUTPUT_DIR}/additions +OUTPUT_LANGPACK_INSTALLER = ${LANG_REPOSITORIES_DIR}/REPO_STUDIO_INSTALLER +OUTPUT_LANGPACK_APPVALIDATOR = ${LANG_REPOSITORIES_DIR}/REPO_APPVALIDATOR +OUTPUT_UPDATESITE_LANGPACK = ${LANG_REPOSITORIES_DIR}/REPO_STUDIO_UPDATESITE + +SETTINGS_DIR = ${MAKEFILE}/repository_settings + +REPOSITORY_LIST_BASE = file://${OUTPUT_METADATA_PRODUCT},file://${APPVALIDATOR_OUTPUT},file://${BASE_REPOSITORIES_DIR}/REPO_ADT,file://${BASE_REPOSITORIES_DIR}/REPO_BIRT,file://${BASE_REPOSITORIES_DIR}/REPO_DATATOOLS,file://${BASE_REPOSITORIES_DIR}/REPO_ECLIPSE_PLATFORM,file://${BASE_REPOSITORIES_DIR}/REPO_EMF_XSD_SDO,file://${BASE_REPOSITORIES_DIR}/REPO_GEF,file://${BASE_REPOSITORIES_DIR}/REPO_JDT,file://${BASE_REPOSITORIES_DIR}/REPO_MAT,file://${BASE_REPOSITORIES_DIR}/REPO_PDE,file://${BASE_REPOSITORIES_DIR}/REPO_PROGUARD,file://${BASE_REPOSITORIES_DIR}/REPO_RSS,file://${BASE_REPOSITORIES_DIR}/REPO_SEQUOYAH,file://${BASE_REPOSITORIES_DIR}/REPO_WTP,file://${BASE_REPOSITORIES_DIR}/REPO_MPC,file://${BASE_REPOSITORIES_DIR}/REPO_EQUINOX +REPOSITORY_LIST_EXTRA = file://${EXTRA_REPOSITORIES_DIR}/REPO_CVS,file://${EXTRA_REPOSITORIES_DIR}/REPO_EGIT,file://${EXTRA_REPOSITORIES_DIR}/REPO_SVN,file://${EXTRA_REPOSITORIES_DIR}/REPO_MYLYN
\ No newline at end of file diff --git a/makefile/studioBuild.xml b/makefile/studioBuild.xml new file mode 100644 index 0000000..85c8331 --- /dev/null +++ b/makefile/studioBuild.xml @@ -0,0 +1,556 @@ +<?xml version="1.0" encoding="UTF-8"?> +<project name="MOTODEV Studio for Android" default="generate.release.artifacts"> + + <description> + This Build file generates the Studio Android Product using PDE + P2 infraestructure + USAGE: + ant generate.release.artifacts [to generate Release Artifacts] + ant generate.release.artifacts -Dmotodev.storepass=[storepass] -Dmotodev.keypass=[keypass] [to build the product signing the features and plugins] + </description> + + <!-- define timestamp for build --> + <tstamp> + <format property="timestamp" pattern="ddMMyyyyhhmm" /> + </tstamp> + + <!-- define basic properties --> + <property environment="env" /> + <property name="BASE_DIR" value="${env.BUILD_BASE_PATH}" /> + + <target name="generate.release.artifacts" depends="devQualifier, releaseQualifier" description="Generate Release Artifacts"> + + <property file="${BASE_DIR}/env/code/android/makefile/common.properties" /> + <property file="${BASE_DIR}/env/code/android/makefile/studioBuild.properties" /> + <!-- property file="${BASE_DIR}/input/sign/jarsigner.properties" / --> + + <available file="${BASE_DIR}/buildplatform" property="buildplatform" /> + + <antcall target="init" /> + + <mkdir dir="${OUTPUT_DIR}/output" /> + + <antcall target="check_plugins_needing_version_update" /> + + <!-- antcall target="build.app.validator.product" /--> + + <antcall target="build.studio.repositories" /> + + <antcall target="generate.repository.packages" /> + + <antcall target="generate.updatesite.repositories.packages" /> + + <antcall target="calculate_checksums" /> + + <!--antcall target="automated_tests" --> + + </target> + + <target name="automated_tests"> + <echo level="info" message="studioBuild.xml Automated Tests target"/> + <exec executable="chmod"> + <arg value="a+x" /> + <arg value="${MAKEFILE}/autotest.sh" /> + </exec> + <exec executable="${MAKEFILE}/autotest.sh" output="/android/tests/autotest_output.log"/> + </target> + + <target name="generate.updatesite.repositories.packages"> + + <ant antfile="${MAKEFILE}/studioRepositoryUtils.xml" target="genAdditionsArchive" /> + + <ant antfile="${MAKEFILE}/studioRepositoryUtils.xml" target="genNativeArchive" /> + + + </target> + + <!-- initialize build (remove all previous output and copy source to a temporary location) --> + <target name="init"> + <defaultexcludes add="**/*.contrib" /> + <delete includeemptydirs="true" failonerror="false"> + <fileset dir="${OUTPUT_DIR}/" includes="**/*" /> + </delete> + <delete includeemptydirs="true" failonerror="false"> + <fileset dir="${user.home}/workspace" includes="**/**" /> + </delete> + </target> + + <target name="clearSettings"> + <delete failonerror="false" includeEmptyDirs="true" verbose="true"> + <fileset dir="${eclipse.builder.path}/configuration/.settings/" includes="**/**" /> + <fileset dir="${eclipse.builder.path}/p2/org.eclipse.equinox.p2.core/cache/" includes="**/**" /> + <fileset dir="${eclipse.builder.path}/p2/org.eclipse.equinox.p2.engine/.settings/" includes="**/**" /> + <fileset dir="${eclipse.builder.path}/p2/org.eclipse.equinox.p2.engine/profileRegistry/" includes="**/**" excludes="**/SDKProfile.profile/**" /> + </delete> + </target> + + <target name="check_plugins_needing_version_update"> + <echo level="info"> + Calling checkmodifications with the following arguments: + ${MAKEFILE}/scripts/checkmodifications.sh ${GIT_REPOSITORY_PATH} APP-VALIDATOR_N_00.09.100I_B001 ${studioVersion} ${platformVersion} ${appvalidatorVersion} ${appvalidatorUIVersion} ${OUTPUT_DIR}/output + </echo> + <exec executable="${MAKEFILE}/scripts/checkmodifications.sh"> + <!-- path to git code --> + <arg value="${GIT_REPOSITORY_PATH}" /> + <!-- label to serve as base to check modifications --> + <!-- Latest studio label: STUDIO-ANDROID_N_03.01.00I_B003 --> + <arg value="STUDIO-ANDROID_N_04.00.00I_B003" /> + <!-- studio version --> + <arg value="${studioVersion}" /> + <!-- platform version --> + <arg value="${platformVersion}" /> + <!-- app validator version --> + <arg value="${appvalidatorVersion}" /> + <!-- app validator ui version --> + <arg value="${appvalidatorUIVersion}" /> + <!-- output folder --> + <arg value="${OUTPUT_DIR}/output" /> + </exec> + </target> + + <target name="generate.repository.packages" description="Pack repositories within zip packages"> + <!-- Besides installers, the MOTODEV Studio Repositories are outputs too--> + <zip destfile="${OUTPUT_DIR}/output/repository_studio.zip" basedir="${OUTPUT_METADATA_PRODUCT}" /> + <zip destfile="${OUTPUT_DIR}/output/repository_basic.zip" basedir="${OUTPUT_METADATA_STUDIO_BASIC}" /> + <zip destfile="${OUTPUT_DIR}/output/MOTODEV_Studio_for_Android_${studioVersion}_Archive.zip" basedir="${OUTPUT_METADATA_STUDIO_FULL}" /> + <zip destfile="${OUTPUT_DIR}/output/repository_appvalidator.zip" basedir="${APPVALIDATOR_OUTPUT}" /> + <zip destfile="${OUTPUT_DIR}/output/javadoc_appvalidator.zip" basedir="${APPVALIDATOR_API_OUTPUT}" /> + </target> + + <target name="calculate_checksums"> + <checksum fileext=".MD5.txt" format="MD5SUM"> + <fileset dir="${OUTPUT_DIR}/output" excludes="*.MD5.txt" /> + </checksum> + <concat destfile="${OUTPUT_DIR}/output/md5sums.txt" binary="yes"> + <fileset dir="${OUTPUT_DIR}/output" includes="*.MD5.txt" /> + </concat> + <delete> + <fileset dir="${OUTPUT_DIR}/output/" includes="*.MD5.txt" /> + </delete> + </target> + + <!-- ============================================================================================== --> + <!-- GENERATE FULL PRODUCT --> + <!-- ============================================================================================== --> + <target name="generate_full_product"> + + <antcall target="p2_director"> + <param name="installable_unit" value="org.eclipse.mylyn_feature.feature.group" /> + <param name="operating_system" value="${operating_system}" /> + <param name="windowing_system" value="${windowing_system}" /> + <param name="arch" value="${arch}" /> + <param name="REPO_LIST" value=""${REPOSITORY_LIST_BASE},${REPOSITORY_LIST_EXTRA}"" /> + </antcall> + + <antcall target="p2_director"> + <param name="installable_unit" value="org.eclipse.mylyn.context_feature.feature.group" /> + <param name="operating_system" value="${operating_system}" /> + <param name="windowing_system" value="${windowing_system}" /> + <param name="arch" value="${arch}" /> + <param name="REPO_LIST" value=""${REPOSITORY_LIST_BASE},${REPOSITORY_LIST_EXTRA}"" /> + </antcall> + + <antcall target="p2_director"> + <param name="installable_unit" value="org.eclipse.cvs.feature.group" /> + <param name="operating_system" value="${operating_system}" /> + <param name="windowing_system" value="${windowing_system}" /> + <param name="arch" value="${arch}" /> + <param name="REPO_LIST" value=""${REPOSITORY_LIST_BASE},${REPOSITORY_LIST_EXTRA}"" /> + </antcall> + + <antcall target="p2_director"> + <param name="installable_unit" value="org.eclipse.team.svn.feature.group" /> + <param name="operating_system" value="${operating_system}" /> + <param name="windowing_system" value="${windowing_system}" /> + <param name="arch" value="${arch}" /> + <param name="REPO_LIST" value=""${REPOSITORY_LIST_BASE},${REPOSITORY_LIST_EXTRA}"" /> + </antcall> + + <antcall target="p2_director"> + <param name="installable_unit" value="org.eclipse.team.svn.feature.group" /> + <param name="operating_system" value="${operating_system}" /> + <param name="windowing_system" value="${windowing_system}" /> + <param name="arch" value="${arch}" /> + <param name="REPO_LIST" value=""${REPOSITORY_LIST_BASE},${REPOSITORY_LIST_EXTRA}"" /> + </antcall> + + <antcall target="p2_director"> + <param name="installable_unit" value="org.eclipse.egit.feature.group" /> + <param name="operating_system" value="${operating_system}" /> + <param name="windowing_system" value="${windowing_system}" /> + <param name="arch" value="${arch}" /> + <param name="REPO_LIST" value=""${REPOSITORY_LIST_BASE},${REPOSITORY_LIST_EXTRA}"" /> + </antcall> + + </target> + + + <!-- ============================================================================================== --> + <!-- GENERATE PRODUCT --> + <!-- ============================================================================================== --> + + <target name="generate_basic_product"> + <mkdir dir="${OUTPUT_DIRECTOR_BASE}/${operating_system}_${windowing_system}_${arch}" /> + + <!-- antcall target="p2_director"> + <param name="installable_unit" value="com.motorola.studio.android.product.android" /> + <param name="operating_system" value="${operating_system}" /> + <param name="windowing_system" value="${windowing_system}" /> + <param name="arch" value="${arch}" /> + <param name="REPO_LIST" value=""${REPOSITORY_LIST_BASE}"" /> + </antcall --> + + + <!-- Install things as top features (prevents p2 bug). Can be removed when p2 bug going to be fixed + https://bugs.eclipse.org/bugs/show_bug.cgi?id=313979 + --> + + <antcall target="p2_director"> + <param name="installable_unit" value="com.motorolamobility.preflighting.feature.feature.group" /> + <param name="operating_system" value="${operating_system}" /> + <param name="windowing_system" value="${windowing_system}" /> + <param name="arch" value="${arch}" /> + <param name="REPO_LIST" value=""${REPOSITORY_LIST_BASE}"" /> + </antcall> + + <antcall target="p2_director"> + <param name="installable_unit" value="com.motorolamobility.preflighting.sdk.feature.feature.group" /> + <param name="operating_system" value="${operating_system}" /> + <param name="windowing_system" value="${windowing_system}" /> + <param name="arch" value="${arch}" /> + <param name="REPO_LIST" value=""${REPOSITORY_LIST_BASE}"" /> + </antcall> + + <antcall target="p2_director"> + <param name="installable_unit" value="com.motorolamobility.preflighting.ui.feature.feature.group" /> + <param name="operating_system" value="${operating_system}" /> + <param name="windowing_system" value="${windowing_system}" /> + <param name="arch" value="${arch}" /> + <param name="REPO_LIST" value=""${REPOSITORY_LIST_BASE}"" /> + </antcall> + + <antcall target="p2_director"> + <param name="installable_unit" value="org.eclipse.datatools.enablement.sqlite.feature.feature.group" /> + <param name="operating_system" value="${operating_system}" /> + <param name="windowing_system" value="${windowing_system}" /> + <param name="arch" value="${arch}" /> + <param name="REPO_LIST" value=""${REPOSITORY_LIST_BASE}"" /> + </antcall> + + <antcall target="p2_director"> + <param name="installable_unit" value="org.eclipse.datatools.doc.user.feature.group" /> + <param name="operating_system" value="${operating_system}" /> + <param name="windowing_system" value="${windowing_system}" /> + <param name="arch" value="${arch}" /> + <param name="REPO_LIST" value=""${REPOSITORY_LIST_BASE}"" /> + </antcall> + + <antcall target="p2_director"> + <param name="installable_unit" value="org.eclipse.gef.feature.group" /> + <param name="operating_system" value="${operating_system}" /> + <param name="windowing_system" value="${windowing_system}" /> + <param name="arch" value="${arch}" /> + <param name="REPO_LIST" value=""${REPOSITORY_LIST_BASE}"" /> + </antcall> + + <antcall target="p2_director"> + <param name="installable_unit" value="org.eclipse.mat.feature.feature.group" /> + <param name="operating_system" value="${operating_system}" /> + <param name="windowing_system" value="${windowing_system}" /> + <param name="arch" value="${arch}" /> + <param name="REPO_LIST" value=""${REPOSITORY_LIST_BASE}"" /> + </antcall> + + <antcall target="p2_director"> + <param name="installable_unit" value="org.eclipse.mat.chart.feature.feature.group" /> + <param name="operating_system" value="${operating_system}" /> + <param name="windowing_system" value="${windowing_system}" /> + <param name="arch" value="${arch}" /> + <param name="REPO_LIST" value=""${REPOSITORY_LIST_BASE}"" /> + </antcall> + + <antcall target="p2_director"> + <param name="installable_unit" value="org.eclipse.sequoyah.device.feature.feature.group" /> + <param name="operating_system" value="${operating_system}" /> + <param name="windowing_system" value="${windowing_system}" /> + <param name="arch" value="${arch}" /> + <param name="REPO_LIST" value=""${REPOSITORY_LIST_BASE}"" /> + </antcall> + + <antcall target="p2_director"> + <param name="installable_unit" value="org.eclipse.sequoyah.localization.tools.feature.feature.group" /> + <param name="operating_system" value="${operating_system}" /> + <param name="windowing_system" value="${windowing_system}" /> + <param name="arch" value="${arch}" /> + <param name="REPO_LIST" value=""${REPOSITORY_LIST_BASE}"" /> + </antcall> + + <antcall target="p2_director"> + <param name="installable_unit" value="org.eclipse.sequoyah.localization.android.feature.feature.group" /> + <param name="operating_system" value="${operating_system}" /> + <param name="windowing_system" value="${windowing_system}" /> + <param name="arch" value="${arch}" /> + <param name="REPO_LIST" value=""${REPOSITORY_LIST_BASE}"" /> + </antcall> + + <antcall target="p2_director"> + <param name="installable_unit" value="org.eclipse.wst.common.fproj.feature.group" /> + <param name="operating_system" value="${operating_system}" /> + <param name="windowing_system" value="${windowing_system}" /> + <param name="arch" value="${arch}" /> + <param name="REPO_LIST" value=""${REPOSITORY_LIST_BASE}"" /> + </antcall> + + <antcall target="p2_director"> + <param name="installable_unit" value="org.eclipse.wst.jsdt.feature.feature.group" /> + <param name="operating_system" value="${operating_system}" /> + <param name="windowing_system" value="${windowing_system}" /> + <param name="arch" value="${arch}" /> + <param name="REPO_LIST" value=""${REPOSITORY_LIST_BASE}"" /> + </antcall> + + <antcall target="p2_director"> + <param name="installable_unit" value="org.eclipse.wst.jsdt.feature.feature.group" /> + <param name="operating_system" value="${operating_system}" /> + <param name="windowing_system" value="${windowing_system}" /> + <param name="arch" value="${arch}" /> + <param name="REPO_LIST" value=""${REPOSITORY_LIST_BASE}"" /> + </antcall> + + <antcall target="p2_director"> + <param name="installable_unit" value="org.eclipse.wst.server_adapters.feature.feature.group" /> + <param name="operating_system" value="${operating_system}" /> + <param name="windowing_system" value="${windowing_system}" /> + <param name="arch" value="${arch}" /> + <param name="REPO_LIST" value=""${REPOSITORY_LIST_BASE}"" /> + </antcall> + + <antcall target="p2_director"> + <param name="installable_unit" value="org.eclipse.wst.web_ui.feature.feature.group" /> + <param name="operating_system" value="${operating_system}" /> + <param name="windowing_system" value="${windowing_system}" /> + <param name="arch" value="${arch}" /> + <param name="REPO_LIST" value=""${REPOSITORY_LIST_BASE}"" /> + </antcall> + + <antcall target="p2_director"> + <param name="installable_unit" value="org.eclipse.wst.xml_ui.feature.feature.group" /> + <param name="operating_system" value="${operating_system}" /> + <param name="windowing_system" value="${windowing_system}" /> + <param name="arch" value="${arch}" /> + <param name="REPO_LIST" value=""${REPOSITORY_LIST_BASE}"" /> + </antcall> + + <antcall target="p2_director"> + <param name="installable_unit" value="org.eclipse.wst.xml_core.feature.feature.group" /> + <param name="operating_system" value="${operating_system}" /> + <param name="windowing_system" value="${windowing_system}" /> + <param name="arch" value="${arch}" /> + <param name="REPO_LIST" value=""${REPOSITORY_LIST_BASE}"" /> + </antcall> + + <antcall target="p2_director"> + <param name="installable_unit" value="org.eclipse.wst.xsl.feature.feature.group" /> + <param name="operating_system" value="${operating_system}" /> + <param name="windowing_system" value="${windowing_system}" /> + <param name="arch" value="${arch}" /> + <param name="REPO_LIST" value=""${REPOSITORY_LIST_BASE}"" /> + </antcall> + + <antcall target="p2_director"> + <param name="installable_unit" value="net.certiv.proguarddt.feature.feature.group" /> + <param name="operating_system" value="${operating_system}" /> + <param name="windowing_system" value="${windowing_system}" /> + <param name="arch" value="${arch}" /> + <param name="REPO_LIST" value=""${REPOSITORY_LIST_BASE}"" /> + </antcall> + + <antcall target="p2_director"> + <param name="installable_unit" value="org.eclipse.pde.feature.group" /> + <param name="operating_system" value="${operating_system}" /> + <param name="windowing_system" value="${windowing_system}" /> + <param name="arch" value="${arch}" /> + <param name="REPO_LIST" value=""${REPOSITORY_LIST_BASE}"" /> + </antcall> + + <!-- create dropins folder --> + <mkdir dir="${OUTPUT_DIRECTOR_BASE}/${operating_system}_${windowing_system}_${arch}/dropins" /> + + <!-- remove p2 cache --> + <delete includeemptydirs="true" failonerror="false"> + <fileset dir="${OUTPUT_DIRECTOR_BASE}/${operating_system}_${windowing_system}_${arch}/p2/org.eclipse.equinox.p2.core/" includes="**/*" /> + </delete> + <delete includeemptydirs="true" failonerror="false"> + <fileset dir="${OUTPUT_DIRECTOR_BASE}/${operating_system}_${windowing_system}_${arch}/p2/org.eclipse.equinox.p2.director/" includes="**/*" /> + </delete> + <delete includeemptydirs="true" failonerror="false"> + <fileset dir="${OUTPUT_DIRECTOR_BASE}/${operating_system}_${windowing_system}_${arch}/p2/org.eclipse.equinox.p2.engine/.settings/" includes="**/*" /> + </delete> + + <!-- copy repository list to the product --> + <mkdir dir="${OUTPUT_DIRECTOR_BASE}/${operating_system}_${windowing_system}_${arch}/p2/org.eclipse.equinox.p2.engine/profileRegistry/MOTODEV_Profile_Android.profile/.data/.settings" /> + <copy todir="${OUTPUT_DIRECTOR_BASE}/${operating_system}_${windowing_system}_${arch}/p2/org.eclipse.equinox.p2.engine/profileRegistry/MOTODEV_Profile_Android.profile/.data/.settings" overwrite="true" failonerror="true"> + <fileset dir="${SETTINGS_DIR}" includes="**/*" /> + </copy> + + <copy todir="${OUTPUT_DIRECTOR_BASE}/${operating_system}_${windowing_system}_${arch}/plugins" overwrite="true" failonerror="true"> + <fileset dir="${OUTPUT_METADATA_PRODUCT}/plugins" includes="com.motorola.studio.android.common*"/> + </copy> + + </target> + + <!-- ============================================================================================== --> + <!-- P2 Director ant --> + <!-- ============================================================================================== --> + <target name="p2_director"> + <echo level="info" message="${BASE_DIR}/env/eclipse/eclipse -noSplash -clean -application org.eclipse.equinox.p2.director.app.application -metadataRepository ${REPO_LIST} -artifactRepository ${REPO_LIST} -installIU ${installable_unit} -version ${installable_unit_version} -destination ${OUTPUT_DIRECTOR_BASE}/${operating_system}_${windowing_system}_${arch} -bundlepool ${OUTPUT_DIRECTOR_BASE}/${operating_system}_${windowing_system}_${arch} -profile MOTODEV_Profile_Android -p2.os ${operating_system} -p2.ws ${windowing_system} -p2.arch ${arch} -roaming -vmArgs -Xms256M -Xmx512M -Declipse.p2.data.area=${OUTPUT_DIRECTOR_BASE}/${operating_system}_${windowing_system}_${arch}/p2" /> + <java failonerror="true" jar="${eclipse.builder.path}/plugins/${eclipse.builder.launcher}" fork="true"> + <arg line="-application org.eclipse.equinox.p2.director" /> + <arg line="-metadataRepository ${REPO_LIST}" /> + <arg line="-artifactRepository ${REPO_LIST}" /> + <arg line="-installIU ${installable_unit}" /> + <arg line="-destination ${OUTPUT_DIRECTOR_BASE}/${operating_system}_${windowing_system}_${arch}" /> + <arg line="-bundlepool ${OUTPUT_DIRECTOR_BASE}/${operating_system}_${windowing_system}_${arch}" /> + <arg line="-profile MOTODEV_Profile_Android" /> + <arg line="-profileProperties org.eclipse.update.install.features=true" /> + <arg line="-p2.os ${operating_system}" /> + <arg line="-p2.ws ${windowing_system}" /> + <arg line="-p2.arch ${arch}" /> + <arg line="-roaming" /> + <arg line="-vmArgs -Xms256M -Xmx512M -Declipse.p2.data.area=${OUTPUT_DIRECTOR_BASE}/${operating_system}_${windowing_system}_${arch}/p2" /> + </java> + + </target> + + <target name="devQualifier" if="env.DEV_RELEASE"> + <property name="forceContextQualifier" value="${timestamp}" /> + </target> + + <target name="releaseQualifier" unless="env.DEV_RELEASE"> + <property name="forceContextQualifier" value="release" /> + </target> + + <target name="createBuildDirectory"> + <delete includeemptydirs="true" failonerror="false"> + <fileset dir="${buildDirectory}" includes="**/**" /> + </delete> + + <mkdir dir="${buildDirectory}" /> + + <copy todir="${buildDirectory}" file="${builder}/customTargets.xml" /> + <copy todir="${buildDirectory}" file="${builder}/customAssembly.xml" failonerror="false" /> + <copy tofile="${buildDirectory}/tmpbuild.properties" file="${builder}/build.properties" /> + <copy todir="${buildDirectory}" file="${MAKEFILE}/common.properties" /> + + <concat destfile="${buildDirectory}/build.properties" binary="yes"> + <fileset dir="${buildDirectory}/" includes="*.properties" /> + </concat> + </target> + + + <target name="build.studio.repositories" depends="build.app.validator.repositories"> + <antcall target="clearSettings" /> + + <property name="studioBuildDir" value="/tmp/studio_android_build_${studioVersion}" /> + + <antcall target="createBuildDirectory"> + <param name="buildDirectory" value="${studioBuildDir}" /> + <param name="builder" value="${MAKEFILE}" /> + </antcall> + + <java failonerror="true" jar="${eclipse.builder.path}/plugins/${eclipse.builder.launcher}" fork="true"> + <jvmarg value="-Xmx1024m" /> + <jvmarg value="-Xms80m" /> + <arg value="-application" /> + <arg value="org.eclipse.ant.core.antRunner" /> + <arg value="-buildfile" /> + <!-- arg value="${eclipse.builder.path}/plugins/${eclipse.builder.pde}/scripts/productBuild/productBuild.xml" /--> + <arg value="${eclipse.builder.path}/plugins/${eclipse.builder.pde}/scripts/build.xml" /> + <arg value="-Dbuilder=${studioBuildDir}/" /> + <!-- arg value="-Dmotodev.storepass=${motodev.storepass}" /> + <arg value="-Dmotodev.keypass=${motodev.keypass}" / --> + <arg value="-DBASE_DIR=${BASE_DIR}" /> + <arg value="-Dtimestamp=${timestamp}" /> + <arg value="-DforceContextQualifier=${forceContextQualifier}" /> + <arg value="-DrepoBaseLocation=${BASE_REPOSITORIES_DIR}" /> + <arg value="-DtransformedRepoLocation=${INPUT_DIR}/transformedRepos" /> + <arg value="-DbuildDirectory=${studioBuildDir}" /> + <arg value="-DbaseLocation=${eclipse.builder.path}" /> + <arg value="-DoutputDirectory=${OUTPUT_METADATA_PRODUCT}" /> + </java> + + <ant antfile="${MAKEFILE}/studioRepositoryUtils.xml" target="mergeAppValidatorAndStudioRepositories" /> + + <ant antfile="${MAKEFILE}/studioRepositoryUtils.xml" target="genFullRepo" /> + + <ant antfile="${MAKEFILE}/studioRepositoryUtils.xml" target="createSimpleBasicRepository" /> + + </target> + + <target name="build.app.validator.repositories"> + + <antcall target="clearSettings" /> + + <property name="appvalBuildDir" value="/tmp/application_validator_build_${appvalidatorVersion}" /> + + <antcall target="createBuildDirectory"> + <param name="buildDirectory" value="${appvalBuildDir}" /> + <param name="builder" value="${MAKEFILE}/preflighting/" /> + </antcall> + + + <java failonerror="true" jar="${eclipse.builder.path}/plugins/${eclipse.builder.launcher}" fork="true"> + <jvmarg value="-Xmx1024m" /> + <jvmarg value="-Xms80m" /> + <arg value="-application" /> + <arg value="org.eclipse.ant.core.antRunner" /> + <arg value="-buildfile" /> + <arg value="${eclipse.builder.path}/plugins/${eclipse.builder.pde}/scripts/productBuild/productBuild.xml" /> + <!-- arg value="${eclipse.builder.path}/plugins/${eclipse.builder.pde}/scripts/build.xml" /--> + <arg value="-Dbuilder=${appvalBuildDir}" /> + <!-- arg value="-Dmotodev.storepass=${motodev.storepass}" /> + <arg value="-Dmotodev.keypass=${motodev.keypass}" / --> + <arg value="-DBASE_DIR=${BASE_DIR}" /> + <arg value="-Dtimestamp=${timestamp}" /> + <arg value="-DforceContextQualifier=${forceContextQualifier}" /> + <arg value="-DrepoBaseLocation=${BASE_REPOSITORIES_DIR}" /> + <arg value="-DtransformedRepoLocation=${INPUT_DIR}/transformedRepos" /> + <arg value="-DbuildDirectory=${appvalBuildDir}" /> + <arg value="-DbaseLocation=${eclipse.builder.path}" /> + <arg value="-DoutputDirectory=${APPVALIDATOR_OUTPUT}" /> + <arg value="-DappValidatorJavadocOutputDirectory=${APPVALIDATOR_API_OUTPUT}" /> + </java> + </target> + + <target name="build.app.validator.product"> + + <antcall target="clearSettings" /> + + <property name="appvalProductBuildDir" value="/tmp/application_validator_product_build_${appvalidatorVersion}" /> + + <antcall target="createBuildDirectory"> + <param name="buildDirectory" value="${appvalProductBuildDir}" /> + <param name="builder" value="${MAKEFILE}/preflighting/product/" /> + </antcall> + + <java failonerror="true" jar="${eclipse.builder.path}/plugins/${eclipse.builder.launcher}" fork="true"> + <jvmarg value="-Xmx1024m" /> + <jvmarg value="-Xms80m" /> + <arg value="-application" /> + <arg value="org.eclipse.ant.core.antRunner" /> + <arg value="-buildfile" /> + <arg value="${eclipse.builder.path}/plugins/${eclipse.builder.pde}/scripts/productBuild/productBuild.xml" /> + <arg value="-Dbuilder=${appvalProductBuildDir}" /> + <!-- arg value="-Dmotodev.storepass=${motodev.storepass}" /> + <arg value="-Dmotodev.keypass=${motodev.keypass}" / --> + <arg value="-DBASE_DIR=${BASE_DIR}" /> + <arg value="-Dtimestamp=${timestamp}" /> + <arg value="-DforceContextQualifier=${forceContextQualifier}" /> + <arg value="-DrepoBaseLocation=${BASE_REPOSITORIES_DIR}" /> + <arg value="-DtransformedRepoLocation=${INPUT_DIR}/transformedRepos" /> + <arg value="-DbuildDirectory=${appvalProductBuildDir}" /> + <arg value="-DbaseLocation=${eclipse.builder.path}" /> + <arg value="-DoutputDirectory=${OUTPUT_DIR}/output" /> + </java> + </target> + +</project> diff --git a/makefile/studioRepositoryUtils.xml b/makefile/studioRepositoryUtils.xml new file mode 100644 index 0000000..f405f5f --- /dev/null +++ b/makefile/studioRepositoryUtils.xml @@ -0,0 +1,271 @@ +<?xml version="1.0" encoding="UTF-8"?> +<project name="MOTODEV Studio for Android" default="noDefault"> + + <target name="createSiteXML"> + <echoxml file="/tmp/site.xml"> + <site> + <feature url="features/${studioFeatureName}.${studioFeatureVersion}.jar" id="${studioFeatureName}" version="${studioFeatureVersion}"> + <category name="MOTODEVStudioforAndroid" /> + </feature> + <category-def name="MOTODEVStudioforAndroid" label="MOTODEV Studio for Android" /> + <feature url="features/${appValidatorFeatureName}.${appValidatorFeatureVersion}.jar" id="${appValidatorFeatureName}" version="${appValidatorFeatureVersion}"> + <category name="MOTODEVStudioforAndroid" /> + </feature> + <feature url="features/${appValidatorUIFeatureName}.${appValidatorUIFeatureVersion}.jar" id="${appValidatorUIFeatureName}" version="${appValidatorUIFeatureVersion}"> + <category name="MOTODEVStudioforAndroid" /> + </feature> + <feature url="features/${appValidatorSDKFeatureName}.${appValidatorSDKFeatureVersion}.jar" id="${appValidatorSDKFeatureName}" version="${appValidatorSDKFeatureVersion}"> + <category name="MOTODEVStudioforAndroid" /> + </feature> + </site> + </echoxml> + </target> + + <!-- Was called by generate.language.packs --> + <target name="createSimpleRepository"> + <antcall target="createSiteXML" /> + <p2.mirror source="${OUTPUT_METADATA_PRODUCT}" destination="file:/${OUTPUT_METADATA_STUDIO}" raw="false"> + <iu id="com.motorola.studio.android.feature.feature.group" /> + <iu id="com.motorolamobility.preflighting.ui.feature.feature.group" /> + <iu id="com.motorolamobility.preflighting.feature.feature.group" /> + <iu id="com.motorolamobility.preflighting.sdk.feature.feature.group" /> + <slicingoptions followstrict="true" includeoptional="false" includenongreedy="false" followonlyfilteredrequirements="true" includefeatures="true" /> + </p2.mirror> + + <eclipse.publish.featuresAndBundles append="true" artifactrepository="file:/${OUTPUT_METADATA_STUDIO}" artifactrepositoryname="MOTODEV Studio for Android Repository" metadatarepository="file:/${OUTPUT_METADATA_STUDIO}" metadatarepositoryname="MOTODEV Studio for Android Repository" site="file:/tmp/site.xml"> + + <features dir="${OUTPUT_METADATA_PRODUCT}" includes="features/com.motorola.studio.android.feature*" /> + <features dir="${OUTPUT_METADATA_PRODUCT}" includes="features/com.motorolamobility.preflighting*" /> + <bundles dir="${OUTPUT_METADATA_PRODUCT}" includes="plugins/com.motorola.studio.android*" /> + <bundles dir="${OUTPUT_METADATA_PRODUCT}" includes="plugins/com.motorolamobility.studio.android*" /> + <bundles dir="${OUTPUT_METADATA_PRODUCT}" includes="plugins/com.motorolamobility.preflighting*" /> + </eclipse.publish.featuresAndBundles> + </target> + + <target name="createBasicSiteXML"> + <echoxml file="/tmp/basicsite.xml"> + <site> + <category-def name="MOTODEVStudioforAndroidBasic" label="MOTODEV Studio for Android Core" /> + <feature url="features/com.motorola.studio.android.basic.feature.${studioFeatureVersion}.jar" id="com.motorola.studio.android.basic.feature" version="${studioFeatureVersion}"> + <category name="MOTODEVStudioforAndroidBasic" /> + </feature> + <category-def name="MOTODEVStudioforAndroid" label="MOTODEV Studio for Android App Validator" /> + <feature url="features/${appValidatorFeatureName}.${appValidatorFeatureVersion}.jar" id="${appValidatorFeatureName}" version="${appValidatorFeatureVersion}"> + <category name="MOTODEVStudioforAndroid" /> + </feature> + <feature url="features/${appValidatorUIFeatureName}.${appValidatorUIFeatureVersion}.jar" id="${appValidatorUIFeatureName}" version="${appValidatorUIFeatureVersion}"> + <category name="MOTODEVStudioforAndroid" /> + </feature> + <feature url="features/${appValidatorSDKFeatureName}.${appValidatorSDKFeatureVersion}.jar" id="${appValidatorSDKFeatureName}" version="${appValidatorSDKFeatureVersion}"> + <category name="MOTODEVStudioforAndroid" /> + </feature> + </site> + </echoxml> + </target> + + <target name="createSimpleBasicRepository"> + <antcall target="createBasicSiteXML" /> + <mkdir dir="${OUTPUT_METADATA_STUDIO_BASIC}"/> + <copy tofile="${OUTPUT_METADATA_STUDIO_BASIC}/content.xml" file="${MAKEFILE}/repository_skel/content_basic.xml"/> + <p2.mirror source="${OUTPUT_METADATA_STUDIO_FULL}" destination="file:/${OUTPUT_METADATA_STUDIO_BASIC}" raw="false"> + <iu id="com.motorola.studio.android.basic.feature.feature.group" /> + <iu id="com.motorolamobility.preflighting.ui.feature.feature.group" /> + <iu id="com.motorolamobility.preflighting.feature.feature.group" /> + <iu id="com.motorolamobility.preflighting.sdk.feature.feature.group" /> + <slicingoptions followstrict="true" includeoptional="false" includenongreedy="false" followonlyfilteredrequirements="true" includefeatures="true" /> + </p2.mirror> + + <eclipse.publish.featuresAndBundles append="true" artifactrepository="file:/${OUTPUT_METADATA_STUDIO_BASIC}" artifactrepositoryname="MOTODEV Studio for Android Core Repository" metadatarepository="file:/${OUTPUT_METADATA_STUDIO_BASIC}" metadatarepositoryname="MOTODEV Studio for Android Core Repository" site="file:/tmp/basicsite.xml"> + <features dir="${OUTPUT_METADATA_STUDIO_FULL}" includes="features/com.motorola.studio.android.basic.feature*" /> + <features dir="${OUTPUT_METADATA_STUDIO_FULL}" includes="features/com.motorolamobility.preflighting*" /> + <bundles dir="${OUTPUT_METADATA_STUDIO_FULL}" includes="plugins/com.motorola.studio.android.common*" /> + <bundles dir="${OUTPUT_METADATA_STUDIO_FULL}" includes="plugins/com.motorola.studio.android.codeutils*"/> + <bundles dir="${OUTPUT_METADATA_STUDIO_FULL}" includes="plugins/com.motorolamobility.studio.android.db.core*"/> + <bundles dir="${OUTPUT_METADATA_STUDIO_FULL}" includes="plugins/com.motorola.studio.android.translation*"/> + <bundles dir="${OUTPUT_METADATA_STUDIO_FULL}" includes="plugins/com.motorola.studio.android.codesnippets*"/> + <bundles dir="${OUTPUT_METADATA_STUDIO_FULL}" includes="plugins/com.motorolamobility.studio.android.certmanager*"/> + <bundles dir="${OUTPUT_METADATA_STUDIO_FULL}" includes="plugins/com.motorolamobility.studio.android.logger*"/> + <bundles dir="${OUTPUT_METADATA_STUDIO_FULL}" includes="plugins/com.motorolamobility.preflighting*" /> + <bundles dir="${OUTPUT_METADATA_STUDIO_FULL}" includes="plugins/com.motorolamobility.studio.android*" /> + <bundles dir="${OUTPUT_METADATA_STUDIO_FULL}" includes="binary/com.motorolamobility.preflighting*" /> + </eclipse.publish.featuresAndBundles> + + <!-- run the category publisher.. there is no ant task to execute it --> + <java failonerror="true" jar="${eclipse.builder.path}/plugins/${eclipse.builder.launcher}" fork="true"> + <arg value="-application" /> + <arg value="org.eclipse.equinox.p2.publisher.CategoryPublisher" /> + <arg value="-metadataRepository" /> + <arg value="file:/${OUTPUT_METADATA_STUDIO_BASIC}" /> + <arg value="-categoryDefinition" /> + <arg value="file:/tmp/basicsite.xml" /> + </java> + </target> + + <target name="mergeAppValidatorAndStudioRepositories"> + <antcall target="createSiteXML" /> + <p2.mirror destination="${OUTPUT_METADATA_PRODUCT}" source="file:${APPVALIDATOR_OUTPUT}" /> + <java failonerror="true" jar="${eclipse.builder.path}/plugins/${eclipse.builder.launcher}" fork="true"> + <arg value="-application" /> + <arg value="org.eclipse.equinox.p2.publisher.CategoryPublisher" /> + <arg value="-metadataRepository" /> + <arg value="file:/${OUTPUT_METADATA_PRODUCT}" /> + <arg value="-categoryDefinition" /> + <arg value="file:/tmp/site.xml" /> + </java> + </target> + + <target name="genFullRepo"> + <antcall target="createSiteXML" /> + <p2.mirror destination="file:/${OUTPUT_METADATA_STUDIO_FULL}" raw="false"> + <slicingoptions followstrict="true" includefeatures="true" /> + <source> + <repository location="file:${OUTPUT_METADATA_PRODUCT}" /> + <repository location="file://${BASE_REPOSITORIES_DIR}/REPO_ADT" /> + <repository location="file://${BASE_REPOSITORIES_DIR}/REPO_ECLIPSE_PLATFORM" /> + <repository location="file://${BASE_REPOSITORIES_DIR}/REPO_EMF_XSD_SDO" /> + <repository location="file://${BASE_REPOSITORIES_DIR}/REPO_GEF" /> + <repository location="file://${BASE_REPOSITORIES_DIR}/REPO_SEQUOYAH" /> + <repository location="file://${BASE_REPOSITORIES_DIR}/REPO_JDT" /> + <repository location="file://${BASE_REPOSITORIES_DIR}/REPO_WTP" /> + <repository location="file://${BASE_REPOSITORIES_DIR}/REPO_DATATOOLS" /> + <repository location="file://${BASE_REPOSITORIES_DIR}/REPO_RSS" /> + <repository location="file://${BASE_REPOSITORIES_DIR}/REPO_BIRT" /> + <repository location="file://${BASE_REPOSITORIES_DIR}/REPO_MAT" /> + <repository location="file://${BASE_REPOSITORIES_DIR}/REPO_PROGUARD" /> + <repository location="file://${BASE_REPOSITORIES_DIR}/REPO_PDE" /> + <repository location="file://${BASE_REPOSITORIES_DIR}/REPO_MPC" /> + <repository location="file://${BASE_REPOSITORIES_DIR}/REPO_EQUINOX" /> + <repository location="file://${APPVALIDATOR_OUTPUT}" /> + </source> + <iu id="com.motorola.studio.android.feature.feature.group" /> + <iu id="com.motorolamobility.preflighting.ui.feature.feature.group" /> + <iu id="com.motorolamobility.preflighting.feature.feature.group" /> + <iu id="com.motorolamobility.preflighting.sdk.feature.feature.group" /> + <iu id="biz.junginger.rss.eclipse.RssPlugin.feature.feature.group" /> + <iu id="com.android.ide.eclipse.adt.feature.group" /> + <iu id="com.android.ide.eclipse.ddms.feature.group" /> + <iu id="com.android.ide.eclipse.hierarchyviewer.feature.group" /> + <iu id="com.android.ide.eclipse.traceview.feature.group" /> + <iu id="org.apache.commons.logging" /> + <iu id="org.eclipse.datatools.enablement.sqlite.feature.feature.group" /> + <iu id="org.eclipse.datatools.sqldevtools.data.feature.feature.group" /> + <iu id="org.eclipse.datatools.connectivity.feature.feature.group" /> + <iu id="org.eclipse.datatools.connectivity.oda.feature.feature.group" /> + <iu id="org.eclipse.datatools.modelbase.feature.feature.group" /> + <iu id="org.eclipse.datatools.sqldevtools.feature.feature.group" /> + <iu id="org.eclipse.datatools.enablement.jdbc.feature.feature.group" /> + <iu id="org.eclipse.datatools.common.doc.user.feature.group" /> + <iu id="org.eclipse.datatools.sqltools.doc.user.feature.group" /> + <iu id="org.eclipse.datatools.connectivity.doc.user.feature.group" /> + <iu id="org.eclipse.datatools.doc.user.feature.group" /> + <iu id="org.eclipse.gef.feature.group" /> + <iu id="org.eclipse.jdt.feature.group" /> + <iu id="org.eclipse.emf.feature.group" /> + <iu id="org.eclipse.emf.ecore.feature.group" /> + <iu id="org.eclipse.emf.ecore.edit.feature.group" /> + <iu id="org.eclipse.emf.edit.ui.feature.group" /> + <iu id="org.eclipse.emf.ecore.editor.feature.group" /> + <iu id="org.eclipse.emf.converter.feature.group" /> + <iu id="org.eclipse.emf.common.feature.group" /> + <iu id="org.eclipse.emf.common.ui.feature.group" /> + <iu id="org.eclipse.emf.mapping.feature.group" /> + <iu id="org.eclipse.emf.mapping.ecore.feature.group" /> + <iu id="org.eclipse.emf.mapping.ecore.editor.feature.group" /> + <iu id="org.eclipse.emf.mapping.ui.feature.group" /> + <iu id="org.eclipse.emf.codegen.feature.group" /> + <iu id="org.eclipse.emf.codegen.ui.feature.group" /> + <iu id="org.eclipse.emf.codegen.ecore.feature.group" /> + <iu id="org.eclipse.emf.codegen.ecore.ui.feature.group" /> + <iu id="org.eclipse.emf.databinding.feature.group" /> + <iu id="org.eclipse.emf.databinding.edit.feature.group" /> + <iu id="org.eclipse.emf.edit.feature.group" /> + <iu id="org.eclipse.emf" /> + <iu id="org.eclipse.emf.ant" /> + <iu id="org.eclipse.emf.ecore" /> + <iu id="org.eclipse.emf.common.ui" /> + <iu id="org.eclipse.emf.edit.ui" /> + <iu id="org.eclipse.emf.common" /> + <iu id="org.eclipse.emf.mapping.ui" /> + <iu id="org.eclipse.emf.mapping" /> + <iu id="org.eclipse.emf.ecore.xmi" /> + <iu id="org.eclipse.emf.ecore.change" /> + <iu id="org.eclipse.emf.ecore.change.edit" /> + <iu id="org.eclipse.emf.ecore.edit" /> + <iu id="org.eclipse.emf.ecore.editor" /> + <iu id="org.eclipse.emf.importer" /> + <iu id="org.eclipse.emf.importer.ecore" /> + <iu id="org.eclipse.emf.importer.rose" /> + <iu id="org.eclipse.emf.importer.java" /> + <iu id="org.eclipse.emf.exporter" /> + <iu id="org.eclipse.emf.converter" /> + <iu id="org.eclipse.emf.mapping.ecore" /> + <iu id="org.eclipse.emf.mapping.ecore.editor" /> + <iu id="org.eclipse.emf.mapping.ecore2ecore" /> + <iu id="org.eclipse.emf.mapping.ecore2ecore.editor" /> + <iu id="org.eclipse.emf.mapping.ecore2xml" /> + <iu id="org.eclipse.emf.mapping.ecore2xml.ui" /> + <iu id="org.eclipse.emf.edit" /> + <iu id="org.eclipse.emf.codegen" /> + <iu id="org.eclipse.emf.codegen.ui" /> + <iu id="org.eclipse.emf.codegen.ecore" /> + <iu id="org.eclipse.emf.codegen.ecore.ui" /> + <iu id="org.eclipse.emf.databinding.edit" /> + <iu id="org.eclipse.emf.databinding" /> + <iu id="org.eclipse.mat.feature.feature.group" /> + <iu id="org.eclipse.mat.chart.feature.feature.group" /> + <iu id="org.eclipse.birt.core" /> + <iu id="org.eclipse.birt.chart.engine" /> + <iu id="org.eclipse.birt.chart.device.extension" /> + <iu id="org.eclipse.birt.chart.device.swt" /> + <iu id="org.eclipse.birt.chart.engine.extension" /> + <iu id="org.eclipse.xsd.edit" /> + <iu id="org.eclipse.xsd" /> + <iu id="org.eclipse.sequoyah.device.common.feature.feature.group" /> + <iu id="org.eclipse.sequoyah.device.feature.feature.group" /> + <iu id="org.eclipse.sequoyah.localization.tools.feature.feature.group" /> + <iu id="org.eclipse.sequoyah.localization.android.feature.feature.group" /> + <iu id="org.eclipse.sequoyah.vnc.vncviewer.feature.feature.group" /> + <iu id="org.eclipse.sequoyah.vnc.protocol.feature.feature.group" /> + <iu id="org.eclipse.sequoyah.vnc.feature.feature.group" /> + <iu id="org.eclipse.wst.common.fproj.feature.group" /> + <iu id="org.eclipse.wst.jsdt.feature.feature.group" /> + <iu id="org.eclipse.wst.server_adapters.feature.feature.group" /> + <iu id="org.eclipse.wst.web_ui.feature.feature.group" /> + <iu id="org.eclipse.wst.xml_core.feature.feature.group" /> + <iu id="org.eclipse.wst.xml_ui.feature.feature.group" /> + <iu id="org.eclipse.wst.xsl.feature.feature.group" /> + <iu id="org.eclipse.xsd.feature.group" /> + <iu id="org.eclipse.xsd.edit.feature.group" /> + <iu id="org.eclipse.pde.feature.group" /> + <iu id="net.certiv.proguarddt.feature.feature.group" /> + <iu id="org.eclipse.epp.mpc.feature.group" /> + <iu id="org.eclipse.equinox.p2.discovery.feature.feature.group" /> + </p2.mirror> + + <!-- Also mirror de product --> + <p2.mirror source="${OUTPUT_METADATA_PRODUCT}" destination="file:/${OUTPUT_METADATA_STUDIO_FULL}" /> + + <!-- run the category publisher.. there is no ant task to execute it --> + <java failonerror="true" jar="${eclipse.builder.path}/plugins/${eclipse.builder.launcher}" fork="true"> + <arg value="-application" /> + <arg value="org.eclipse.equinox.p2.publisher.CategoryPublisher" /> + <arg value="-metadataRepository" /> + <arg value="file:/${OUTPUT_METADATA_STUDIO_FULL}" /> + <arg value="-categoryDefinition" /> + <arg value="file:/tmp/site.xml" /> + </java> + + </target> + + <target name="genAdditionsArchive"> + + </target> + + <target name="genNativeArchive"> + + </target> + + <target name="noDefault"> + <echo message="You must specify a target when invoking this file" /> + </target> +</project>
\ No newline at end of file |