diff options
Diffstat (limited to 'dist/linux/buildtest.sh')
-rwxr-xr-x | dist/linux/buildtest.sh | 55 |
1 files changed, 30 insertions, 25 deletions
diff --git a/dist/linux/buildtest.sh b/dist/linux/buildtest.sh index f8347070d..86722b785 100755 --- a/dist/linux/buildtest.sh +++ b/dist/linux/buildtest.sh @@ -10,10 +10,10 @@ set -e for arg in "$@"; do shift case "$arg" in - "--color"|"-color") set -- "$@" "-c";; - "--build"|"-build") set -- "$@" "-b";; - "--file"|"-file") set -- "$@" "-f";; - "--taskid"|"-taskid") set -- "$@" "-t";; + "--color"|"-color") set -- "$@" "-c";; + "--build"|"-build") set -- "$@" "-b";; + "--file"|"-file") set -- "$@" "-f";; + "--taskid"|"-taskid") set -- "$@" "-t";; *) set -- "$@" "$arg" esac done @@ -22,10 +22,12 @@ while getopts ":b:f:t:c" opt; do case $opt in c) enable_color;; b) BLD=$OPTARG ;; - f) PKG_FILE=$OPTARG;; + f) PKG_FILE=$OPTARG;; t) TASK=$OPTARG;; - \?) printf "$ANSI_RED[GHDL] Invalid option: -$OPTARG $ANSI_NOCOLOR\n" >&2; exit 1 ;; - :) printf "$ANSI_RED[GHDL] Option -$OPTARG requires an argument. $ANSI_NOCOLOR\n" >&2; exit 1 ;; + \?) printf "$ANSI_RED[GHDL] Invalid option: -$OPTARG $ANSI_NOCOLOR\n" >&2 + exit 1 ;; + :) printf "$ANSI_RED[GHDL] Option -$OPTARG requires an argument. $ANSI_NOCOLOR\n" >&2 + exit 1 ;; esac done @@ -33,7 +35,6 @@ done printf "$ANSI_BLUE[$TASK| GHDL] Prepare $(pwd) $ANSI_NOCOLOR\n" CDIR=$(pwd) -mkdir logs prefix="$CDIR/install-$BLD" mkdir "$prefix" mkdir "build-$BLD" @@ -49,27 +50,30 @@ env 1>> ../log.log 2>&1 printf "$ANSI_BLUE[$TASK| GHDL - build] Configure $ANSI_NOCOLOR\n" case "$BLD" in mcode) - ../configure "--prefix=$prefix" 1>> ../log.log 2>&1 - ;; - + ../configure "--prefix=$prefix" 1>> ../log.log 2>&1 + ;; + llvm) - ../configure "--prefix=$prefix" "--with-llvm-config" 1>> ../log.log 2>&1 - ;; - + ../configure "--prefix=$prefix" "--with-llvm-config" 1>> ../log.log 2>&1 + ;; + llvm-3.5) - ../configure "--prefix=$prefix" "--with-llvm-config=llvm-config-3.5" 1>> ../log.log 2>&1 - MAKEOPTS="CXX=clang++" - ;; + ../configure "--prefix=$prefix" "--with-llvm-config=llvm-config-3.5" 1>> ../log.log 2>&1 + MAKEOPTS="CXX=clang++" + ;; llvm-3.8) - ../configure "--prefix=$prefix" "--with-llvm-config=llvm-config-3.8" 1>> ../log.log 2>&1 - MAKEOPTS="CXX=clang++-3.8" - ;; + ../configure "--prefix=$prefix" "--with-llvm-config=llvm-config-3.8" 1>> ../log.log 2>&1 + MAKEOPTS="CXX=clang++-3.8" + ;; - docker) printf "$ANSI_MAGENTA[$TASK| GHDL - build] Check docker container! $ANSI_NOCOLOR\n"; exit 0;; + docker) + printf "$ANSI_MAGENTA[$TASK| GHDL - build] Check docker container! $ANSI_NOCOLOR\n" + exit 0;; - *) printf "$ANSI_RED[$TASK| GHDL - build] Unknown build $BLD $ANSI_NOCOLOR\n" - exit 1;; + *) + printf "$ANSI_RED[$TASK| GHDL - build] Unknown build $BLD $ANSI_NOCOLOR\n" + exit 1;; esac #--- @@ -90,10 +94,11 @@ tar -zcvf "$PKG_FILE" -C "$prefix" . 1>> log.log 2>&1 export ENABLECOLOR="$ENABLECOLOR" export TASK="$TASK" export GHDL="$CDIR/install-$BLD/bin/ghdl" -cd testsuite && ./testsuite.sh +cd testsuite +./testsuite.sh cd .. #--- # Do not remove this line, and don't write anything below, since it is used to identify successful builds -echo "[$TASK|SUCCESSFUL]" 1>> log.log 2>&1
\ No newline at end of file +echo "[$TASK|SUCCESSFUL]" 1>> log.log 2>&1 |