1 |
commit: 1e4e3d89728cc93439b3c72872779f9a88a661bb |
2 |
Author: Matt Turner <mattst88 <AT> gentoo <DOT> org> |
3 |
AuthorDate: Fri Jan 8 04:20:12 2021 +0000 |
4 |
Commit: Matt Turner <mattst88 <AT> gentoo <DOT> org> |
5 |
CommitDate: Fri Jan 8 16:23:53 2021 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=1e4e3d89 |
7 |
|
8 |
app-crypt/gcr: Version bump to 3.38.0 |
9 |
|
10 |
Closes: https://bugs.gentoo.org/751346 |
11 |
Closes: https://bugs.gentoo.org/762799 |
12 |
Signed-off-by: Matt Turner <mattst88 <AT> gentoo.org> |
13 |
|
14 |
app-crypt/gcr/Manifest | 1 + |
15 |
.../files/3.38.0-avoid-gnupg-circular-dep.patch | 52 +++++++++++++ |
16 |
app-crypt/gcr/files/3.38.0-optional-vapi.patch | 88 ++++++++++++++++++++++ |
17 |
app-crypt/gcr/gcr-3.38.0.ebuild | 84 +++++++++++++++++++++ |
18 |
4 files changed, 225 insertions(+) |
19 |
|
20 |
diff --git a/app-crypt/gcr/Manifest b/app-crypt/gcr/Manifest |
21 |
index 593256ddcdf..1776e37e762 100644 |
22 |
--- a/app-crypt/gcr/Manifest |
23 |
+++ b/app-crypt/gcr/Manifest |
24 |
@@ -1 +1,2 @@ |
25 |
DIST gcr-3.36.0.tar.xz 1025760 BLAKE2B 03f0d0ed40b600ed80e894111fedff3efcbbaaf6f261d6a44a3649a1acb50c4f35f3dc9a7ddb60f56cab241f68fef83aa5a02a94036e70a6556b35300f2c8fb5 SHA512 0431e7971b73accc62869c9497fcff7c111c453aa6a8ff25b42f19ceae1be0aec52e0e4eb504676f967c6e4f179198c15c521278690822e3457dbc5fe512fd5e |
26 |
+DIST gcr-3.38.0.tar.xz 1029784 BLAKE2B cf295a9f497d6c54067717e806439166965f90670ed5f7283802bb70c547465d9cc28d452970269d4315d02d24cc31f483a0a1fc1807f9b9720e70aa2b8249b9 SHA512 24c35ac514a67a1dee6a5738e829b55921a490b060ffa597421cea0abac3ddc62695370d2c7b3504c0adfd55b1ade878ad3ca5e6cb869428b4a19f4a11563bc6 |
27 |
|
28 |
diff --git a/app-crypt/gcr/files/3.38.0-avoid-gnupg-circular-dep.patch b/app-crypt/gcr/files/3.38.0-avoid-gnupg-circular-dep.patch |
29 |
new file mode 100644 |
30 |
index 00000000000..5bb7da0fa78 |
31 |
--- /dev/null |
32 |
+++ b/app-crypt/gcr/files/3.38.0-avoid-gnupg-circular-dep.patch |
33 |
@@ -0,0 +1,52 @@ |
34 |
+From b938b0b658852c682ae17d56e0ad9322611e9516 Mon Sep 17 00:00:00 2001 |
35 |
+From: Rasmus Thomsen <oss@×××××××.dev> |
36 |
+Date: Wed, 11 Mar 2020 11:49:08 +0100 |
37 |
+Subject: [PATCH 1/2] meson: allow building without gpg(2) installed |
38 |
+ |
39 |
+This avoids circular dependencies, such as gcr -> gpg2 -> pinentry -> gcr |
40 |
+--- |
41 |
+ meson.build | 7 +++++-- |
42 |
+ meson_options.txt | 5 +++++ |
43 |
+ 2 files changed, 10 insertions(+), 2 deletions(-) |
44 |
+ |
45 |
+diff --git a/meson.build b/meson.build |
46 |
+index a26a0f9..02b4c3c 100644 |
47 |
+--- a/meson.build |
48 |
++++ b/meson.build |
49 |
+@@ -41,7 +41,10 @@ gobject_dep = dependency('gobject-2.0', version: '>=' + min_glib_version) |
50 |
+ gio_dep = dependency('gio-2.0', version: '>=' + min_glib_version) |
51 |
+ gio_unix_dep = dependency('gio-unix-2.0',version: '>=' + min_glib_version) |
52 |
+ glib_deps = [ glib_dep, gmodule_dep, gthread_dep, gobject_dep, gio_dep, gio_unix_dep, ] |
53 |
+-gpg_bin = find_program('gpg2', 'gpg') |
54 |
++gpg_path = get_option('gpg_path') |
55 |
++if gpg_path == '' |
56 |
++ gpg_path = find_program('gpg2', 'gpg').path() |
57 |
++endif |
58 |
+ libgcrypt_dep = dependency('libgcrypt', version: '>= 1') |
59 |
+ p11kit_dep = dependency('p11-kit-1', version: '>= 0.19.0') |
60 |
+ p11_system_config_modules = p11kit_dep.get_pkgconfig_variable('p11_system_config_modules') |
61 |
+@@ -65,7 +68,7 @@ conf.set('HAVE_GETTEXT', true) |
62 |
+ conf.set('HAVE_LOCALE_H', cc.has_header('locale.h')) |
63 |
+ conf.set('HAVE_TIMEGM', cc.has_function('timegm')) |
64 |
+ conf.set('HAVE_MLOCK', cc.has_function('mlock')) |
65 |
+-conf.set_quoted('GPG_EXECUTABLE', gpg_bin.path()) |
66 |
++conf.set_quoted('GPG_EXECUTABLE', gpg_path) |
67 |
+ conf.set_quoted('LIBGCRYPT_VERSION', libgcrypt_dep.version()) |
68 |
+ config_file = configure_file( |
69 |
+ output: 'config.h', |
70 |
+diff --git a/meson_options.txt b/meson_options.txt |
71 |
+index bbdc8e3..ae0f524 100644 |
72 |
+--- a/meson_options.txt |
73 |
++++ b/meson_options.txt |
74 |
+@@ -13,3 +13,8 @@ option('gtk_doc', |
75 |
+ value: true, |
76 |
+ description: 'Build the reference documentation (requires gtk-doc)', |
77 |
+ ) |
78 |
++option('gpg_path', |
79 |
++ type: 'string', |
80 |
++ value: '', |
81 |
++ description: 'Path to gpg, autodetected if not set', |
82 |
++) |
83 |
+-- |
84 |
+2.26.2 |
85 |
+ |
86 |
|
87 |
diff --git a/app-crypt/gcr/files/3.38.0-optional-vapi.patch b/app-crypt/gcr/files/3.38.0-optional-vapi.patch |
88 |
new file mode 100644 |
89 |
index 00000000000..d565884994f |
90 |
--- /dev/null |
91 |
+++ b/app-crypt/gcr/files/3.38.0-optional-vapi.patch |
92 |
@@ -0,0 +1,88 @@ |
93 |
+From 6d61774b8556eb4acfa5e7613ee25893d2a7e565 Mon Sep 17 00:00:00 2001 |
94 |
+From: Mart Raudsepp <leio@g.o> |
95 |
+Date: Tue, 18 Aug 2020 09:36:19 +0300 |
96 |
+Subject: [PATCH 2/2] build: Make vapi optional |
97 |
+ |
98 |
+--- |
99 |
+ gck/meson.build | 2 ++ |
100 |
+ gcr/meson.build | 2 ++ |
101 |
+ meson_options.txt | 5 +++++ |
102 |
+ ui/meson.build | 2 ++ |
103 |
+ 4 files changed, 11 insertions(+) |
104 |
+ |
105 |
+diff --git a/gck/meson.build b/gck/meson.build |
106 |
+index 756b486..a15f4ed 100644 |
107 |
+--- a/gck/meson.build |
108 |
++++ b/gck/meson.build |
109 |
+@@ -142,6 +142,7 @@ if get_option('introspection') |
110 |
+ install: true, |
111 |
+ ) |
112 |
+ |
113 |
++if get_option('vapi') |
114 |
+ gck_vapi = gnome.generate_vapi('gck-@0@'.format(gck_major_version), |
115 |
+ sources: gck_gir[0], |
116 |
+ metadata_dirs: meson.current_source_dir(), |
117 |
+@@ -153,6 +154,7 @@ if get_option('introspection') |
118 |
+ install_dir: get_option('datadir') / 'vala' / 'vapi', |
119 |
+ ) |
120 |
+ endif |
121 |
++endif |
122 |
+ |
123 |
+ # pkg-config file |
124 |
+ pkgconfig.generate(gck_lib, |
125 |
+diff --git a/gcr/meson.build b/gcr/meson.build |
126 |
+index 06c3a63..cc642cf 100644 |
127 |
+--- a/gcr/meson.build |
128 |
++++ b/gcr/meson.build |
129 |
+@@ -204,6 +204,7 @@ if get_option('introspection') |
130 |
+ install: true, |
131 |
+ ) |
132 |
+ |
133 |
++if get_option('vapi') |
134 |
+ gcr_vapi = gnome.generate_vapi('gcr-@0@'.format(gcr_major_version), |
135 |
+ sources: gcr_gir[0], |
136 |
+ packages: [ 'glib-2.0', 'gio-2.0', gck_vapi ], |
137 |
+@@ -217,6 +218,7 @@ if get_option('introspection') |
138 |
+ install: true, |
139 |
+ ) |
140 |
+ endif |
141 |
++endif |
142 |
+ |
143 |
+ # pkg-config file |
144 |
+ pkgconfig.generate(gcr_base_lib, |
145 |
+diff --git a/meson_options.txt b/meson_options.txt |
146 |
+index ae0f524..f68cb95 100644 |
147 |
+--- a/meson_options.txt |
148 |
++++ b/meson_options.txt |
149 |
+@@ -18,3 +18,8 @@ option('gpg_path', |
150 |
+ value: '', |
151 |
+ description: 'Path to gpg, autodetected if not set', |
152 |
+ ) |
153 |
++option('vapi', |
154 |
++ type: 'boolean', |
155 |
++ value: true, |
156 |
++ description: 'Generate vapi data (requires vapigen and introspection option)', |
157 |
++) |
158 |
+diff --git a/ui/meson.build b/ui/meson.build |
159 |
+index 477412d..0b89b24 100644 |
160 |
+--- a/ui/meson.build |
161 |
++++ b/ui/meson.build |
162 |
+@@ -169,6 +169,7 @@ if get_option('introspection') |
163 |
+ install: true, |
164 |
+ ) |
165 |
+ |
166 |
++if get_option('vapi') |
167 |
+ gcr_ui_vapi = gnome.generate_vapi('gcr-ui-@0@'.format(gcr_major_version), |
168 |
+ sources: gcr_ui_gir[0], |
169 |
+ packages: [ |
170 |
+@@ -190,6 +191,7 @@ if get_option('introspection') |
171 |
+ install: true, |
172 |
+ ) |
173 |
+ endif |
174 |
++endif |
175 |
+ |
176 |
+ # gcr-viewer |
177 |
+ gcr_viewer = executable('gcr-viewer', |
178 |
+-- |
179 |
+2.26.2 |
180 |
+ |
181 |
|
182 |
diff --git a/app-crypt/gcr/gcr-3.38.0.ebuild b/app-crypt/gcr/gcr-3.38.0.ebuild |
183 |
new file mode 100644 |
184 |
index 00000000000..1328f530c41 |
185 |
--- /dev/null |
186 |
+++ b/app-crypt/gcr/gcr-3.38.0.ebuild |
187 |
@@ -0,0 +1,84 @@ |
188 |
+# Copyright 1999-2021 Gentoo Authors |
189 |
+# Distributed under the terms of the GNU General Public License v2 |
190 |
+ |
191 |
+EAPI=7 |
192 |
+VALA_USE_DEPEND="vapigen" |
193 |
+PYTHON_COMPAT=( python3_{6..9} ) |
194 |
+ |
195 |
+inherit gnome.org gnome2-utils meson python-any-r1 vala xdg |
196 |
+ |
197 |
+DESCRIPTION="Libraries for cryptographic UIs and accessing PKCS#11 modules" |
198 |
+HOMEPAGE="https://gitlab.gnome.org/GNOME/gcr" |
199 |
+ |
200 |
+LICENSE="GPL-2+ LGPL-2+" |
201 |
+SLOT="0/1" # subslot = suffix of libgcr-base-3 and co |
202 |
+ |
203 |
+IUSE="gtk gtk-doc +introspection test +vala" |
204 |
+REQUIRED_USE="vala? ( introspection )" |
205 |
+RESTRICT="!test? ( test )" |
206 |
+ |
207 |
+KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~mips ~ppc ~ppc64 ~sparc ~x86 ~amd64-linux ~x86-linux ~sparc-solaris ~x86-solaris" |
208 |
+ |
209 |
+DEPEND=" |
210 |
+ >=dev-libs/glib-2.44.0:2 |
211 |
+ >=dev-libs/libgcrypt-1.2.2:0= |
212 |
+ >=app-crypt/p11-kit-0.19.0 |
213 |
+ gtk? ( >=x11-libs/gtk+-3.12:3[X,introspection?] ) |
214 |
+ >=sys-apps/dbus-1 |
215 |
+ introspection? ( >=dev-libs/gobject-introspection-1.58:= ) |
216 |
+" |
217 |
+RDEPEND="${DEPEND}" |
218 |
+PDEPEND="app-crypt/gnupg" |
219 |
+BDEPEND=" |
220 |
+ ${PYTHON_DEPS} |
221 |
+ gtk? ( dev-libs/libxml2:2 ) |
222 |
+ dev-util/gdbus-codegen |
223 |
+ dev-util/glib-utils |
224 |
+ gtk-doc? ( |
225 |
+ >=dev-util/gtk-doc-1.9 |
226 |
+ app-text/docbook-xml-dtd:4.1.2 |
227 |
+ ) |
228 |
+ >=sys-devel/gettext-0.19.8 |
229 |
+ test? ( app-crypt/gnupg ) |
230 |
+ virtual/pkgconfig |
231 |
+ vala? ( $(vala_depend) ) |
232 |
+" |
233 |
+ |
234 |
+PATCHES=( |
235 |
+ "${FILESDIR}"/${PV}-avoid-gnupg-circular-dep.patch |
236 |
+ "${FILESDIR}"/${PV}-optional-vapi.patch |
237 |
+) |
238 |
+ |
239 |
+pkg_setup() { |
240 |
+ python-any-r1_pkg_setup |
241 |
+} |
242 |
+ |
243 |
+src_prepare() { |
244 |
+ use vala && vala_src_prepare |
245 |
+ xdg_src_prepare |
246 |
+} |
247 |
+ |
248 |
+src_configure() { |
249 |
+ local emesonargs=( |
250 |
+ $(meson_use introspection) |
251 |
+ $(meson_use gtk) |
252 |
+ $(meson_use gtk-doc gtk_doc) |
253 |
+ -Dgpg_path="${EPREFIX}"/usr/bin/gpg |
254 |
+ $(meson_use vala vapi) |
255 |
+ ) |
256 |
+ meson_src_configure |
257 |
+} |
258 |
+ |
259 |
+src_test() { |
260 |
+ dbus-run-session meson test -C "${BUILD_DIR}" || die 'tests failed' |
261 |
+} |
262 |
+ |
263 |
+pkg_postinst() { |
264 |
+ xdg_pkg_postinst |
265 |
+ gnome2_schemas_update |
266 |
+} |
267 |
+ |
268 |
+pkg_postrm() { |
269 |
+ xdg_pkg_postrm |
270 |
+ gnome2_schemas_update |
271 |
+} |