Use a non-empty test program to test ability to link.
authorSandra Loosemore <sandra@codesourcery.com>
Wed, 12 Feb 2020 20:20:15 +0000 (12:20 -0800)
committerSandra Loosemore <sandra@codesourcery.com>
Wed, 12 Feb 2020 21:22:07 +0000 (13:22 -0800)
On bare-metal targets, I/O support is typically provided by a BSP and
requires a linker script and/or hosting library to be specified on the
linker command line.  Linking an empty program with the default linker
script may succeed, however, which confuses libstdc++ configuration
when programs that probe for the presence of various I/O features fail
with link errors.

2020-02-12  Sandra Loosemore  <sandra@codesourcery.com>

PR libstdc++/79193
PR libstdc++/88999

config/
* no-executables.m4: Use a non-empty program to test for linker
support.

libgcc/
* configure: Regenerated.

libgfortran/
* configure: Regenerated.

libiberty/
* configure: Regenerated.

libitm/
* configure: Regenerated.

libobjc/
* configure: Regenerated.

libquadmath/
* configure: Regenerated.

libssp/
* configure: Regenerated.

libstdc++v-3/
* configure: Regenerated.

18 files changed:
config/ChangeLog
config/no-executables.m4
libgcc/ChangeLog
libgcc/configure
libgfortran/ChangeLog
libgfortran/configure
libiberty/ChangeLog
libiberty/configure
libitm/ChangeLog
libitm/configure [changed mode: 0644->0755]
libobjc/ChangeLog
libobjc/configure
libquadmath/ChangeLog
libquadmath/configure
libssp/ChangeLog
libssp/configure
libstdc++-v3/ChangeLog
libstdc++-v3/configure

index f1fec81a0ca7d491dce4bd10c73fc5ca0c745365..01428dd04ee3be63b382277a8f04dfce1fe76c64 100644 (file)
@@ -1,3 +1,11 @@
+2020-02-12  Sandra Loosemore  <sandra@codesourcery.com>
+
+       PR libstdc++/79193
+       PR libstdc++/88999
+
+       * no-executables.m4: Use a non-empty program to test for linker
+       support.
+
 2020-02-01  Andrew Burgess  <andrew.burgess@embecosm.com>
 
        * lib-link.m4 (AC_LIB_LINKFLAGS_BODY): Update shell syntax.
index 90616245ef92bfe2645382d9a78060bf90bdab3f..6842f84fba3268bc20d4f1860f67ea9c4f6947b2 100644 (file)
@@ -25,7 +25,9 @@ AC_BEFORE([$0], [_AC_COMPILER_EXEEXT])
 AC_BEFORE([$0], [AC_LINK_IFELSE])
 
 m4_define([_AC_COMPILER_EXEEXT],
-[AC_LANG_CONFTEST([AC_LANG_PROGRAM()])
+[AC_LANG_CONFTEST([AC_LANG_PROGRAM(
+                    [#include <stdio.h>],
+                    [printf ("hello world\n");])])
 # FIXME: Cleanup?
 AS_IF([AC_TRY_EVAL(ac_link)], [gcc_no_link=no], [gcc_no_link=yes])
 if test x$gcc_no_link = xyes; then
index 917d0e765681a916c9e93aeddface178c368ffa4..7b46ccb40c953bb051910268c9bf253bc28caf30 100644 (file)
@@ -1,3 +1,10 @@
+2020-02-12  Sandra Loosemore  <sandra@codesourcery.com>
+
+       PR libstdc++/79193
+       PR libstdc++/88999
+
+       * configure: Regenerated.
+
 2020-02-10  Jeff Law  <law@redhat.com>
 
        * config/frv/frvbegin.c: Use right flags for .ctors and .dtors
index ab8d4713196553ba93f306ff39e23175f1c857a1..093036acf81c1f5d347e6b6098dde016a0b1db08 100755 (executable)
@@ -3553,11 +3553,11 @@ done
 
 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
 /* end confdefs.h.  */
-
+#include <stdio.h>
 int
 main ()
 {
-
+printf ("hello world\n");
   ;
   return 0;
 }
index fe7e48040cd19949d9d187b128a760f18cb19180..5632fbc8272b6db1573b09fa843bc4c944aefadf 100644 (file)
@@ -1,3 +1,10 @@
+2020-02-12  Sandra Loosemore  <sandra@codesourcery.com>
+
+       PR libstdc++/79193
+       PR libstdc++/88999
+
+       * configure: Regenerated.
+
 2020-01-24  Maciej W. Rozycki  <macro@wdc.com>
 
        * configure.ac: Handle `--with-toolexeclibdir='.
index 8ba6831c8b13579b4fb89cd12320e7e50d12f18a..d01654e7c4b7f94047f673a7473dd8947f7e1eb2 100755 (executable)
@@ -4042,11 +4042,11 @@ done
 
 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
 /* end confdefs.h.  */
-
+#include <stdio.h>
 int
 main ()
 {
-
+printf ("hello world\n");
   ;
   return 0;
 }
index b3ec2314d89a5a2dcb8d4d25656f0b4f382c271d..84225ad969b02f2745adc2ca03d1f43e1cc151ee 100644 (file)
@@ -1,3 +1,10 @@
+2020-02-12  Sandra Loosemore  <sandra@codesourcery.com>
+
+       PR libstdc++/79193
+       PR libstdc++/88999
+
+       * configure: Regenerated.
+
 2020-02-05  Andrew Burgess  <andrew.burgess@embecosm.com>
 
        * hashtab.c (htab_remove_elt): Make a parameter const.
index 7a34dabec32b0b383bd33f07811757335f4dd39c..d2413f13acf3b18ec41a532c7ff71ff17c582379 100755 (executable)
@@ -3310,11 +3310,11 @@ done
 
 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
 /* end confdefs.h.  */
-
+#include <stdio.h>
 int
 main ()
 {
-
+printf ("hello world\n");
   ;
   return 0;
 }
index feccd160330df2f4a582740fb53352c3fc4ada86..9c70974776cfce89ed4e6de9b02ca776dc9c79d2 100644 (file)
@@ -1,3 +1,10 @@
+2020-02-12  Sandra Loosemore  <sandra@codesourcery.com>
+
+       PR libstdc++/79193
+       PR libstdc++/88999
+
+       * configure: Regenerated.
+
 2020-01-24  Maciej W. Rozycki  <macro@wdc.com>
 
        * configure.ac: Handle `--with-toolexeclibdir='.
old mode 100644 (file)
new mode 100755 (executable)
index db7fce7df1700bbf55e22575eaf25f47c711a48f..b5bba60494403c4a272e5c3d1c58b0b89b79b642 100644 (file)
@@ -1,3 +1,10 @@
+2020-02-12  Sandra Loosemore  <sandra@codesourcery.com>
+
+       PR libstdc++/79193
+       PR libstdc++/88999
+
+       * configure: Regenerated.
+
 2020-01-24  Maciej W. Rozycki  <macro@wdc.com>
 
        * Makefile.in (aclocal_deps): Add `toolexeclibdir.m4'.
index 46124b2a9e01e7e4c93c213b244e3939cc98e102..2f8924e5042fd1f2a1b063765029f88da0cf2d89 100755 (executable)
@@ -2917,11 +2917,11 @@ done
 
 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
 /* end confdefs.h.  */
-
+#include <stdio.h>
 int
 main ()
 {
-
+printf ("hello world\n");
   ;
   return 0;
 }
index 0b1db14d8d6d3a82f5fefc967954fea726edf3f8..2df546a3aa0e3f1b5ae46d08a32854be3362eb00 100644 (file)
@@ -1,3 +1,10 @@
+2020-02-12  Sandra Loosemore  <sandra@codesourcery.com>
+
+       PR libstdc++/79193
+       PR libstdc++/88999
+
+       * configure: Regenerated.
+
 2020-01-24  Maciej W. Rozycki  <macro@wdc.com>
 
        * configure.ac: Handle `--with-toolexeclibdir='.
index 339e80944e6ddf0b7064b35a78972864ae04f2c3..7b45eb7e805f210423ffc5eabf9c5eb046a4d4ab 100755 (executable)
@@ -3461,11 +3461,11 @@ done
 
 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
 /* end confdefs.h.  */
-
+#include <stdio.h>
 int
 main ()
 {
-
+printf ("hello world\n");
   ;
   return 0;
 }
index f1ccde4e36f629cd3a2b805839ceb34f122e9549..9e3e6a687ffc4ff23d1cd52e255899c03e5e27d7 100644 (file)
@@ -1,3 +1,10 @@
+2020-02-12  Sandra Loosemore  <sandra@codesourcery.com>
+
+       PR libstdc++/79193
+       PR libstdc++/88999
+
+       * configure: Regenerated.
+
 2020-01-24  Maciej W. Rozycki  <macro@wdc.com>
 
        * configure.ac: Handle `--with-toolexeclibdir='.
index 5541cf9d9728b74200a88ad675bdd541a51c9156..dd3b41da0f62e252aee92df7c13ddde4d275699e 100755 (executable)
@@ -3402,11 +3402,11 @@ done
 
 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
 /* end confdefs.h.  */
-
+#include <stdio.h>
 int
 main ()
 {
-
+printf ("hello world\n");
   ;
   return 0;
 }
index b2f66e037c4b742213842f22df1071235f0d66ce..922c715c8385faeef101d8feb1b5c39f17d057b8 100644 (file)
@@ -1,3 +1,10 @@
+2020-02-12  Sandra Loosemore  <sandra@codesourcery.com>
+
+       PR libstdc++/79193
+       PR libstdc++/88999
+
+       * configure: Regenerated.
+
 2020-02-12  François Dumont  <fdumont@gcc.gnu.org>
 
        * include/bits/hashtable.h
index a39c33b055d29aa0e1ca1c4984f4f020776d1e4c..9f9c5a2419aa599ff9f330ac510cb8dfbe116c4f 100755 (executable)
@@ -4130,11 +4130,11 @@ done
 
 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
 /* end confdefs.h.  */
-
+#include <stdio.h>
 int
 main ()
 {
-
+printf ("hello world\n");
   ;
   return 0;
 }