# HG changeset patch # User Olaf Wintermann # Date 1764415090 -3600 # Node ID 12a5e64cab3410052282bbd7c091e9c170c08169 # Parent 79eeb33c738fad0cc886c15502ceea9a59f88141 fix toolchain.sh compatibility with older shells diff -r 79eeb33c738f -r 12a5e64cab34 src/main/resources/make/toolchain.sh --- a/src/main/resources/make/toolchain.sh Fri Nov 14 15:09:37 2025 +0100 +++ b/src/main/resources/make/toolchain.sh Sat Nov 29 12:18:10 2025 +0100 @@ -24,7 +24,8 @@ check_c_compiler() { - if ! command -v "$1" >/dev/null 2>&1 ; then + command -v "$1" >/dev/null 2>&1 + if [ $? -ne 0 ] ; then return 1 fi cat > "$TEMP_DIR/test.c" << __EOF__ @@ -55,7 +56,8 @@ check_cpp_compiler() { - if ! command -v "$1" >/dev/null 2>&1 ; then + command -v "$1" >/dev/null 2>&1 + if [ $? -ne 0 ] ; then return 1 fi cat > "$TEMP_DIR/test.cpp" << __EOF__ diff -r 79eeb33c738f -r 12a5e64cab34 test/make/toolchain.sh --- a/test/make/toolchain.sh Fri Nov 14 15:09:37 2025 +0100 +++ b/test/make/toolchain.sh Sat Nov 29 12:18:10 2025 +0100 @@ -24,7 +24,8 @@ check_c_compiler() { - if ! command -v "$1" >/dev/null 2>&1 ; then + command -v "$1" >/dev/null 2>&1 + if [ $? -ne 0 ] ; then return 1 fi cat > "$TEMP_DIR/test.c" << __EOF__ @@ -55,7 +56,8 @@ check_cpp_compiler() { - if ! command -v "$1" >/dev/null 2>&1 ; then + command -v "$1" >/dev/null 2>&1 + if [ $? -ne 0 ] ; then return 1 fi cat > "$TEMP_DIR/test.cpp" << __EOF__