aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLars Vogel2013-10-24 05:20:22 (EDT)
committerGerrit Code Review @ Eclipse.org2013-10-25 09:42:20 (EDT)
commit3484cb7b17c9212247098f738357c254b02b2231 (patch)
tree74d6cf9b184961002f645d836da368c8bccc7d01
parent8401b49307ce53cbbe58ea9529e263b9d1eb757b (diff)
downloadeclipse.platform.releng.aggregator-3484cb7b17c9212247098f738357c254b02b2231.zip
eclipse.platform.releng.aggregator-3484cb7b17c9212247098f738357c254b02b2231.tar.gz
eclipse.platform.releng.aggregator-3484cb7b17c9212247098f738357c254b02b2231.tar.bz2
Bug 42021 - Provide README and build script to make CBI build morerefs/changes/23/17723/3
accessible Change-Id: Icff4aaf2040f2cc721c8bc59c2054727482893f0 Signed-off-by: Lars Vogel <Lars.Vogel@gmail.com>
-rw-r--r--README11
-rwxr-xr-xscripts/build.sh118
-rwxr-xr-xscripts/cbi_build.sh52
3 files changed, 28 insertions, 153 deletions
diff --git a/README b/README
new file mode 100644
index 0000000..40beab1
--- /dev/null
+++ b/README
@@ -0,0 +1,11 @@
+Aggregator repo for an Eclipse SDK build
+
+
+
+To run a complete build, run the commands from ./scripts/build.sh in this folder
+
+These commands requires the installation and setup of Java 1.6 or higher and Maven
+in version 3.0.3 or higher
+
+For details please see http://wiki.eclipse.org/Platform-releng/Platform_Build
+
diff --git a/scripts/build.sh b/scripts/build.sh
index 5cd9ea4..8292083 100755
--- a/scripts/build.sh
+++ b/scripts/build.sh
@@ -1,103 +1,19 @@
#!/bin/bash
-BASEDIR=$(pwd)
-LOG=$BASEDIR/log_$( date +%Y%m%d%H%M%S ).txt
-exec >$LOG 2>&1
-
-BRANCH=master
-GIT_PREFIX=ssh://git.eclipse.org
-javaHome=/opt/local/jdk1.7.0_07
-mvnPath=/opt/pwebster/git/cbi/apache-maven-3.1.0/bin
-updateAggregator=false
-
-while [ $# -gt 0 ]
-do
- case "$1" in
- "-v")
- mavenVerbose=-X;;
- "-bree-libs")
- mavenBREE=-Pbree-libs;;
- "-sign")
- mavenSign=-Peclipse-sign;;
- "-update")
- updateAggregator=true;;
- "-anonymous")
- GIT_PREFIX=git://git.eclipse.org;;
- "-gitPrefix")
- GIT_PREFIX="$2" ; shift;;
- "-branch")
- BRANCH="$2" ; shift;;
- "-javaHome")
- javaHome="$2" ; shift;;
- "-mavenPath")
- mvnPath="$2" ; shift;;
- esac
- shift
-done
-
-
-export MAVEN_OPTS=-Xmx2560m
-LOCAL_REPO=$BASEDIR/localRepo
-
-
-if [ -z "$JAVA_HOME" ]; then
- export JAVA_HOME=$javaHome
-fi
-
-mvnRegex=$( echo $mvnPath | sed 's!/!.!g' )
-if ! (echo $PATH | grep "$mvnRegex" >/dev/null ); then
- export PATH=${mvnPath}:$PATH
-fi
-
-
-cloneAggregator() {
- if [ ! -d eclipse.platform.releng.aggregator ]; then
- git clone \
- -b $BRANCH \
- ${GIT_PREFIX}/gitroot/platform/eclipse.platform.releng.aggregator.git
- pushd eclipse.platform.releng.aggregator
- git submodule init
- # this will take a while ... a long while
- git submodule update
- popd
- else
- pushd eclipse.platform.releng.aggregator
- git fetch
- git checkout $BRANCH
- git pull
- git submodule update
- popd
- fi
-}
-
-installEclipseParent () {
- pushd eclipse.platform.releng.aggregator
- mvn -f eclipse-platform-parent/pom.xml \
- clean install \
- -Dmaven.repo.local=$LOCAL_REPO
- popd
-}
-
-buildAggregator () {
- pushd eclipse.platform.releng.aggregator
- mvn $mavenVerbose \
- clean install \
- $mavenSign \
- $mavenBREE \
- -Dmaven.test.skip=true \
- -Dmaven.repo.local=$LOCAL_REPO
- popd
-}
-
-# steps to get going
-
-if $updateAggregator; then
- cloneAggregator
-fi
-
-# pick up any changes
-installEclipseParent
-
-# build from the aggregator root
-buildAggregator
-
+clean up "dirt" from previous build
+# see Bug 420078
+git submodule foreach git clean -f -d -x
+git submodule foreach git reset --hard HEAD
+git clean -f -d -x
+git reset --hard HEAD
+
+# update master and submodules
+git checkout master
+git pull --recurse-submodules
+git submodule update
+
+# run the build
+mvn clean verify
+
+# find the results in
+# eclipse.platform.releng.tychoeclipsebuilder/sdk/target/products/*
diff --git a/scripts/cbi_build.sh b/scripts/cbi_build.sh
deleted file mode 100755
index 7020ec4..0000000
--- a/scripts/cbi_build.sh
+++ /dev/null
@@ -1,52 +0,0 @@
-#!/bin/bash
-
-###
-### THIS SCRIPT IS DEPRECATED, USE build.sh INSTEAD.
-###
-
-echo "WARNING: This script is deprecated and will be removed in the future, please use build.sh instead."
-
-
-
-BASE=$( cd $( dirname "$0" ) > /dev/null ; pwd )
-
-if [[ ! -e "$BASE/setup.sh" ]]; then
- echo "Copy cbi_setup.tpl to $BASE/setup.sh and modify it for your local environment"
- exit 1
-fi
-
-
-source "$BASE/setup.sh"
-
-if [[ ! -e "${m2settings}" ]]; then
- echo "Copy $HOME/.m2/settings.xml or cbi_settings.tpl to ${m2settings}"
- exit 1
-fi
-
-mvnWrapper() {
- mvn -Dmaven.repo.local="${m2repo}" --settings "${m2settings}" "$@" || exit 1
-}
-
-cmd="$1"
-
-case "$cmd" in
- build ) #CMD Build all the sources
- mvnWrapper -f eclipse-platform-parent/pom.xml clean install
- mvnWrapper clean install -Dmaven.test.skip=true
- echo "Build successful"
- echo "You can find the installation files in $BASE/../eclipse.platform.releng.tychoeclipsebuilder/sdk/target/products/"
- ls -l "$BASE/../eclipse.platform.releng.tychoeclipsebuilder/sdk/target/products"
- ;;
-
- test ) #CMD Run the tests. You must build at least once before you can run this
- # TODO
- ;;
-
- * )
- echo "Missing command. Available are:"
- grep CMD "$0" | grep -v grep | sed -e "s:^[ \t]+::g" -e 's:[)] #CMD:-:'
- ;;
-esac
-
-exit 0
-