From: Jan Beulich Date: Fri, 13 Feb 2026 09:19:23 +0000 (+0100) Subject: ld: move symlink-ing of ldscripts a little earlier X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=6c625668326b342247791f47492756c643010eb7;p=thirdparty%2Fbinutils-gdb.git ld: move symlink-ing of ldscripts a little earlier Following up commit a29a6230b820 "PR 33629 ldscripts symlink in .libs/ created too late", move the symlink-ing ahead of the linking of the final binary, to eliminate the slim chance of the build being interrupted (or failing) at that (so far) final step. If that happened, a subsequent make invocation with no other changes made would then not re-attempt this step. Necessarily with this the test for the existence of the binary needs to be removed. Perhaps that shouldn't have been there anyway, the more that the check was lacking $(EXEEXT). --- diff --git a/ld/Makefile.am b/ld/Makefile.am index a81cb4578bc..20d17c23f33 100644 --- a/ld/Makefile.am +++ b/ld/Makefile.am @@ -661,8 +661,8 @@ EXTRA_ld_new_SOURCES += $(ALL_EMULATION_SOURCES) $(ALL_64_EMULATION_SOURCES) # The standard rule plus set up a symlink when --enable-shared for "make check" ld-new$(EXEEXT): $(ld_new_OBJECTS) $(ld_new_DEPENDENCIES) $(EXTRA_ld_new_DEPENDENCIES) @rm -f ld-new$(EXEEXT) + $(AM_V_at)cd .libs; test -e ldscripts || $(LN_S) ../ldscripts . $(AM_V_CCLD)$(LINK) $(ld_new_OBJECTS) $(ld_new_LDADD) $(LIBS) - $(AM_V_at)cd .libs; test ! -e ld-new || test -e ldscripts || $(LN_S) ../ldscripts . # This is the real libbfd.a and libctf.a created by libtool. TESTBFDLIB = @TESTBFDLIB@ diff --git a/ld/Makefile.in b/ld/Makefile.in index 9de1ec5f676..ddc2732a03f 100644 --- a/ld/Makefile.in +++ b/ld/Makefile.in @@ -2370,8 +2370,8 @@ $(ALL_EMULATION_SOURCES) $(ALL_64_EMULATION_SOURCES): $(GEN_DEPENDS) # The standard rule plus set up a symlink when --enable-shared for "make check" ld-new$(EXEEXT): $(ld_new_OBJECTS) $(ld_new_DEPENDENCIES) $(EXTRA_ld_new_DEPENDENCIES) @rm -f ld-new$(EXEEXT) + $(AM_V_at)cd .libs; test -e ldscripts || $(LN_S) ../ldscripts . $(AM_V_CCLD)$(LINK) $(ld_new_OBJECTS) $(ld_new_LDADD) $(LIBS) - $(AM_V_at)cd .libs; test ! -e ld-new || test -e ldscripts || $(LN_S) ../ldscripts . check-DEJAGNU: site.exp srcroot=`cd $(srcdir) && pwd`; export srcroot; \