Gentoo Archives: gentoo-commits

From: Joonas Niilola <juippis@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: app-crypt/trousers/files/, app-crypt/trousers/
Date: Tue, 28 Apr 2020 07:45:20
Message-Id: 1588059846.31454f0e773a3d17201258e778b5e29ea9cd7217.juippis@gentoo
1 commit: 31454f0e773a3d17201258e778b5e29ea9cd7217
2 Author: Salah Coronya <salah.coronya <AT> gmail <DOT> com>
3 AuthorDate: Sat Apr 25 04:03:52 2020 +0000
4 Commit: Joonas Niilola <juippis <AT> gentoo <DOT> org>
5 CommitDate: Tue Apr 28 07:44:06 2020 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=31454f0e
7
8 app-crypt/trousers: Fix -fno-common/gcc10 compile error
9
10 Closes: https://bugs.gentoo.org/707244
11 Package-Manager: Portage-2.3.89, Repoman-2.3.20
12 Signed-off-by: Salah Coronya <salah.coronya <AT> gmail.com>
13 Closes: https://github.com/gentoo/gentoo/pull/15509
14 Signed-off-by: Joonas Niilola <juippis <AT> gentoo.org>
15
16 .../files/trousers-0.3.14-fno-common.patch | 15 +++++++++
17 app-crypt/trousers/trousers-0.3.14-r2.ebuild | 39 ++--------------------
18 2 files changed, 17 insertions(+), 37 deletions(-)
19
20 diff --git a/app-crypt/trousers/files/trousers-0.3.14-fno-common.patch b/app-crypt/trousers/files/trousers-0.3.14-fno-common.patch
21 new file mode 100644
22 index 00000000000..5046bc70883
23 --- /dev/null
24 +++ b/app-crypt/trousers/files/trousers-0.3.14-fno-common.patch
25 @@ -0,0 +1,15 @@
26 +diff --git a/src/include/tcsd.h b/src/include/tcsd.h
27 +index 5b9462b..05bae97 100644
28 +--- a/src/include/tcsd.h
29 ++++ b/src/include/tcsd.h
30 +@@ -166,8 +166,8 @@ void thread_signal_init();
31 +
32 + /* signal handling */
33 + #ifndef __APPLE__
34 +-struct sigaction tcsd_sa_int;
35 +-struct sigaction tcsd_sa_chld;
36 ++extern struct sigaction tcsd_sa_int;
37 ++extern struct sigaction tcsd_sa_chld;
38 + #endif
39 +
40 + #endif
41
42 diff --git a/app-crypt/trousers/trousers-0.3.14-r2.ebuild b/app-crypt/trousers/trousers-0.3.14-r2.ebuild
43 index 98591153d56..b94cc955e2d 100644
44 --- a/app-crypt/trousers/trousers-0.3.14-r2.ebuild
45 +++ b/app-crypt/trousers/trousers-0.3.14-r2.ebuild
46 @@ -29,6 +29,7 @@ BDEPEND="virtual/pkgconfig"
47 PATCHES=(
48 "${FILESDIR}/${PN}-0.3.13-nouseradd.patch"
49 "${FILESDIR}/${P}-libressl.patch"
50 + "${FILESDIR}/${P}-fno-common.patch"
51 )
52
53 DOCS="AUTHORS ChangeLog NICETOHAVES README TODO"
54 @@ -37,45 +38,9 @@ DOC_CONTENTS="
55 If you have problems starting tcsd, please check permissions and
56 ownership on /dev/tpm* and ~tss/system.data
57 "
58 -
59 S="${WORKDIR}"
60
61 -pkg_setup() {
62 - # Check for driver (not sure it can be an rdep, because ot depends on the
63 - # version of virtual/linux-sources... Is that supported by portage?)
64 - linux-info_pkg_setup
65 - local tpm_kernel_version tpm_kernel_present tpm_module
66 - kernel_is ge 2 6 12 && tpm_kernel_version="yes"
67 - if linux_config_exists; then
68 - linux_chkconfig_present TCG_TPM && tpm_kernel_present="yes"
69 - else
70 - ewarn "No kernel configuration could be found."
71 - fi
72 - has_version app-crypt/tpm-emulator && tpm_module="yes"
73 - if [[ -n "${tpm_kernel_present}" ]]; then
74 - einfo "Good, you seem to have in-kernel TPM support."
75 - elif [[ -n "${tpm_module}" ]]; then
76 - einfo "Good, you seem to have TPM support with the external module."
77 - if [[ -n "${tpm_kernel_version}" ]]; then
78 - elog
79 - elog "Note that since you have a >=2.6.12 kernel, you could use"
80 - elog "the in-kernel driver instead of (CONFIG_TCG_TPM)."
81 - fi
82 - elif [[ -n "${tpm_kernel_version}" ]]; then
83 - eerror
84 - eerror "To use this package, you will have to activate TPM support"
85 - eerror "in your kernel configuration. That's at least CONFIG_TCG_TPM,"
86 - eerror "plus probably a chip specific driver (like CONFIG_TCG_ATMEL)."
87 - eerror
88 - else
89 - eerror
90 - eerror "To use this package, you should install a TPM driver."
91 - eerror "You can have the following options:"
92 - eerror " - install app-crypt/tpm-emulator"
93 - eerror " - switch to a >=2.6.12 kernel and compile the kernel module"
94 - eerror
95 - fi
96 -}
97 +CONFIG_CHECK="~TCG_TPM"
98
99 src_prepare() {
100 default