summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorWANG Xuerui <xen0n@gentoo.org>2023-01-13 15:27:35 +0800
committerSam James <sam@gentoo.org>2023-01-14 19:14:36 +0000
commit21d7ce6b425ba815dda6adb86ac7779972d5d12c (patch)
tree86c54fee70bfd8b5f5b11a47b5c152f047864ee9 /sys-devel/binutils/binutils-2.32-r2.ebuild
parentsys-libs/zlib: fix build with lld-16 (diff)
downloadgentoo-21d7ce6b425ba815dda6adb86ac7779972d5d12c.tar.gz
gentoo-21d7ce6b425ba815dda6adb86ac7779972d5d12c.tar.bz2
gentoo-21d7ce6b425ba815dda6adb86ac7779972d5d12c.zip
sys-devel/binutils: fix build with lld-16
Signed-off-by: WANG Xuerui <xen0n@gentoo.org> Signed-off-by: Sam James <sam@gentoo.org>
Diffstat (limited to 'sys-devel/binutils/binutils-2.32-r2.ebuild')
-rw-r--r--sys-devel/binutils/binutils-2.32-r2.ebuild9
1 files changed, 8 insertions, 1 deletions
diff --git a/sys-devel/binutils/binutils-2.32-r2.ebuild b/sys-devel/binutils/binutils-2.32-r2.ebuild
index d19fc5bc163c..df54d7b7423d 100644
--- a/sys-devel/binutils/binutils-2.32-r2.ebuild
+++ b/sys-devel/binutils/binutils-2.32-r2.ebuild
@@ -1,4 +1,4 @@
-# Copyright 1999-2022 Gentoo Authors
+# Copyright 1999-2023 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
@@ -162,6 +162,13 @@ src_configure() {
# Keep things sane
strip-flags
+ # ideally we want !tc-ld-is-bfd for best future-proofing, but it needs
+ # https://github.com/gentoo/gentoo/pull/28355
+ # mold needs this too but right now tc-ld-is-mold is also not available
+ if tc-ld-is-lld; then
+ append-ldflags -Wl,--undefined-version
+ fi
+
local x
echo
for x in CATEGORY CBUILD CHOST CTARGET CFLAGS LDFLAGS ; do