Gentoo Archives: gentoo-commits

From: Mike Gilbert <floppym@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: sys-apps/systemd/files/, sys-apps/systemd/
Date: Sun, 11 Jul 2021 14:41:41
Message-Id: 1626014232.afc5cea9987daa5c97eb3dd96efae40663153ecf.floppym@gentoo
1 commit: afc5cea9987daa5c97eb3dd96efae40663153ecf
2 Author: Mike Gilbert <floppym <AT> gentoo <DOT> org>
3 AuthorDate: Sun Jul 11 14:37:12 2021 +0000
4 Commit: Mike Gilbert <floppym <AT> gentoo <DOT> org>
5 CommitDate: Sun Jul 11 14:37:12 2021 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=afc5cea9
7
8 sys-apps/systemd: add static link info to libudev.pc
9
10 Bug: https://bugs.gentoo.org/801070
11 Signed-off-by: Mike Gilbert <floppym <AT> gentoo.org>
12
13 sys-apps/systemd/files/249-libudev-static.patch | 26 ++++++++++++++++++++++
14 ...systemd-249-r1.ebuild => systemd-249-r2.ebuild} | 0
15 2 files changed, 26 insertions(+)
16
17 diff --git a/sys-apps/systemd/files/249-libudev-static.patch b/sys-apps/systemd/files/249-libudev-static.patch
18 new file mode 100644
19 index 00000000000..73375b716e9
20 --- /dev/null
21 +++ b/sys-apps/systemd/files/249-libudev-static.patch
22 @@ -0,0 +1,26 @@
23 +From f2c57d4f3805775e0ffdc80ce578eaa737017d31 Mon Sep 17 00:00:00 2001
24 +From: Mike Gilbert <floppym@g.o>
25 +Date: Fri, 9 Jul 2021 13:05:23 -0400
26 +Subject: [PATCH] libudev: add "Libs.private: -lrt -pthread" to libudev.pc
27 +
28 +This resolves a failure when linking cryptsetup.static against libudev.a.
29 +
30 +```
31 +libtool: link: x86_64-pc-linux-gnu-gcc -Wall -O2 -pipe -march=amdfam10 -static -O2 -o cryptsetup.static lib/utils_crypt.o lib/utils_loop.o lib/utils_io.o lib/utils_blkid.o src/utils_tools.o src/utils_password.o src/utils_luks2.o src/utils_blockdev.o src/cryptsetup.o -pthread -pthread -Wl,--as-needed ./.libs/libcryptsetup.a -largon2 -lrt -ljson-c -lpopt -luuid -lblkid -lssl -lcrypto -lz -ldl -ldevmapper -lm -lpthread -ludev -pthread
32 +/usr/lib/gcc/x86_64-pc-linux-gnu/11.1.0/../../../../x86_64-pc-linux-gnu/bin/ld: /usr/lib/gcc/x86_64-pc-linux-gnu/11.1.0/../../../../lib64/libudev.a(src_libsystemd_sd-daemon_sd-daemon.c.o): in function `sd_is_mq':
33 +(.text.sd_is_mq+0x3a): undefined reference to `mq_getattr'
34 +```
35 +---
36 + src/libudev/libudev.pc.in | 1 +
37 + 1 file changed, 1 insertion(+)
38 +
39 +diff --git a/src/libudev/libudev.pc.in b/src/libudev/libudev.pc.in
40 +index 89028aaa6bf2..1d6487fa4084 100644
41 +--- a/src/libudev/libudev.pc.in
42 ++++ b/src/libudev/libudev.pc.in
43 +@@ -16,4 +16,5 @@ Name: libudev
44 + Description: Library to access udev device information
45 + Version: {{PROJECT_VERSION}}
46 + Libs: -L${libdir} -ludev
47 ++Libs.private: -lrt -pthread
48 + Cflags: -I${includedir}
49
50 diff --git a/sys-apps/systemd/systemd-249-r1.ebuild b/sys-apps/systemd/systemd-249-r2.ebuild
51 similarity index 100%
52 rename from sys-apps/systemd/systemd-249-r1.ebuild
53 rename to sys-apps/systemd/systemd-249-r2.ebuild