[PATCH]: A patch for ld/testsuite

Ian Lance Taylor ian@zembu.com
Sat Feb 26 15:19:00 GMT 2000

   Date: Sat, 26 Feb 2000 08:53:43 -0800
   From: Geoff Keating <geoffk@cygnus.com>

   >    Sun Oct 10 10:02:51 1999  H.J. Lu  (hjl@gnu.org)
   > 	   * lib/ld-lib.exp (default_ld_link): Added "$LIBS" to libs.
   > This is OK.
   > Geoff, this is only used when testing a native configuration.  That is
   > the only time it makes sense to use HOSTING_LIBS.

   It seems to be used in other places too.  There are occurrences of
   'ld-link' in these files, as well as bootstrap.exp:

   ld-cdtest/cdtest.exp:if ![ld_link $ld tmpdir/cdtest {tmpdir/cdtest-foo.o tmpdir/cdtest-bar.o tmpdir/cdtest-main.o}] {
   ld-cdtest/cdtest.exp:    if ![ld_link $ld tmpdir/cdtest tmpdir/cdtest.o] {
   ld-elfvers/vers.exp:    if {![ld_link $ld $tmpdir/$execname "$tmpdir/$execname.o $other_lib $script_arg"]}     {
   ld-elfvers/vers.exp:    if {![ld_link $ld $tmpdir/$execname "$flags $tmpdir/$execname.o $solibname_lib"]}     {
   ld-shared/shared.exp:    if ![ld_link $ld $tmpdir/$progname "-rpath $rpath $tmpdir/$main $tmpdir/$progname.so"] {

   Are these all native-only tests?  I'm pretty sure the versioning tests
   also run on a cross.

Those are all native-only tests.  Note the test for isnative near the
start of each of those files.

I know they are native-only because ld_link itself is native-only.  It
uses the newly built linker, but it links against HOSTING_LIBS, which
can only work if the host and target are the same.

I think you mentioned that there could be a problem if build != host,
and you're right.  But there is already a problem in that case: the
linker binary will not run at all.


More information about the Binutils mailing list