]> git.xonotic.org Git - xonotic/xonotic.git/blobdiff - all
Merge branch 'master' of git://de.git.xonotic.org/xonotic/xonotic
[xonotic/xonotic.git] / all
diff --git a/all b/all
index 705423c8748235d0ba2644103ed0ccafebb97550..388a6e39b82ddfe0954162373f5091dcedb42c92 100755 (executable)
--- a/all
+++ b/all
@@ -963,7 +963,9 @@ case "$cmd" in
                                                [5-9]*|[1-9][0-9]*|4.[3-9]*|4.[1-9][0-9]*)
                                                        # gcc 4.3 or higher
                                                        # -march=native is broken < 4.3
-                                                       export CC="$CC -mtune=native -march=native"
+                                                       if $CC -mtune=native -march=native misc/tools/conftest.c -o conftest >/dev/null 2>&1; then
+                                                               export CC="$CC -mtune=native -march=native"
+                                                       fi
                                                        ;;
                                        esac
                                        if [ -n "$WE_HATE_OUR_USERS" ]; then
@@ -1043,6 +1045,17 @@ case "$cmd" in
                        fi
                fi
 
+               
+               if ! verbose $CC misc/tools/conftest.c -o conftest; then
+                       msg ""
+                       msg "COMPILER"
+                       msg ""
+                       msg "Y U NO COMPILE CODE?"
+                       msg ""
+                       exit 1
+               fi
+               rm -f conftest
+
                verbose cd "$d0/d0_blind_id"
                if ! $compiled0; then
                        # compilation of crypto library failed