]> git.ipfire.org Git - thirdparty/dhcpcd.git/commitdiff
Revert [26bc10be24] as some compile can't output to /dev/null.
authorRoy Marples <roy@marples.name>
Mon, 30 Jun 2014 09:44:07 +0000 (09:44 +0000)
committerRoy Marples <roy@marples.name>
Mon, 30 Jun 2014 09:44:07 +0000 (09:44 +0000)
configure

index a0d093ae4a1c54cc4db6282c1d8139ff5ee927d2..0b17569695b059796f1388354bee86dcb35a88df 100755 (executable)
--- a/configure
+++ b/configure
@@ -272,8 +272,17 @@ if ! type "$CC" >/dev/null 2>&1; then
 fi
 
 echo "Using compiler .. $CC"
-if ! echo "int main(void) { return 0; }" | $CC -x c -o /dev/null - 2>/dev/null
-then
+cat <<EOF >_test.c
+int main(void) {
+       return 0;
+}
+EOF
+_CC=false
+if $CC _test.c -o _test >/dev/null 2>&1; then
+       [ -x _test ] && _CC=true
+fi
+rm -f _test.c _test
+if ! $_CC; then
        echo "$CC does not create executables"
        exit 1
 fi