Skip to content
Permalink
Browse files
improve jenkins job handling
  • Loading branch information
Dave Cottlehuber committed Mar 26, 2013
1 parent fb225be commit 1c51bf12333c19942589ec32bbc59985d023412e
Showing 3 changed files with 22 additions and 7 deletions.
@@ -1,4 +1,7 @@
@echo off
:: This script must run with elevated (admin/uac) permissions for the
:: cp -p stage in couchdb autotools script to complete successfully.

:: tell other glazier scripts to run automated
:: builds instead of usual interactive mode
set BUILD_WITH_JENKINS=1
@@ -21,12 +24,25 @@ robocopy %WERL_SRC% %WERL_DIR% -mir -log:NUL: -r:0 -w:0
:: expect crash and burn for the moment

:: this allows you to run the jenkins build interactively TODO HACKHACKHACK
if not defined WORKSPACE set WORKSPACE=c:\jenkins\workspace\Apache-CouchDB-Windows-master\label\Windows-8-x64\

:: This script must run with elevated (admin/uac) permissions for the
:: cp -p stage in couchdb autotools script to complete successfully.
if not defined WORKSPACE set WORKSPACE=c:\jenkins\workspace\Apache-CouchDB-Windows\

echo ============= JENKINS CONFIG ===============
echo Working Directory:
cd
set BUILD
set GIT
set JENKINS_HOME
set JENKINS_URL
set JOB
set NODE
set OTP
set PATH
set WERL
set WORKSPACE
echo ============= JENKINS CONFIG ===============

call c:\relax\bin\shell.cmd
:: and relax

:: output when all is well, ends up in /etc/windows/ for better or for worse!
xz
@@ -98,7 +98,6 @@ goto unix_shell
:unix_shell
color
title Building in %ERL_TOP% with OTP %OTP_REL% and Erlang v%ERTS_VSN%
pushd %WERL%\
for /f "usebackq" %%i in (`c:\cygwin\bin\cygpath.exe %WERL_DIR%`) do @set WERL_PATH=%%i
set ERL_TOP=%WERL_PATH%/otp_src_%OTP_REL%
c:\cygwin\bin\bash %relax%\bin\shell.sh
@@ -72,7 +72,6 @@ export OVERRIDE_TARGET CC CXX AR RANLIB OVERRIDE_CONFIG_CACHE_STATIC OVERRIDE_CO

# ensure we have an ERL_TOP to go to
mkdir -p $ERL_TOP > /dev/null 2>&1
pushd $ERL_TOP

# this shouldn't change anything really
### eval `./otp_build env_win32`
@@ -88,9 +87,10 @@ echo Ready to build Erlang and CouchDB using Erlang $ERTS_VSN OTP $OTP_VER in $E
echo Time to Relax.

if [ -z "$BUILD_WITH_JENKINS" ] ; then
pushd $ERL_TOP
bash -i
else
cd $WORKSPACE
echo Working directory is: `pwd`
git clean -fdx
git reset --hard
./bootstrap

0 comments on commit 1c51bf1

Please sign in to comment.