diff options
author | Markus Knauer | 2009-03-17 11:20:37 +0000 |
---|---|---|
committer | Markus Knauer | 2009-03-17 11:20:37 +0000 |
commit | d58f68232eddf7adf42055f96157a750320230b3 (patch) | |
tree | 92a65f99bae19042d3fe1c1ea789e1d657e2a960 /releng | |
parent | e197b33f1e432855e8d4b3b26b8b3f335cd33703 (diff) | |
download | org.eclipse.epp.packages-d58f68232eddf7adf42055f96157a750320230b3.tar.gz org.eclipse.epp.packages-d58f68232eddf7adf42055f96157a750320230b3.tar.xz org.eclipse.epp.packages-d58f68232eddf7adf42055f96157a750320230b3.zip |
update
Diffstat (limited to 'releng')
-rw-r--r-- | releng/org.eclipse.epp.config/startEPP35.sh | 96 |
1 files changed, 72 insertions, 24 deletions
diff --git a/releng/org.eclipse.epp.config/startEPP35.sh b/releng/org.eclipse.epp.config/startEPP35.sh index 30d2f088..e2fd36c0 100644 --- a/releng/org.eclipse.epp.config/startEPP35.sh +++ b/releng/org.eclipse.epp.config/startEPP35.sh @@ -1,39 +1,48 @@ #!/bin/sh -#set -x +set -x umask 0022 ulimit -n 2048 +# change this if building on build.eclipse.org to "server"; "local" otherwise +BUILDLOCATION="server" +# Location of the build input HTTP_BASE="http://download.eclipse.org" FILESYSTEM_BASE="file:///home/data/httpd/download.eclipse.org" - -# change this if building on build.eclipse.org to FILESYSTEM_BASE -BASE_URL=${FILESYSTEM_BASE} - -# Ganymede Repositories -REPO_ECLIPSE34="${BASE_URL}/eclipse/updates/3.4/" -REPO_GANYMEDE="${BASE_URL}/releases/ganymede/" -REPO_EPP_GANYMEDE="${BASE_URL}/technology/epp/packages/ganymede/" -REPO_EPP_UDC="${BASE_URL}/technology/epp/updates/1.0/" +if [ ${BUILDLOCATION} = "server" ] +then + BASE_URL=${FILESYSTEM_BASE} +else + BASE_URL=${HTTP_BASE} +fi # Galileo Repositories REPO_ECLIPSE35="${BASE_URL}/eclipse/updates/3.5milestones" #REPO_GALILEO="${BASE_URL}/releases/galileo/" -#REPO_GALILEO="http://build.eclipse.org/galileo/staging/" -REPO_GALILEO="file:///opt/users/hudsonbuild/downloads/galileo/" +if [ ${BUILDLOCATION} = "server" ] +then + REPO_GALILEO="file:///opt/users/hudsonbuild/downloads/galileo/" +else + REPO_GALILEO="http://build.eclipse.org/galileo/staging/" +fi REPO_EPP_GALILEO="${BASE_URL}/technology/epp/packages/galileo/milestones" -# Repositories (Galileo vs. Ganymede) -METADATAREPOSITORIES="${REPO_ECLIPSE35},${REPO_GALILEO},${REPO_EPP_UDC},${REPO_EPP_GALILEO}" -ARTIFACTREPOSITORIES="${REPO_ECLIPSE35},${REPO_GALILEO},${REPO_EPP_UDC}" -# METADATAREPOSITORIES="${REPO_ECLIPSE34},${REPO_GANYMEDE},${REPO_EPP_GANYMEDE}" -# ARTIFACTREPOSITORIES="${REPO_ECLIPSE34},${REPO_GANYMEDE}" +# Repositories (Galileo) +METADATAREPOSITORIES="${REPO_ECLIPSE35},${REPO_GALILEO},${REPO_EPP_GALILEO}" +ARTIFACTREPOSITORIES="${REPO_ECLIPSE35},${REPO_GALILEO}" # Eclipse installation, Java, etc. -ECLIPSE="/shared/technology/epp/epp_build/35/eclipse/eclipse" -JRE="/opt/ibm/java2-ppc-50/bin/java" +if [ ${BUILDLOCATION} = "server" ] +then + ECLIPSE="/shared/technology/epp/epp_build/35/eclipse/eclipse" + JRE="/opt/ibm/java2-ppc-50/bin/java" +else + ECLIPSE="eclipse" + JRE="java" +fi PACKAGES="epp.package.javame epp.package.cpp epp.package.java epp.package.jee epp.package.modeling epp.package.rcp epp.package.reporting" +PACKAGES_NAMES=( "JavaME" "CPP" "Java" "JEE" "Modeling" "RCP" "Reporting" ) OSes=( win32 linux linux macosx ) WSes=( win32 gtk gtk carbon ) ARCHes=( x86 x86 x86_64 ppc ) @@ -41,6 +50,7 @@ FORMAT=( zip tar.gz tar.gz tar.gz ) BASE_DIR=/shared/technology/epp/epp_build/35 DOWNLOAD_BASE_DIR=${BASE_DIR}/download +DOWNLOAD_BASE_URL="http://build.eclipse.org/technology/epp/epp_build/35/download" BUILD_DIR=${BASE_DIR}/build ############################################################################### @@ -48,6 +58,8 @@ BUILD_DIR=${BASE_DIR}/build # variables START_TIME=`date -u +%Y%m%d-%H%M` LOCKFILE="/tmp/epp.build35.lock" +MARKERFILENAME=".epp.nightlybuild" +STATUSFILENAME="status.stub" ############################################################################### @@ -59,19 +71,28 @@ fi trap "rm -f ${LOCKFILE}; exit" INT TERM EXIT touch ${LOCKFILE} -# create download directory +# create download directory and files DOWNLOAD_DIR=${DOWNLOAD_BASE_DIR}/${START_TIME} mkdir ${DOWNLOAD_DIR} +MARKERFILE="${DOWNLOAD_DIR}/${MARKERFILENAME}" +touch ${MARKERFILE} +STATUSFILE="${DOWNLOAD_DIR}/${STATUSFILENAME}" +touch ${STATUSFILE} # log to file LOGFILE="${DOWNLOAD_DIR}/build.log" exec 1>${LOGFILE} 2>&1 +# start statusfile +echo "<tr>" >>${STATUSFILE} +echo "<td>${START_TIME}</td>" >>${STATUSFILE} + # build the packages for PACKAGE in ${PACKAGES}; do echo "Building package for IU ${PACKAGE}" mkdir -p ${BUILD_DIR}/${PACKAGE} + echo "<td>" >>${STATUSFILE} for index in 0 1 2 3; do echo -n "...EPP building ${PACKAGE} ${OSes[$index]} ${WSes[$index]} ${ARCHes[$index]} " @@ -94,22 +115,49 @@ do -vmargs -Declipse.p2.mirrors=false -Declipse.p2.data.area=${PACKAGE_BUILD_DIR}/eclipse/p2 \ 2>&1 >${DOWNLOAD_DIR}/${PACKAGE}_${EXTENSION}.log if [ $? = "0" ]; then - echo "...successfully finished ${OSes[$index]} ${WSes[$index]} ${ARCHes[$index]} package build" cd ${PACKAGE_BUILD_DIR} if [ ${OSes[$index]} = "win32" ]; then - zip -r -o -q ${DOWNLOAD_DIR}/${START_TIME}_eclipse-${PACKAGE}-${EXTENSION}.zip eclipse + PACKAGEFILE="${START_TIME}_eclipse-${PACKAGE}-${EXTENSION}.zip" + zip -r -o -q ${DOWNLOAD_DIR}/${PACKAGEFILE} eclipse else - tar zc --owner=100 --group=100 -f ${DOWNLOAD_DIR}/${START_TIME}_eclipse-${PACKAGE}-${EXTENSION}.tar.gz eclipse + PACKAGEFILE="${START_TIME}_eclipse-${PACKAGE}-${EXTENSION}.tar.gz" + tar zc --owner=100 --group=100 -f ${DOWNLOAD_DIR}/${PACKAGEFILE} eclipse fi cd .. rm -r ${PACKAGE_BUILD_DIR} + echo "...successfully finished ${OSes[$index]} ${WSes[$index]} ${ARCHes[$index]} package build: ${PACKAGEFILE}" + echo ${PACKAGEFILE} >>${DOWNLOAD_DIR}/${PACKAGE}_${EXTENSION}.log + echo "<small style=\"background-color: rgb(204, 255, 204);\"><a href=\"${DOWNLOAD_BASE_URL}/${START_TIME}/${PACKAGEFILE}\">${EXTENSION}</a><small><br>" >>${STATUSFILE} else echo "...failed while building package ${OSes[$index]} ${WSes[$index]} ${ARCHes[$index]}" + echo "FAILED" >>${DOWNLOAD_DIR}/${PACKAGE}_${EXTENSION}.log + echo "<small style=\"background-color: rgb(255, 204, 204);\"><a href=\"${DOWNLOAD_BASE_URL}/${START_TIME}/${PACKAGE}_${EXTENSION}.log\">${EXTENSION}</a><small><br>" >>${STATUSFILE} fi done + echo "</td>" >>${STATUSFILE} done - +# start statusfile +echo "</tr>" >>${STATUSFILE} + +# remove 'some' (which?) files from the download server +echo "...remove oldest build from download directory ${DOWNLOAD_BASE_DIR}" +cd ${DOWNLOAD_BASE_DIR} +TOBEDELETED_TEMP=`find . -name ${MARKERFILENAME} | grep -v "\./${MARKERFILENAME}" | sort | head -n 1` +TOBEDELETED_DIR=`echo ${TOBEDELETED_TEMP} | cut -d "/" -f 2` +echo "......removing ${TOBEDELETED_DIR} from ${DOWNLOAD_BASE_DIR}" +rm -r ${TOBEDELETED_DIR} + +# link results somehow in a single file +echo "...recreate ${DOWNLOAD_BASE_DIR}/${STATUSFILENAME}" +rm ${DOWNLOAD_BASE_DIR}/${STATUSFILENAME} +cd ${DOWNLOAD_BASE_DIR} +for FILE in `ls -r */${STATUSFILENAME}` +do + echo "......adding $FILE" + cat ${FILE} >>${DOWNLOAD_BASE_DIR}/${STATUSFILENAME} +done +cp -a ${DOWNLOAD_BASE_DIR}/${STATUSFILENAME} /home/data/httpd/download.eclipse.org/technology/epp/downloads/testing/status35.stub ############################################################################### |