summaryrefslogtreecommitdiff
path: root/sys-fs
diff options
context:
space:
mode:
authorSergei Trofimovich <slyfox@gentoo.org>2018-04-12 10:41:38 +0100
committerSergei Trofimovich <slyfox@gentoo.org>2018-04-12 10:41:58 +0100
commit665fca34ff359676b9ebe0f855f3716ad85be312 (patch)
tree6c36c388f2566b92f637506f6768eba8d2bd7656 /sys-fs
parentmedia-sound/murmur: Minor ebuild adjustment. (diff)
downloadgentoo-665fca34ff359676b9ebe0f855f3716ad85be312.tar.gz
gentoo-665fca34ff359676b9ebe0f855f3716ad85be312.tar.bz2
gentoo-665fca34ff359676b9ebe0f855f3716ad85be312.zip
sys-fs/btrfs-progs: fix btrfs.static linking, bug #652966
btrfs.static was not linked against internal libbtrfsutil: https://www.spinics.net/lists/linux-btrfs/msg76763.html This caused link failure due to unresolved symbols. Reported-by: Attila Tóth Closes: https://bugs.gentoo.org/652966 Package-Manager: Portage-2.3.28, Repoman-2.3.9
Diffstat (limited to 'sys-fs')
-rw-r--r--sys-fs/btrfs-progs/btrfs-progs-4.16.ebuild4
-rw-r--r--sys-fs/btrfs-progs/files/btrfs-progs-4.16-static-linkage.patch27
2 files changed, 31 insertions, 0 deletions
diff --git a/sys-fs/btrfs-progs/btrfs-progs-4.16.ebuild b/sys-fs/btrfs-progs/btrfs-progs-4.16.ebuild
index 0936ade75910..8d3f9db2dd2d 100644
--- a/sys-fs/btrfs-progs/btrfs-progs-4.16.ebuild
+++ b/sys-fs/btrfs-progs/btrfs-progs-4.16.ebuild
@@ -72,6 +72,10 @@ fi
REQUIRED_USE="python? ( ${PYTHON_REQUIRED_USE} )"
+PATCHES=(
+ "${FILESDIR}"/${P}-static-linkage.patch
+)
+
pkg_setup() {
use python && python-single-r1_pkg_setup
}
diff --git a/sys-fs/btrfs-progs/files/btrfs-progs-4.16-static-linkage.patch b/sys-fs/btrfs-progs/files/btrfs-progs-4.16-static-linkage.patch
new file mode 100644
index 000000000000..b8a7d8b79f06
--- /dev/null
+++ b/sys-fs/btrfs-progs/files/btrfs-progs-4.16-static-linkage.patch
@@ -0,0 +1,27 @@
+https://www.spinics.net/lists/linux-btrfs/msg76763.html
+Reported-by: Attila Tóth
+Bug: https://bugs.gentoo.org/652966
+diff --git a/Makefile b/Makefile
+index 5ba76d2..dc3a31a 100644
+--- a/Makefile
++++ b/Makefile
+@@ -264,6 +264,7 @@ static_libbtrfs_objects = $(patsubst %.o, %.static.o, $(libbtrfs_objects))
+ static_convert_objects = $(patsubst %.o, %.static.o, $(convert_objects))
+ static_mkfs_objects = $(patsubst %.o, %.static.o, $(mkfs_objects))
+ static_image_objects = $(patsubst %.o, %.static.o, $(image_objects))
++static_libbtrfsutil_objects = $(patsubst %.o, %.static.o, $(libbtrfsutil_objects))
+
+ libs_shared = libbtrfs.so.0.1 libbtrfsutil.so.$(libbtrfsutil_version)
+ libs_static = libbtrfs.a libbtrfsutil.a
+@@ -453,7 +454,7 @@ btrfs: btrfs.o $(objects) $(cmds_objects) $(libs_static)
+ @echo " [LD] $@"
+ $(Q)$(CC) -o $@ $^ $(LDFLAGS) $(LIBS) $(LIBS_COMP)
+
+-btrfs.static: btrfs.static.o $(static_objects) $(static_cmds_objects) $(static_libbtrfs_objects)
++btrfs.static: btrfs.static.o $(static_objects) $(static_cmds_objects) $(static_libbtrfs_objects) $(static_libbtrfsutil_objects)
+ @echo " [LD] $@"
+ $(Q)$(CC) -o $@ $^ $(STATIC_LDFLAGS) $(STATIC_LIBS) $(STATIC_LIBS_COMP)
+
+--
+2.17.0
+