From 1cbd29531c202bf654a8b1f9d7e1437e9aa5d616 Mon Sep 17 00:00:00 2001 From: Amar Takhar Date: Fri, 1 May 2009 03:58:23 +0000 Subject: [PATCH] Add an sh script to generate snap tarballs upon successful builds of UNIX platforms (excluding Darwin). Originally committed to SVN as r2889. --- aegisub/tinderbox/unix/dist.sh | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) create mode 100755 aegisub/tinderbox/unix/dist.sh diff --git a/aegisub/tinderbox/unix/dist.sh b/aegisub/tinderbox/unix/dist.sh new file mode 100755 index 000000000..c451e7cab --- /dev/null +++ b/aegisub/tinderbox/unix/dist.sh @@ -0,0 +1,27 @@ +#!/bin/sh +DIST_NAME="aegisub-snap-r${1}" + +if test -z "${1}"; then + echo "You must supply a revision number!" + exit 1 +fi + +# On FreeBSD "make" is PMake, so we need to use 'gmake' +if test `uname -s` = "FreeBSD"; then + BIN_MAKE="gmake" +else + BIN_MAKE="make" +fi + +./autogen.sh || exit $? + +${BIN_MAKE} distdir distdir="${DIST_NAME}" || exit $? + +# Put the name of the buildslave into ./slave_info as it may be useful for +# debugging localised buildslave issues if a user is using a snapshot. +echo "${2}" > "${DIST_NAME}/slave_info" + +tar cf "${DIST_NAME}.tar" "${DIST_NAME}" || exit $? +bzip2 -v ${DIST_NAME}.tar +mv "${DIST_NAME}.tar.bz2" dist.tar.bz2 +