From f170876956e3743f2e6ac2b67a8deb80ae16dfcb Mon Sep 17 00:00:00 2001 From: Christian Stimming Date: Wed, 27 May 2009 14:09:48 +0000 Subject: [PATCH] Win32: Add shell script for the automated nightly build. git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@18091 57a11ea4-9604-0410-9ed3-97b8803252fd --- packaging/win32/daily_build.sh | 33 +++++++++++++++++++++++++++++++++ 1 file changed, 33 insertions(+) create mode 100755 packaging/win32/daily_build.sh diff --git a/packaging/win32/daily_build.sh b/packaging/win32/daily_build.sh new file mode 100755 index 0000000000..79852020ab --- /dev/null +++ b/packaging/win32/daily_build.sh @@ -0,0 +1,33 @@ +#!/bin/sh + +set -e + +function qpushd() { pushd "$@" >/dev/null; } +function qpopd() { popd >/dev/null; } +function unix_path() { echo "$*" | sed 's,^\([A-Za-z]\):,/\1,;s,\\,/,g'; } + +qpushd "$(dirname $(unix_path "$0"))" +. functions.sh +. defaults.sh + +set_default OUTPUT_DIR $GLOBAL_DIR\\output + +LOGFILENAME=build-`date +'%Y-%m-%d'`.log + +_OUTPUT_DIR=`unix_path $OUTPUT_DIR` +LOGFILE=${_OUTPUT_DIR}/${LOGFILENAME} + +# Run the compile +./install.sh 2>&1 | tee ${LOGFILE} + +# Create the installer +./dist.sh 2>&1 | tee -a ${LOGFILE} + +# Copy the resulting installer into the output directory +_BUILD_UDIR=`unix_path $BUILD_DIR` +_GNUCASH_UDIR=`unix_path $GNUCASH_DIR` +PKG_VERSION=`grep PACKAGE_VERSION ${_BUILD_UDIR}/config.h | cut -d" " -f3 | cut -d\" -f2 ` +SVN_REV=`grep GNUCASH_SVN_REV ${_BUILD_UDIR}/src/gnome-utils/gnc-svninfo.h | cut -d" " -f3 | cut -d\" -f2 ` +SETUP_FILENAME="gnucash-${PKG_VERSION}-svn-r${SVN_REV}-setup.exe" +mv ${_GNUCASH_UDIR}/${SETUP_FILENAME} ${_OUTPUT_DIR} +