devel/binutils: configure with --enable-new-dtags

This makes binutils ld use DT_RUNPATH instead of DT_RPATH by default
for FreeBSD targets and brings it in line with LLVM ld.

The difference between the two is that DT_RUNPATH has a lower priority
than the LD_LIBRARY_PATH environment variable.  This variable is used
by libtool to override DT_RUNPATH when running programs directly from
the build directory (e.g. during make test).

PR:		259446
Approved by:	maintainer timeout (2 weeks)

(cherry picked from commit dea411ca0c)
This commit is contained in:
Tijl Coosemans 2021-10-25 18:33:09 +02:00
parent f5532da8b8
commit 06072fa94d
1 changed files with 6 additions and 1 deletions

View File

@ -2,7 +2,7 @@
PORTNAME= binutils
PORTVERSION= 2.37
PORTREVISION= 1
PORTREVISION= 2
PORTEPOCH?= 1
CATEGORIES?= devel
MASTER_SITES= SOURCEWARE/binutils/releases
@ -115,6 +115,11 @@ PLIST_SUB+= GOLD=""
PLIST_SUB+= GOLD="@comment "
.endif
.if (${FLAVOR} == native && ${OPSYS} == FreeBSD) || \
(${FLAVOR} != native && ${BUTARGET:M*freebsd*})
CONFIGURE_ARGS+= --enable-new-dtags
.endif
.if ${ARCH} == amd64
CONFIGURE_TARGET= x86_64-portbld-freebsd${OSREL}
.elif ${ARCH} == powerpcspe