On Sun, May 26 2019, Christian Weisgerber <naddy@mips.inka.de> wrote:
> USE_LLD=No is confusing on aarch64. The setting creates a wrapper
> script ${WRKDIR}/bin/ld that execs /usr/bin/ld.bfd... which does
> not exist on aarch64, resulting in build errors like
>
> configure: error: C compiler cannot create executables
> See `config.log' for more details
>
> I'm uncertain what to do about this. Add yet another variable
> no_lld_on_this_arch to arch-defines.mk and set IGNORE when handling
> USE_LLD?
I'd be fine with this ("no_ld_bfd_on_this_arch").
> Currently, aarch64 is the only architecture where ld.bfd does not
> exist.
So far we only need this for one arch, maybe a cheaper approach would be
enough? The diff below just tests whether ld.bfd exists.
Index: bsd.port.mk
===================================================================
RCS file: /cvs/ports/infrastructure/mk/bsd.port.mk,v
retrieving revision 1.1467
diff -u -p -r1.1467 bsd.port.mk
--- bsd.port.mk 20 May 2019 22:15:13 -0000 1.1467
+++ bsd.port.mk 27 May 2019 10:07:18 -0000
@@ -802,6 +802,8 @@ _LD_PROGRAM = /usr/bin/ld.lld
. if ! ${PROPERTIES:Mlld}
_NONDEFAULT_LD = Yes
. endif
+.elif !exists(/usr/bin/ld.bfd)
+IGNORE = "requires /usr/bin/ld.bfd"
.else
_LD_PROGRAM = /usr/bin/ld.bfd
. if ${PROPERTIES:Mlld}
@@ -1888,7 +1890,7 @@ _FAKE_TREE_LIST = \
${_nls}/{ru_RU.CP866,ru_RU.ISO_8859-5,ru_RU.KOI8-R} \
${_nls}/{sv_SE.ISO_8859-1,uk_UA.KOI8-U} \
${WRKINST}${VARBASE}/{db,games,log,spool,www}
-
+
# packing list utilities. This generates a packing list from the WRKINST
# directory. Not perfect, but pretty close. The generated file
# will have to have some tweaks done by hand.
--
jca | PGP : 0x1524E7EE / 5135 92C1 AD36 5293 2BDF DDCC 0DFA 74AE 1524 E7EE
No comments:
Post a Comment