1 |
commit: 0c57f77f684053bbc14049127f8c537874ad61c1 |
2 |
Author: Stefan Strogin <stefan.strogin <AT> gmail <DOT> com> |
3 |
AuthorDate: Sat Feb 16 03:38:17 2019 +0000 |
4 |
Commit: Aaron Bauman <bman <AT> gentoo <DOT> org> |
5 |
CommitDate: Sat Feb 16 17:59:30 2019 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=0c57f77f |
7 |
|
8 |
net-misc/spice-gtk: fix build for >=libressl-2.7.0 |
9 |
|
10 |
NB: spice-gtk-0.34-libressl.patch was not used anywhere. |
11 |
|
12 |
Closes: https://bugs.gentoo.org/664512 |
13 |
Package-Manager: Portage-2.3.60, Repoman-2.3.12 |
14 |
Signed-off-by: Stefan Strogin <stefan.strogin <AT> gmail.com> |
15 |
Closes: https://github.com/gentoo/gentoo/pull/11062 |
16 |
Signed-off-by: Aaron Bauman <bman <AT> gentoo.org> |
17 |
|
18 |
...ibressl.patch => spice-gtk-0.35-libressl.patch} | 25 ++-- |
19 |
net-misc/spice-gtk/spice-gtk-0.35-r1.ebuild | 154 +++++++++++++++++++++ |
20 |
2 files changed, 170 insertions(+), 9 deletions(-) |
21 |
|
22 |
diff --git a/net-misc/spice-gtk/files/spice-gtk-0.34-libressl.patch b/net-misc/spice-gtk/files/spice-gtk-0.35-libressl.patch |
23 |
similarity index 54% |
24 |
rename from net-misc/spice-gtk/files/spice-gtk-0.34-libressl.patch |
25 |
rename to net-misc/spice-gtk/files/spice-gtk-0.35-libressl.patch |
26 |
index e39efaee274..6ecea6d11c2 100644 |
27 |
--- a/net-misc/spice-gtk/files/spice-gtk-0.34-libressl.patch |
28 |
+++ b/net-misc/spice-gtk/files/spice-gtk-0.35-libressl.patch |
29 |
@@ -1,16 +1,21 @@ |
30 |
https://bugs.gentoo.org/631250 |
31 |
https://631250.bugs.gentoo.org/attachment.cgi?id=513720 |
32 |
|
33 |
+https://bugs.gentoo.org/664512 |
34 |
+https://cgit.freedesktop.org/spice/spice-common/commit/?id=8e8476d932d9866d950fe616fe1c10361b75a3a2 |
35 |
+https://cgit.freedesktop.org/spice/spice-gtk/commit/?id=a45e8a56e389e41c891eaa204b16dd89e74e2e69 |
36 |
+ |
37 |
diff --git a/spice-common/common/ssl_verify.c b/spice-common/common/ssl_verify.c |
38 |
index a9ed650..821faa9 100644 |
39 |
--- a/spice-common/common/ssl_verify.c |
40 |
+++ b/spice-common/common/ssl_verify.c |
41 |
-@@ -33,7 +33,7 @@ |
42 |
+@@ -33,7 +33,8 @@ |
43 |
#include <string.h> |
44 |
#include <gio/gio.h> |
45 |
|
46 |
--#if OPENSSL_VERSION_NUMBER < 0x10100000 |
47 |
-+#if OPENSSL_VERSION_NUMBER < 0x10100000 || defined(LIBRESSL_VERSION_NUMBER) |
48 |
+-#if OPENSSL_VERSION_NUMBER < 0x10100000 || defined (LIBRESSL_VERSION_NUMBER) |
49 |
++#if OPENSSL_VERSION_NUMBER < 0x10100000 || \ |
50 |
++ (defined (LIBRESSL_VERSION_NUMBER) && LIBRESSL_VERSION_NUMBER < 0x20700000) |
51 |
static const unsigned char *ASN1_STRING_get0_data(const ASN1_STRING *asn1) |
52 |
{ |
53 |
return M_ASN1_STRING_data(asn1); |
54 |
@@ -18,12 +23,13 @@ diff --git a/src/bio-gio.c b/src/bio-gio.c |
55 |
index 9358fae..30aa73b 100644 |
56 |
--- a/src/bio-gio.c |
57 |
+++ b/src/bio-gio.c |
58 |
-@@ -23,7 +23,7 @@ |
59 |
+@@ -23,7 +23,8 @@ |
60 |
#include "spice-util.h" |
61 |
#include "bio-gio.h" |
62 |
|
63 |
--#if OPENSSL_VERSION_NUMBER < 0x10100000 |
64 |
-+#if OPENSSL_VERSION_NUMBER < 0x10100000 || defined(LIBRESSL_VERSION_NUMBER) |
65 |
+-#if OPENSSL_VERSION_NUMBER < 0x10100000 || defined(LIBRESSL_VERSION_NUMBER) |
66 |
++#if OPENSSL_VERSION_NUMBER < 0x10100000 || \ |
67 |
++ (defined(LIBRESSL_VERSION_NUMBER) && LIBRESSL_VERSION_NUMBER < 0x20700000) |
68 |
static BIO_METHOD one_static_bio; |
69 |
|
70 |
static int BIO_meth_set_read(BIO_METHOD *biom, |
71 |
@@ -31,12 +37,13 @@ diff --git a/src/spice-channel.c b/src/spice-channel.c |
72 |
index 4c3db9d..9df0203 100644 |
73 |
--- a/src/spice-channel.c |
74 |
+++ b/src/spice-channel.c |
75 |
-@@ -55,7 +55,7 @@ static void spice_channel_reset_capabilities(SpiceChannel *channel); |
76 |
+@@ -55,7 +55,8 @@ static void spice_channel_reset_capabilities(SpiceChannel *channel); |
77 |
static void spice_channel_send_migration_handshake(SpiceChannel *channel); |
78 |
static gboolean channel_connect(SpiceChannel *channel, gboolean tls); |
79 |
|
80 |
--#if OPENSSL_VERSION_NUMBER < 0x10100000 |
81 |
-+#if OPENSSL_VERSION_NUMBER < 0x10100000 || defined(LIBRESSL_VERSION_NUMBER) |
82 |
+-#if OPENSSL_VERSION_NUMBER < 0x10100000 || defined(LIBRESSL_VERSION_NUMBER) |
83 |
++#if OPENSSL_VERSION_NUMBER < 0x10100000 || \ |
84 |
++ (defined(LIBRESSL_VERSION_NUMBER) && LIBRESSL_VERSION_NUMBER < 0x20700000) |
85 |
static RSA *EVP_PKEY_get0_RSA(EVP_PKEY *pkey) |
86 |
{ |
87 |
if (pkey->type != EVP_PKEY_RSA) { |
88 |
|
89 |
diff --git a/net-misc/spice-gtk/spice-gtk-0.35-r1.ebuild b/net-misc/spice-gtk/spice-gtk-0.35-r1.ebuild |
90 |
new file mode 100644 |
91 |
index 00000000000..c72b4911bbd |
92 |
--- /dev/null |
93 |
+++ b/net-misc/spice-gtk/spice-gtk-0.35-r1.ebuild |
94 |
@@ -0,0 +1,154 @@ |
95 |
+# Copyright 1999-2019 Gentoo Authors |
96 |
+# Distributed under the terms of the GNU General Public License v2 |
97 |
+ |
98 |
+EAPI=6 |
99 |
+ |
100 |
+GCONF_DEBUG="no" |
101 |
+VALA_MIN_API_VERSION="0.14" |
102 |
+VALA_USE_DEPEND="vapigen" |
103 |
+ |
104 |
+inherit autotools eutils xdg-utils vala readme.gentoo-r1 |
105 |
+ |
106 |
+DESCRIPTION="Set of GObject and Gtk objects for connecting to Spice servers and a client GUI" |
107 |
+HOMEPAGE="https://www.spice-space.org https://cgit.freedesktop.org/spice/spice-gtk/" |
108 |
+ |
109 |
+LICENSE="LGPL-2.1" |
110 |
+SLOT="0" |
111 |
+SRC_URI="https://www.spice-space.org/download/gtk/${P}.tar.bz2" |
112 |
+KEYWORDS="~alpha ~amd64 ~arm ~ia64 ~ppc ~ppc64 ~sparc ~x86" |
113 |
+IUSE="dbus gstaudio gstvideo +gtk3 +introspection lz4 mjpeg policykit pulseaudio sasl smartcard static-libs usbredir vala webdav libressl" |
114 |
+ |
115 |
+REQUIRED_USE="?? ( pulseaudio gstaudio )" |
116 |
+ |
117 |
+# TODO: |
118 |
+# * check if sys-freebsd/freebsd-lib (from virtual/acl) provides acl/libacl.h |
119 |
+# * use external pnp.ids as soon as that means not pulling in gnome-desktop |
120 |
+RDEPEND=" |
121 |
+ !libressl? ( dev-libs/openssl:0= ) |
122 |
+ libressl? ( dev-libs/libressl:0= ) |
123 |
+ pulseaudio? ( media-sound/pulseaudio[glib] ) |
124 |
+ gstvideo? ( |
125 |
+ media-libs/gstreamer:1.0 |
126 |
+ media-libs/gst-plugins-base:1.0 |
127 |
+ media-libs/gst-plugins-good:1.0 |
128 |
+ ) |
129 |
+ gstaudio? ( |
130 |
+ media-libs/gstreamer:1.0 |
131 |
+ media-libs/gst-plugins-base:1.0 |
132 |
+ media-libs/gst-plugins-good:1.0 |
133 |
+ ) |
134 |
+ >=x11-libs/pixman-0.17.7 |
135 |
+ media-libs/opus |
136 |
+ gtk3? ( x11-libs/gtk+:3[introspection?] ) |
137 |
+ >=dev-libs/glib-2.36:2 |
138 |
+ >=x11-libs/cairo-1.2 |
139 |
+ virtual/jpeg:0= |
140 |
+ sys-libs/zlib |
141 |
+ introspection? ( dev-libs/gobject-introspection ) |
142 |
+ lz4? ( app-arch/lz4 ) |
143 |
+ sasl? ( dev-libs/cyrus-sasl ) |
144 |
+ smartcard? ( app-emulation/qemu[smartcard] ) |
145 |
+ usbredir? ( |
146 |
+ sys-apps/hwids |
147 |
+ >=sys-apps/usbredir-0.4.2 |
148 |
+ virtual/libusb:1 |
149 |
+ virtual/libgudev:= |
150 |
+ policykit? ( |
151 |
+ sys-apps/acl |
152 |
+ >=sys-auth/polkit-0.110-r1 |
153 |
+ !~sys-auth/polkit-0.111 ) |
154 |
+ ) |
155 |
+ webdav? ( |
156 |
+ net-libs/phodav:2.0 |
157 |
+ >=dev-libs/glib-2.43.90:2 |
158 |
+ >=net-libs/libsoup-2.49.91 ) |
159 |
+" |
160 |
+DEPEND="${RDEPEND} |
161 |
+ >=app-emulation/spice-protocol-0.12.14 |
162 |
+ dev-perl/Text-CSV |
163 |
+ >=dev-util/gtk-doc-am-1.14 |
164 |
+ >=dev-util/intltool-0.40.0 |
165 |
+ >=sys-devel/gettext-0.17 |
166 |
+ virtual/pkgconfig |
167 |
+ vala? ( $(vala_depend) ) |
168 |
+" |
169 |
+ |
170 |
+PATCHES=( |
171 |
+ "${FILESDIR}"/${PN}-0.34-openssl11.patch |
172 |
+ "${FILESDIR}"/${P}-libressl.patch |
173 |
+) |
174 |
+ |
175 |
+src_prepare() { |
176 |
+ # bug 558558 |
177 |
+ export GIT_CEILING_DIRECTORIES="${WORKDIR}" |
178 |
+ echo GIT_CEILING_DIRECTORIES=${GIT_CEILING_DIRECTORIES} |
179 |
+ |
180 |
+ default |
181 |
+ |
182 |
+ eautoreconf |
183 |
+ |
184 |
+ use vala && vala_src_prepare |
185 |
+} |
186 |
+ |
187 |
+src_configure() { |
188 |
+ # Prevent sandbox violations, bug #581836 |
189 |
+ # https://bugzilla.gnome.org/show_bug.cgi?id=744134 |
190 |
+ # https://bugzilla.gnome.org/show_bug.cgi?id=744135 |
191 |
+ addpredict /dev |
192 |
+ |
193 |
+ # Clean up environment, bug #586642 |
194 |
+ xdg_environment_reset |
195 |
+ |
196 |
+ local myconf |
197 |
+ |
198 |
+ if use vala ; then |
199 |
+ # force vala regen for MinGW, etc |
200 |
+ rm -fv gtk/controller/controller.{c,vala.stamp} gtk/controller/menu.c |
201 |
+ fi |
202 |
+ |
203 |
+ myconf=" |
204 |
+ $(use_enable static-libs static) |
205 |
+ $(use_enable introspection) |
206 |
+ $(use_with sasl) |
207 |
+ $(use_enable smartcard) |
208 |
+ $(use_enable usbredir) |
209 |
+ $(use_with usbredir usb-ids-path /usr/share/misc/usb.ids) |
210 |
+ $(use_with usbredir usb-acl-helper-dir /usr/libexec) |
211 |
+ $(use_with gtk3 gtk 3.0) |
212 |
+ $(use_enable policykit polkit) |
213 |
+ $(use_enable pulseaudio pulse) |
214 |
+ $(use_enable gstaudio) |
215 |
+ $(use_enable gstvideo) |
216 |
+ $(use_enable mjpeg builtin-mjpeg) |
217 |
+ $(use_enable vala) |
218 |
+ $(use_enable webdav) |
219 |
+ $(use_enable dbus) |
220 |
+ --disable-celt051 |
221 |
+ --disable-gtk-doc |
222 |
+ --disable-maintainer-mode |
223 |
+ --disable-werror |
224 |
+ --enable-pie" |
225 |
+ |
226 |
+ econf ${myconf} |
227 |
+} |
228 |
+ |
229 |
+src_compile() { |
230 |
+ # Prevent sandbox violations, bug #581836 |
231 |
+ # https://bugzilla.gnome.org/show_bug.cgi?id=744134 |
232 |
+ # https://bugzilla.gnome.org/show_bug.cgi?id=744135 |
233 |
+ addpredict /dev |
234 |
+ |
235 |
+ default |
236 |
+} |
237 |
+ |
238 |
+src_install() { |
239 |
+ default |
240 |
+ |
241 |
+ dodoc AUTHORS ChangeLog NEWS README THANKS TODO |
242 |
+ |
243 |
+ # Remove .la files if they're not needed |
244 |
+ use static-libs || prune_libtool_files |
245 |
+ |
246 |
+ make_desktop_entry spicy Spicy "utilities-terminal" "Network;RemoteAccess;" |
247 |
+ readme.gentoo_create_doc |
248 |
+} |