aboutsummaryrefslogtreecommitdiff
path: root/bfd/aclocal.m4
diff options
context:
space:
mode:
authorIan Lance Taylor <ian@airs.com>1999-08-03 16:10:38 +0000
committerIan Lance Taylor <ian@airs.com>1999-08-03 16:10:38 +0000
commitaab084313464de2f91dee130584bc5b62b8a15b5 (patch)
tree581aee1f3e0fd730d8dd35b37fd0aaca3fe18323 /bfd/aclocal.m4
parent08372f14279208e1682dfc35325ade9c648e787e (diff)
downloadgdb-aab084313464de2f91dee130584bc5b62b8a15b5.zip
gdb-aab084313464de2f91dee130584bc5b62b8a15b5.tar.gz
gdb-aab084313464de2f91dee130584bc5b62b8a15b5.tar.bz2
* acinclude.m4 (BFD_CC_FOR_BUILD): Change to use conftest, and to
look for generated file correctly. * aclocal.m4, configure: Rebuild.
Diffstat (limited to 'bfd/aclocal.m4')
-rw-r--r--bfd/aclocal.m421
1 files changed, 12 insertions, 9 deletions
diff --git a/bfd/aclocal.m4 b/bfd/aclocal.m4
index 39df10e..f0753c1 100644
--- a/bfd/aclocal.m4
+++ b/bfd/aclocal.m4
@@ -36,15 +36,18 @@ if test "x$cross_compiling" = "xno"; then
EXEEXT_FOR_BUILD='$(EXEEXT)'
else
AC_CACHE_CHECK([for build system executable suffix], bfd_cv_build_exeext,
- [cat > ac_c_test.c << 'EOF'
-int main() {
-/* Nothing needed here */
-}
-EOF
- ${CC_FOR_BUILD} -o ac_c_test am_c_test.c 1>&5 2>&5
- bfd_cv_build_exeext=`echo ac_c_test.* | grep -v ac_c_test.c | sed -e s/ac_c_test//`
- rm -f ac_c_test*
- test x"${bfd_cv_build_exeext}" = x && bfd_cv_build_exeext=no])
+ [rm -f conftest*
+ echo 'int main () { return 0; }' > conftest.c
+ bfd_cv_build_exeext=
+ ${CC_FOR_BUILD} -o conftest conftest.c 1>&5 2>&5
+ for file in conftest.*; do
+ case $file in
+ *.c | *.o | *.obj | *.ilk | *.pdb) ;;
+ *) bfd_cv_build_exeext=`echo $file | sed -e s/conftest//` ;;
+ esac
+ done
+ rm -f conftest*
+ test x"${bfd_cv_build_exeext}" = x && bfd_cv_build_exeext=no])
EXEEXT_FOR_BUILD=""
test x"${bfd_cv_build_exeext}" != xno && EXEEXT_FOR_BUILD=${bfd_cv_build_exeext}
fi