summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSam James <sam@gentoo.org>2022-01-23 15:41:27 +0000
committerSam James <sam@gentoo.org>2022-01-23 15:41:27 +0000
commit689f7b50735d60bf3f3afe15de1ea667fa462667 (patch)
tree91cda4d2b25bb9dcf1f2cfcb4da1add9600457da /dev-libs/libbsd
parentmedia-sound/vmpk: Stabilize 0.8.6 x86, #831887 (diff)
downloadgentoo-689f7b50735d60bf3f3afe15de1ea667fa462667.tar.gz
gentoo-689f7b50735d60bf3f3afe15de1ea667fa462667.tar.bz2
gentoo-689f7b50735d60bf3f3afe15de1ea667fa462667.zip
dev-libs/libbsd: respect OBJDUMP
Closes: https://bugs.gentoo.org/831863 Signed-off-by: Sam James <sam@gentoo.org>
Diffstat (limited to 'dev-libs/libbsd')
-rw-r--r--dev-libs/libbsd/files/libbsd-0.11.4-build-respect-OBJDUMP.patch26
-rw-r--r--dev-libs/libbsd/libbsd-0.11.4.ebuild13
2 files changed, 38 insertions, 1 deletions
diff --git a/dev-libs/libbsd/files/libbsd-0.11.4-build-respect-OBJDUMP.patch b/dev-libs/libbsd/files/libbsd-0.11.4-build-respect-OBJDUMP.patch
new file mode 100644
index 000000000000..2f9df4475bbe
--- /dev/null
+++ b/dev-libs/libbsd/files/libbsd-0.11.4-build-respect-OBJDUMP.patch
@@ -0,0 +1,26 @@
+https://gitlab.freedesktop.org/libbsd/libbsd/-/merge_requests/16
+
+From 3fbb632b460a4f2d37036cf3959736938494459e Mon Sep 17 00:00:00 2001
+From: Sam James <sam@gentoo.org>
+Date: Sun, 23 Jan 2022 15:36:55 +0000
+Subject: [PATCH] build: respect $(OBJDUMP)
+
+We already search for it in `./configure` so let's respect
+the result of that search.
+
+This helps with cross-compilation and any other cases
+where one might want to choose a different toolchain.
+
+Bug: https://bugs.gentoo.org/831863
+Signed-off-by: Sam James <sam@gentoo.org>
+--- a/src/Makefile.am
++++ b/src/Makefile.am
+@@ -141,7 +141,7 @@ TRANSPARENT_LIBMD_DEPENDS = format.ld
+
+ format.ld:
+ $(CC) -shared -nostdlib -nostartfiles -x assembler /dev/null -o $@.so
+- objdump -f $@.so | sed -n 's/.*file format \(.*\)/OUTPUT_FORMAT(\1)/;T;p' > $@
++ $(OBJDUMP) -f $@.so | sed -n 's/.*file format \(.*\)/OUTPUT_FORMAT(\1)/;T;p' > $@
+ rm -f $@.so
+ endif
+
diff --git a/dev-libs/libbsd/libbsd-0.11.4.ebuild b/dev-libs/libbsd/libbsd-0.11.4.ebuild
index 55d75e728bd8..ca1cbf076ce2 100644
--- a/dev-libs/libbsd/libbsd-0.11.4.ebuild
+++ b/dev-libs/libbsd/libbsd-0.11.4.ebuild
@@ -3,7 +3,7 @@
EAPI=8
-inherit multilib-minimal
+inherit autotools multilib-minimal
DESCRIPTION="Library to provide useful functions commonly found on BSD systems"
HOMEPAGE="https://libbsd.freedesktop.org/wiki/ https://gitlab.freedesktop.org/libbsd/libbsd"
@@ -19,6 +19,17 @@ DEPEND="${RDEPEND}
>=sys-kernel/linux-headers-3.17
"
+PATCHES=(
+ "${FILESDIR}"/${PN}-0.11.4-build-respect-OBJDUMP.patch
+)
+
+src_prepare() {
+ default
+
+ # Needed for objdump patch
+ eautoreconf
+}
+
multilib_src_configure() {
# The build system will install libbsd-ctor.a despite of USE="-static-libs"
# which is correct, see: