qbe

Internal scc patchset buffer for QBE
Log | Files | Refs | README | LICENSE

commit e54f7a0fda867f4cc7ae42bfaa6e38ad26034f7f
parent fedb1fa32cf71536bbc986182e78cd4437b1a63c
Author: Quentin Carbonneaux <quentin.carbonneaux@yale.edu>
Date:   Mon, 25 Sep 2017 14:41:25 +0200

adjust test.sh for ubuntu

Diffstat:
Mtools/test.sh | 8+++++++-
1 file changed, 7 insertions(+), 1 deletion(-)

diff --git a/tools/test.sh b/tools/test.sh @@ -10,6 +10,11 @@ asm=$tmp.s exe=$tmp.exe out=$tmp.out +testcc() { + echo "int main() { }" | $1 -x C -o /dev/null - >/dev/null 2>&1 + return $? +} + init() { case "$TARGET" in arm64) @@ -31,7 +36,7 @@ init() { echo "Cannot find arm64 compiler or qemu." exit 1 fi - bin="$bin -t arm64" + bin="$bin -t arm64" ;; "") case `uname` in @@ -46,6 +51,7 @@ init() { ;; *) cc="cc -no-pie" + testcc $cc || cc="cc" ;; esac ;;