From 2b1f49035b8a849c718399ff6780d7600dc517a3 Mon Sep 17 00:00:00 2001 From: "Arnold D. Robbins" Date: Mon, 24 Apr 2017 07:31:51 +0300 Subject: New helper script: test-build.sh. --- helpers/ChangeLog | 4 ++++ helpers/test-build.sh | 49 +++++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 53 insertions(+) create mode 100755 helpers/test-build.sh (limited to 'helpers') diff --git a/helpers/ChangeLog b/helpers/ChangeLog index b08dec6c..df0741c9 100644 --- a/helpers/ChangeLog +++ b/helpers/ChangeLog @@ -1,3 +1,7 @@ +2017-04-24 Arnold D. Robbins + + * test-build.sh: New file. + 2017-03-20 Andrew J. Schorr * update-branches.sh: Robustness improvements. diff --git a/helpers/test-build.sh b/helpers/test-build.sh new file mode 100755 index 00000000..ce4aab50 --- /dev/null +++ b/helpers/test-build.sh @@ -0,0 +1,49 @@ +#! /bin/sh + +MIXED_COMPILERS="gcc /usr/gcc/bin/gcc clang" +OTHER_COMPILERS="tcc pcc" + +rm -f compile-results.txt + +compile () { + make -k + if make check + then + echo success: $1 $2 >> compile-results.txt + else + echo failure: $1 $2 >> compile-results.txt + fi +} + +configure_and_compile () { + for j in "" --disable-mpfr + do + ./configure $j CC="$1" + compile "$1" "$j" + done + make distclean +} + +(make distclean) + +for i in $OTHER_COMPILERS $MIXED_COMPILERS +do + configure_and_compile $i +done + +for i in $MIXED_COMPILERS +do + configure_and_compile "$i -m32" +done + +echo +echo ========================================== +echo +case $(grep failure compile-results.txt | wc -l) in +0) echo No failures! + # rm compile-results.txt + ;; +*) echo The following combinations failed: + grep failure compile-results.txt + ;; +esac -- cgit v1.2.3