From 20876694ab8f9ee1a821e464541d85e733fd44e0 Mon Sep 17 00:00:00 2001 From: Rob Landley Date: Mon, 2 Mar 2020 17:19:48 -0600 Subject: Check that cross compiler is there, not linker, before building native. It builds binutils first, so ld being there doesn't mean cc finished. --- scripts/mcm-buildall.sh | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'scripts') diff --git a/scripts/mcm-buildall.sh b/scripts/mcm-buildall.sh index e82ce2d5..20713bc8 100755 --- a/scripts/mcm-buildall.sh +++ b/scripts/mcm-buildall.sh @@ -47,14 +47,15 @@ make_toolchain() HOST="$TARGET" export NATIVE=y LP="$OUTPUT/${RENAME:-$TARGET}-cross/bin:$LP" + [ -z "$(which $TARGET-cc)" ] && return fi COMMON_CONFIG="CC=\"$HOST-gcc -static --static\" CXX=\"$HOST-g++ -static --static\"" export -n HOST OUTPUT="$OUTPUT/${RENAME:-$TARGET}-$TYPE" fi - if [ -e "$OUTPUT.sqf" ] || [ -e "$OUTPUT/bin/$TARGET-ld" ] || - [ -e "$OUTPUT/bin/ld" ] + if [ -e "$OUTPUT.sqf" ] || [ -e "$OUTPUT/bin/$TARGET-cc" ] || + [ -e "$OUTPUT/bin/cc" ] then return fi -- cgit v1.2.3