ar="${cross_prefix}${ar}"
strip="${cross_prefix}${strip}"
-if [ ! -x "`which $cc`" ] ; then
- echo "Compiler $cc could not be found"
- exit
+# check that the C compiler works.
+cat > $TMPC <<EOF
+int main(void) {}
+EOF
+
+if $cc -c -o $TMPO $TMPC 2>/dev/null ; then
+ : C compiler works ok
+else
+ echo "ERROR: \"$cc\" either does not exist or does not work"
+ exit 1
fi
if test "$mingw32" = "yes" ; then
fi
# the following are Linux specific
if [ "$user" = "yes" ] ; then
- target_list="i386-user arm-user armeb-user sparc-user ppc-user mips-user mipsel-user sh4-user $target_list"
+ target_list="i386-user arm-user armeb-user sparc-user ppc-user mips-user mipsel-user $target_list"
fi
else
target_list=`echo "$target_list" | sed -e 's/,/ /g'`