aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rwxr-xr-xdist/travis-ci.sh21
1 files changed, 16 insertions, 5 deletions
diff --git a/dist/travis-ci.sh b/dist/travis-ci.sh
index d0f356b8e..cf7e81916 100755
--- a/dist/travis-ci.sh
+++ b/dist/travis-ci.sh
@@ -5,15 +5,16 @@
set -e
CDIR=$PWD
+BLD=$1
# Prepare
-prefix="$CDIR/install-$1"
+prefix="$CDIR/install-$BLD"
mkdir "$prefix"
-mkdir build-$1
-cd build-$1
+mkdir build-$BLD
+cd build-$BLD
# Configure
-case "$1" in
+case "$BLD" in
mcode)
../configure --prefix="$prefix" ;;
@@ -21,7 +22,7 @@ case "$1" in
../configure --prefix="$prefix" --with-llvm-config=llvm-config-3.5 ;;
*)
- echo "unknown build $1"
+ echo "unknown build $BLD"
exit 1
;;
esac
@@ -31,6 +32,16 @@ make
make install
cd ..
+# Package
+PKG_VER=`grep Ghdl_Ver src/version.ads | sed -e 's/.*"\(.*\)";/\1/'`
+
+if [ "$TRAVIS_TAG" = "x" ]; then
+ PKG_TAG=`date -u +%Y%m%d`
+else
+ PKG_TAG=$TRAVIS_TAG
+fi
+tar -zcvf ghdl-$PKG_VER-$BLD-$PKG_TAG.tgz -C $prefix .
+
# Test
export GHDL="$CDIR/install-$1/bin/ghdl"
cd testsuite