1 |
commit: 022ca5838e9da166a42cb5db0bfa590c66d953a0 |
2 |
Author: Sam James <sam <AT> gentoo <DOT> org> |
3 |
AuthorDate: Tue Oct 12 18:47:39 2021 +0000 |
4 |
Commit: Sam James <sam <AT> gentoo <DOT> org> |
5 |
CommitDate: Tue Oct 12 18:47:45 2021 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=022ca583 |
7 |
|
8 |
app-crypt/gnupg: add 2.3.3 |
9 |
|
10 |
Enable tofu by default given tests need it |
11 |
and Python needs sqlite by default now too. |
12 |
|
13 |
Bug: https://bugs.gentoo.org/790248 |
14 |
Signed-off-by: Sam James <sam <AT> gentoo.org> |
15 |
|
16 |
app-crypt/gnupg/Manifest | 1 + |
17 |
app-crypt/gnupg/gnupg-2.3.3.ebuild | 155 +++++++++++++++++++++++++++++++++++++ |
18 |
2 files changed, 156 insertions(+) |
19 |
|
20 |
diff --git a/app-crypt/gnupg/Manifest b/app-crypt/gnupg/Manifest |
21 |
index 2f084ca106b..c1e439ec9c6 100644 |
22 |
--- a/app-crypt/gnupg/Manifest |
23 |
+++ b/app-crypt/gnupg/Manifest |
24 |
@@ -4,3 +4,4 @@ DIST gnupg-2.2.29.tar.bz2 7215986 BLAKE2B 04b777730b8fcbe8d93dfc8985aadd6bc7385a |
25 |
DIST gnupg-2.2.31.tar.bz2 7212188 BLAKE2B 57a2b6c6ea491137a708e18a0119502621b7bdf0591818d19beb8b08a521a7dbf60472243e1723f53acbfb9a5de612b8e5040c45dc847bdda26012244edb11be SHA512 2f6fa200e08d6b8993b482e5825bea6083afc8686c4e1ae80386b36ae49e1c2d73066c508edaa359a7794cb26ba7a00f81555a906fa422d1117e41415cfa2fea |
26 |
DIST gnupg-2.2.32.tar.bz2 7212625 BLAKE2B 8e1feba83a0d8fa1c154c814e26b41aa252cef4af53937e4e8954860249c180c1d6910356b0c46dfefde094846b02bd5375f17c8b6fdcc9138281d0daa292d42 SHA512 76b75d3688561ce65a8014812656aa87c9722c898d7e186fdb1331dee6af32f886a6b0a4806975c348a22ad6dda60f956ece56076d00153b9706aad4c934c6a1 |
27 |
DIST gnupg-2.3.2.tar.bz2 7589445 BLAKE2B f7e35ed553ea89cdb073abb1432f67fa00bb625f6e686e534f96bca11d88f09ea272b3cb0d6706e4bce2c023f8c5b8d628742aa2f60752a2e605132cd32f62ed SHA512 2747cbe38546f500d165f024ebb2dc5be70fa68d20702af3f61e97db685eba94caf65307293137c76ea6cfcc189ed24aaee025c80cd33f26609e5fe512bdda73 |
28 |
+DIST gnupg-2.3.3.tar.bz2 7590874 BLAKE2B a80a84b4f6691815550de6125f4f24aa9c901b8ca8eeb6bc91c90ccd3d285a5ddb15688c7ab870aa6a6c418eb98b969e7b958120c3976b5aaea55188f39b67b0 SHA512 12d500e6b45910d5f7bfd4916bcee37ac988a58a35563fcf425a65b88c0cf92c2af2e94d3e31e9e5e19094c8beb5ec3779cf90bfe43d1555c4196f69eee2f102 |
29 |
|
30 |
diff --git a/app-crypt/gnupg/gnupg-2.3.3.ebuild b/app-crypt/gnupg/gnupg-2.3.3.ebuild |
31 |
new file mode 100644 |
32 |
index 00000000000..b32b781d0fd |
33 |
--- /dev/null |
34 |
+++ b/app-crypt/gnupg/gnupg-2.3.3.ebuild |
35 |
@@ -0,0 +1,155 @@ |
36 |
+# Copyright 1999-2021 Gentoo Authors |
37 |
+# Distributed under the terms of the GNU General Public License v2 |
38 |
+ |
39 |
+EAPI=7 |
40 |
+ |
41 |
+inherit flag-o-matic systemd toolchain-funcs |
42 |
+ |
43 |
+MY_P="${P/_/-}" |
44 |
+ |
45 |
+DESCRIPTION="The GNU Privacy Guard, a GPL OpenPGP implementation" |
46 |
+HOMEPAGE="https://gnupg.org/" |
47 |
+SRC_URI="mirror://gnupg/gnupg/${MY_P}.tar.bz2" |
48 |
+S="${WORKDIR}/${MY_P}" |
49 |
+ |
50 |
+LICENSE="GPL-3" |
51 |
+SLOT="0" |
52 |
+KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~x64-cygwin ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris" |
53 |
+IUSE="bzip2 doc ldap nls readline selinux +smartcard ssl test +tofu tools usb user-socket wks-server" |
54 |
+RESTRICT="!test? ( test )" |
55 |
+REQUIRED_USE="test? ( tofu )" |
56 |
+ |
57 |
+# Existence of executables is checked during configuration. |
58 |
+DEPEND=">=dev-libs/libassuan-2.5.0 |
59 |
+ >=dev-libs/libgcrypt-1.9.1:= |
60 |
+ >=dev-libs/libgpg-error-1.29 |
61 |
+ >=dev-libs/libksba-1.3.4 |
62 |
+ >=dev-libs/npth-1.2 |
63 |
+ >=net-misc/curl-7.10 |
64 |
+ bzip2? ( app-arch/bzip2 ) |
65 |
+ ldap? ( net-nds/openldap ) |
66 |
+ readline? ( sys-libs/readline:0= ) |
67 |
+ smartcard? ( usb? ( virtual/libusb:1 ) ) |
68 |
+ tofu? ( >=dev-db/sqlite-3.27 ) |
69 |
+ ssl? ( >=net-libs/gnutls-3.0:0= ) |
70 |
+ sys-libs/zlib |
71 |
+" |
72 |
+ |
73 |
+RDEPEND="${DEPEND} |
74 |
+ app-crypt/pinentry |
75 |
+ nls? ( virtual/libintl ) |
76 |
+ selinux? ( sec-policy/selinux-gpg ) |
77 |
+ wks-server? ( virtual/mta )" |
78 |
+ |
79 |
+BDEPEND="virtual/pkgconfig |
80 |
+ doc? ( sys-apps/texinfo ) |
81 |
+ nls? ( sys-devel/gettext )" |
82 |
+ |
83 |
+DOCS=( |
84 |
+ ChangeLog NEWS README THANKS TODO VERSION |
85 |
+ doc/FAQ doc/DETAILS doc/HACKING doc/TRANSLATE doc/OpenPGP doc/KEYSERVER |
86 |
+) |
87 |
+ |
88 |
+PATCHES=( |
89 |
+ "${FILESDIR}/${PN}-2.1.20-gpgscm-Use-shorter-socket-path-lengts-to-improve-tes.patch" |
90 |
+) |
91 |
+ |
92 |
+src_prepare() { |
93 |
+ default |
94 |
+ |
95 |
+ # Inject SSH_AUTH_SOCK into user's sessions after enabling gpg-agent-ssh.socket in systemctl --user mode, |
96 |
+ # idea borrowed from libdbus, see |
97 |
+ # https://gitlab.freedesktop.org/dbus/dbus/-/blob/master/bus/systemd-user/dbus.socket.in#L6 |
98 |
+ # |
99 |
+ # This cannot be upstreamed, as it requires determining the exact prefix of 'systemctl', |
100 |
+ # which in turn requires discovery in Autoconf, something that upstream deeply resents. |
101 |
+ sed -e "/DirectoryMode=/a ExecStartPost=-${EPREFIX}/bin/systemctl --user set-environment SSH_AUTH_SOCK=%t/gnupg/S.gpg-agent.ssh" \ |
102 |
+ -i doc/examples/systemd-user/gpg-agent-ssh.socket || die |
103 |
+} |
104 |
+ |
105 |
+src_configure() { |
106 |
+ local myconf=( |
107 |
+ $(use_enable bzip2) |
108 |
+ $(use_enable nls) |
109 |
+ $(use_enable smartcard scdaemon) |
110 |
+ $(use_enable ssl gnutls) |
111 |
+ $(use_enable tofu) |
112 |
+ $(use_enable tofu keyboxd) |
113 |
+ $(use_enable tofu sqlite) |
114 |
+ $(use smartcard && use_enable usb ccid-driver || echo '--disable-ccid-driver') |
115 |
+ $(use_enable wks-server wks-tools) |
116 |
+ $(use_with ldap) |
117 |
+ $(use_with readline) |
118 |
+ --with-mailprog=/usr/libexec/sendmail |
119 |
+ --disable-ntbtls |
120 |
+ --enable-all-tests |
121 |
+ --enable-gpgsm |
122 |
+ --enable-large-secmem |
123 |
+ CC_FOR_BUILD="$(tc-getBUILD_CC)" |
124 |
+ GPG_ERROR_CONFIG="${ESYSROOT}/usr/bin/${CHOST}-gpg-error-config" |
125 |
+ KSBA_CONFIG="${ESYSROOT}/usr/bin/ksba-config" |
126 |
+ LIBASSUAN_CONFIG="${ESYSROOT}/usr/bin/libassuan-config" |
127 |
+ LIBGCRYPT_CONFIG="${ESYSROOT}/usr/bin/${CHOST}-libgcrypt-config" |
128 |
+ NPTH_CONFIG="${ESYSROOT}/usr/bin/npth-config" |
129 |
+ $("${S}/configure" --help | grep -o -- '--without-.*-prefix') |
130 |
+ ) |
131 |
+ |
132 |
+ if use prefix && use usb; then |
133 |
+ # bug #649598 |
134 |
+ append-cppflags -I"${EPREFIX}/usr/include/libusb-1.0" |
135 |
+ fi |
136 |
+ |
137 |
+ #bug 663142 |
138 |
+ if use user-socket; then |
139 |
+ myconf+=( --enable-run-gnupg-user-socket ) |
140 |
+ fi |
141 |
+ |
142 |
+ # glib fails and picks up clang's internal stdint.h causing weird errors |
143 |
+ [[ ${CC} == *clang ]] && \ |
144 |
+ export gl_cv_absolute_stdint_h=/usr/include/stdint.h |
145 |
+ |
146 |
+ # Hardcode mailprog to /usr/libexec/sendmail even if it does not exist. |
147 |
+ # As of GnuPG 2.3, the mailprog substitution is used for the binary called |
148 |
+ # by wks-client & wks-server; and if it's autodetected but not not exist at |
149 |
+ # build time, then then 'gpg-wks-client --send' functionality will not |
150 |
+ # work. This has an unwanted side-effect in stage3 builds: there was a |
151 |
+ # [R]DEPEND on virtual/mta, which also brought in virtual/logger, bloating |
152 |
+ # the build where the install guide previously make the user chose the |
153 |
+ # logger & mta early in the install. |
154 |
+ |
155 |
+ econf "${myconf[@]}" |
156 |
+} |
157 |
+ |
158 |
+src_compile() { |
159 |
+ default |
160 |
+ |
161 |
+ use doc && emake -C doc html |
162 |
+} |
163 |
+ |
164 |
+src_test() { |
165 |
+ #Bug: 638574 |
166 |
+ use tofu && export TESTFLAGS=--parallel |
167 |
+ default |
168 |
+} |
169 |
+ |
170 |
+src_install() { |
171 |
+ default |
172 |
+ |
173 |
+ use tools && |
174 |
+ dobin \ |
175 |
+ tools/{convert-from-106,gpg-check-pattern} \ |
176 |
+ tools/{gpgconf,gpgsplit,lspgpot,mail-signed-keys} \ |
177 |
+ tools/make-dns-cert |
178 |
+ |
179 |
+ dosym gpg /usr/bin/gpg2 |
180 |
+ dosym gpgv /usr/bin/gpgv2 |
181 |
+ echo ".so man1/gpg.1" > "${ED}"/usr/share/man/man1/gpg2.1 || die |
182 |
+ echo ".so man1/gpgv.1" > "${ED}"/usr/share/man/man1/gpgv2.1 || die |
183 |
+ |
184 |
+ dodir /etc/env.d |
185 |
+ echo "CONFIG_PROTECT=/usr/share/gnupg/qualified.txt" >> "${ED}"/etc/env.d/30gnupg || die |
186 |
+ |
187 |
+ use doc && dodoc doc/gnupg.html/* doc/*.png |
188 |
+ |
189 |
+ systemd_douserunit doc/examples/systemd-user/*.{service,socket} |
190 |
+} |