From b894a457d7a2955dd123e47f4cffdd3c7fa33ebb Mon Sep 17 00:00:00 2001 From: ThorstenB Date: Wed, 18 Jan 2012 00:32:16 +0100 Subject: [PATCH] Build release using separate directories. Don't build in the git repositories' directories - so they're always fresh and clean... --- hudson_build_release.sh | 31 +++++++++++++++++++++++-------- 1 file changed, 23 insertions(+), 8 deletions(-) diff --git a/hudson_build_release.sh b/hudson_build_release.sh index d94046d..7a7ec29 100755 --- a/hudson_build_release.sh +++ b/hudson_build_release.sh @@ -1,10 +1,19 @@ #!/bin/sh -cd simgear -cmake -DCMAKE_INSTALL_PREFIX:PATH=$WORKSPACE/dist +# remove old and create fresh build directories +rm -rf sgBuild +rm -rf fgBuild +mkdir -p sgBuild +mkdir -p fgBuild +mkdir -p output +# clear output directory +rm -rf output/* -# first make source package (clean directory), finally compile -make package_source +echo "Starting on SimGear" +cd sgBuild +cmake -DCMAKE_INSTALL_PREFIX:PATH=$WORKSPACE/dist ../simgear + +# compile make if [ $? -ne '0' ]; then @@ -14,13 +23,16 @@ fi make install +# build source package and copy to output +make package_source +cp simgear-*.tar.bz2 ../output/. + echo "Starting on FlightGear" -cd ../flightgear -cmake -DCMAKE_INSTALL_PREFIX:PATH=$WORKSPACE/dist +cd ../fgBuild +cmake -DCMAKE_INSTALL_PREFIX:PATH=$WORKSPACE/dist ../flightgear -# first source package (clean directory), finally compile -make package_source +# compile make if [ $? -ne '0' ]; then @@ -30,3 +42,6 @@ fi make install +# build source package and copy to output +make package_source +