NetBSD-Bugs archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: toolchain/60000: split debug data rules broke ${.TARGET}-dependent flags



The following reply was made to PR toolchain/60000; it has been noted by GNATS.

From: Taylor R Campbell <riastradh%NetBSD.org@localhost>
To: gnats-bugs%NetBSD.org@localhost, netbsd-bugs%NetBSD.org@localhost
Cc: Nick Hudson <skrll%NetBSD.org@localhost>
Subject: Re: toolchain/60000: split debug data rules broke ${.TARGET}-dependent flags
Date: Fri, 13 Feb 2026 08:11:36 +0000

 This is a multi-part message in MIME format.
 --=_3GH/d8a4GiEuk6sY511/abKYWvHzDwXu
 
 Attached patch aims to fix this.  I searched for `.${.TARGET}' and
 this is the only one that came up, so maybe we're already otherwise
 clean of this problem.
 
 --=_3GH/d8a4GiEuk6sY511/abKYWvHzDwXu
 Content-Type: text/plain; charset="ISO-8859-1"; name="pr60000-bsdprogmkldstaticpie"
 Content-Transfer-Encoding: quoted-printable
 Content-Disposition: attachment; filename="pr60000-bsdprogmkldstaticpie.patch"
 
 # HG changeset patch
 # User Taylor R Campbell <riastradh%NetBSD.org@localhost>
 # Date 1770970107 0
 #      Fri Feb 13 08:08:27 2026 +0000
 # Branch trunk
 # Node ID f083a332526e1831201892f13204a6af0aabba6c
 # Parent  1b592182187334d0db950753ee819bfab9e74ed8
 # EXP-Topic riastradh-pr60000-bsdprogmkldstaticpie
 bsd.prog.mk: Respect LDSTATIC.${PROG}, not LDSTATIC.${PROG}.link.
 
 PR toolchain/60000: split debug data rules broke ${.TARGET}-dependent
 flags
 
 diff -r 1b5921821873 -r f083a332526e share/mk/bsd.prog.mk
 --- a/share/mk/bsd.prog.mk	Fri Feb 13 05:26:10 2026 +0000
 +++ b/share/mk/bsd.prog.mk	Fri Feb 13 08:08:27 2026 +0000
 @@ -38,7 +38,7 @@ CLEANFILES+=3D a.out [Ee]rrs mklog core *.
  .if defined(MKPIE) && (${MKPIE} !=3D "no") && !defined(NOPIE)
  CFLAGS+=3D	${PIE_CFLAGS}
  AFLAGS+=3D	${PIE_AFLAGS}
 -LDFLAGS+=3D	${"${LDSTATIC.${.TARGET}}" =3D=3D "-static" :? : ${PIE_LDFLAGS=
 }}
 +# PIE_LDFLAGS added on a per-PROG basis below depending on LDSTATIC.${PROG}
  .endif
 =20
  CFLAGS+=3D	${COPTS}
 @@ -470,6 +470,7 @@ PAXCTL_FLAGS.${_P}=3D +a
  _DPADD.${_P}=3D		${DPADD}    ${DPADD.${_P}}
  _LDADD.${_P}=3D		${LDADD}    ${LDADD.${_P}}
  _LDFLAGS.${_P}=3D		${LDFLAGS}  ${LDFLAGS.${_P}}
 +_LDFLAGS.${_P}+=3D	${"${LDSTATIC.${_P}}" =3D=3D "-static" :? : ${PIE_LDFLA=
 GS}}
  .if ${MKSANITIZER} !=3D "yes"
  # Sanitizers don't support static build.
  _LDSTATIC.${_P}=3D	${LDSTATIC} ${LDSTATIC.${_P}}
 
 --=_3GH/d8a4GiEuk6sY511/abKYWvHzDwXu--
 


Home | Main Index | Thread Index | Old Index