[PATCH 08/94] x11-libs/libpciaccess: add static-libs for GNU Hurd

Sam James <[email protected]>
Newsgroups gmane.linux.gentoo.devel
Message-ID <0354ba5f2af2fb959493d21204b05ee7d204a2aa.1774994283.git.sam@gentoo.org>
This is needed by sys-kernel/hurd which installs static versions of
some binaries for rescue purposes.

Signed-off-by: Sam James <[email protected]>
---
 .../libpciaccess/libpciaccess-0.18.1.ebuild     | 17 ++++++++++++++---
 1 file changed, 14 insertions(+), 3 deletions(-)

diff --git a/x11-libs/libpciaccess/libpciaccess-0.18.1.ebuild b/x11-libs/libpciaccess/libpciaccess-0.18.1.ebuild
index 45525cde55ba7..53d2f4c20f53d 100644
--- a/x11-libs/libpciaccess/libpciaccess-0.18.1.ebuild
+++ b/x11-libs/libpciaccess/libpciaccess-0.18.1.ebuild
@@ -1,14 +1,14 @@
-# Copyright 1999-2025 Gentoo Authors
+# Copyright 1999-2026 Gentoo Authors
 # Distributed under the terms of the GNU General Public License v2
 
 EAPI=8
 
 XORG_MULTILIB=yes
-inherit xorg-3 meson-multilib
+inherit dot-a xorg-3 meson-multilib
 
 DESCRIPTION="Library providing generic access to the PCI bus and devices"
 KEYWORDS="~alpha amd64 arm arm64 ~hppa ~loong ~m68k ~mips ppc ppc64 ~riscv ~s390 ~sparc x86 ~x64-solaris"
-IUSE="zlib"
+IUSE="zlib static-libs"
 
 DEPEND="
 	zlib? (	>=virtual/zlib-1.2.8-r1:=[${MULTILIB_USEDEP}] )"
@@ -19,10 +19,21 @@ src_prepare() {
 	default
 }
 
+src_configure() {
+	use static-libs && lto-guarantee-fat
+	multilib-minimal_src_configure
+}
+
 multilib_src_configure() {
 	local emesonargs=(
+		-Ddefault_library=$(multilib_native_usex static-libs both shared)
 		-Dpci-ids="${EPREFIX}"/usr/share/hwdata
 		$(meson_feature zlib)
 	)
 	meson_src_configure
 }
+
+multilib_src_install_all() {
+	einstalldocs
+	strip-lto-bytecode
+}
-- 
2.53.0
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.