1 |
commit: f58cf34d879bb0119b9b50458308dd7d6d086aa1 |
2 |
Author: Anthony G. Basile <blueness <AT> gentoo <DOT> org> |
3 |
AuthorDate: Sun Jan 31 14:44:59 2021 +0000 |
4 |
Commit: Anthony G. Basile <blueness <AT> gentoo <DOT> org> |
5 |
CommitDate: Sun Jan 31 14:44:59 2021 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=f58cf34d |
7 |
|
8 |
net-misc/curl: remove libressl |
9 |
|
10 |
Package-Manager: Portage-3.0.13, Repoman-3.0.2 |
11 |
Signed-off-by: Anthony G. Basile <blueness <AT> gentoo.org> |
12 |
|
13 |
net-misc/curl/curl-7.74.0-r4.ebuild | 285 ++++++++++++++++++++++++++++++++++++ |
14 |
1 file changed, 285 insertions(+) |
15 |
|
16 |
diff --git a/net-misc/curl/curl-7.74.0-r4.ebuild b/net-misc/curl/curl-7.74.0-r4.ebuild |
17 |
new file mode 100644 |
18 |
index 00000000000..c7d9410a7e0 |
19 |
--- /dev/null |
20 |
+++ b/net-misc/curl/curl-7.74.0-r4.ebuild |
21 |
@@ -0,0 +1,285 @@ |
22 |
+# Copyright 1999-2021 Gentoo Authors |
23 |
+# Distributed under the terms of the GNU General Public License v2 |
24 |
+ |
25 |
+EAPI="7" |
26 |
+ |
27 |
+inherit autotools eutils prefix multilib-minimal |
28 |
+ |
29 |
+DESCRIPTION="A Client that groks URLs" |
30 |
+HOMEPAGE="https://curl.haxx.se/" |
31 |
+SRC_URI="https://curl.haxx.se/download/${P}.tar.xz" |
32 |
+ |
33 |
+LICENSE="curl" |
34 |
+SLOT="0" |
35 |
+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" |
36 |
+IUSE="adns alt-svc brotli +ftp gnutls gopher hsts +http2 idn +imap ipv6 kerberos ldap mbedtls metalink nss +openssl +pop3 +progress-meter rtmp samba +smtp ssh ssl static-libs test telnet +tftp threads winssl zstd" |
37 |
+IUSE+=" curl_ssl_gnutls curl_ssl_mbedtls curl_ssl_nss +curl_ssl_openssl curl_ssl_winssl" |
38 |
+IUSE+=" nghttp3 quiche" |
39 |
+IUSE+=" elibc_Winnt" |
40 |
+ |
41 |
+#lead to lots of false negatives, bug #285669 |
42 |
+RESTRICT="!test? ( test )" |
43 |
+ |
44 |
+RDEPEND="ldap? ( net-nds/openldap[${MULTILIB_USEDEP}] ) |
45 |
+ brotli? ( app-arch/brotli:=[${MULTILIB_USEDEP}] ) |
46 |
+ ssl? ( |
47 |
+ gnutls? ( |
48 |
+ net-libs/gnutls:0=[static-libs?,${MULTILIB_USEDEP}] |
49 |
+ dev-libs/nettle:0=[${MULTILIB_USEDEP}] |
50 |
+ app-misc/ca-certificates |
51 |
+ ) |
52 |
+ mbedtls? ( |
53 |
+ net-libs/mbedtls:0=[${MULTILIB_USEDEP}] |
54 |
+ app-misc/ca-certificates |
55 |
+ ) |
56 |
+ openssl? ( |
57 |
+ dev-libs/openssl:0=[static-libs?,${MULTILIB_USEDEP}] |
58 |
+ ) |
59 |
+ nss? ( |
60 |
+ dev-libs/nss:0[${MULTILIB_USEDEP}] |
61 |
+ app-misc/ca-certificates |
62 |
+ ) |
63 |
+ ) |
64 |
+ http2? ( net-libs/nghttp2[${MULTILIB_USEDEP}] ) |
65 |
+ nghttp3? ( |
66 |
+ net-libs/nghttp3[${MULTILIB_USEDEP}] |
67 |
+ net-libs/ngtcp2[ssl,${MULTILIB_USEDEP}] |
68 |
+ ) |
69 |
+ quiche? ( >=net-libs/quiche-0.3.0[${MULTILIB_USEDEP}] ) |
70 |
+ idn? ( net-dns/libidn2:0=[static-libs?,${MULTILIB_USEDEP}] ) |
71 |
+ adns? ( net-dns/c-ares:0[${MULTILIB_USEDEP}] ) |
72 |
+ kerberos? ( >=virtual/krb5-0-r1[${MULTILIB_USEDEP}] ) |
73 |
+ metalink? ( >=media-libs/libmetalink-0.1.1[${MULTILIB_USEDEP}] ) |
74 |
+ rtmp? ( media-video/rtmpdump[${MULTILIB_USEDEP}] ) |
75 |
+ ssh? ( net-libs/libssh2[${MULTILIB_USEDEP}] ) |
76 |
+ sys-libs/zlib[${MULTILIB_USEDEP}] |
77 |
+ zstd? ( app-arch/zstd:=[${MULTILIB_USEDEP}] )" |
78 |
+ |
79 |
+# Do we need to enforce the same ssl backend for curl and rtmpdump? Bug #423303 |
80 |
+# rtmp? ( |
81 |
+# media-video/rtmpdump |
82 |
+# curl_ssl_gnutls? ( media-video/rtmpdump[gnutls] ) |
83 |
+# curl_ssl_openssl? ( media-video/rtmpdump[-gnutls,ssl] ) |
84 |
+# ) |
85 |
+ |
86 |
+# ssl providers to be added: |
87 |
+# fbopenssl $(use_with spnego) |
88 |
+ |
89 |
+DEPEND="${RDEPEND}" |
90 |
+BDEPEND="virtual/pkgconfig |
91 |
+ test? ( |
92 |
+ sys-apps/diffutils |
93 |
+ dev-lang/perl |
94 |
+ )" |
95 |
+ |
96 |
+# c-ares must be disabled for threads |
97 |
+# only one default ssl provider can be enabled |
98 |
+REQUIRED_USE=" |
99 |
+ winssl? ( elibc_Winnt ) |
100 |
+ threads? ( !adns ) |
101 |
+ ssl? ( |
102 |
+ ^^ ( |
103 |
+ curl_ssl_gnutls |
104 |
+ curl_ssl_mbedtls |
105 |
+ curl_ssl_nss |
106 |
+ curl_ssl_openssl |
107 |
+ curl_ssl_winssl |
108 |
+ ) |
109 |
+ )" |
110 |
+ |
111 |
+DOCS=( CHANGES README docs/FEATURES.md docs/INTERNALS.md \ |
112 |
+ docs/FAQ docs/BUGS.md docs/CONTRIBUTE.md ) |
113 |
+ |
114 |
+MULTILIB_WRAPPED_HEADERS=( |
115 |
+ /usr/include/curl/curlbuild.h |
116 |
+) |
117 |
+ |
118 |
+MULTILIB_CHOST_TOOLS=( |
119 |
+ /usr/bin/curl-config |
120 |
+) |
121 |
+ |
122 |
+src_prepare() { |
123 |
+ eapply "${FILESDIR}"/${PN}-7.30.0-prefix.patch |
124 |
+ eapply "${FILESDIR}"/${PN}-respect-cflags-3.patch |
125 |
+ eapply "${FILESDIR}"/${PN}-fix-gnutls-nettle.patch |
126 |
+ |
127 |
+ sed -i '/LD_LIBRARY_PATH=/d' configure.ac || die #382241 |
128 |
+ sed -i '/CURL_MAC_CFLAGS/d' configure.ac || die #637252 |
129 |
+ |
130 |
+ eapply_user |
131 |
+ eprefixify curl-config.in |
132 |
+ eautoreconf |
133 |
+} |
134 |
+ |
135 |
+multilib_src_configure() { |
136 |
+ # We make use of the fact that later flags override earlier ones |
137 |
+ # So start with all ssl providers off until proven otherwise |
138 |
+ # TODO: in the future, we may want to add wolfssl (https://www.wolfssl.com/) |
139 |
+ local myconf=() |
140 |
+ |
141 |
+ myconf+=( --without-gnutls --without-mbedtls --without-nss --without-polarssl --without-ssl --without-winssl ) |
142 |
+ myconf+=( --without-ca-fallback --with-ca-bundle="${EPREFIX}"/etc/ssl/certs/ca-certificates.crt ) |
143 |
+ #myconf+=( --without-default-ssl-backend ) |
144 |
+ if use ssl ; then |
145 |
+ if use gnutls || use curl_ssl_gnutls; then |
146 |
+ einfo "SSL provided by gnutls" |
147 |
+ myconf+=( --with-gnutls --with-nettle ) |
148 |
+ fi |
149 |
+ if use mbedtls || use curl_ssl_mbedtls; then |
150 |
+ einfo "SSL provided by mbedtls" |
151 |
+ myconf+=( --with-mbedtls ) |
152 |
+ fi |
153 |
+ if use nss || use curl_ssl_nss; then |
154 |
+ einfo "SSL provided by nss" |
155 |
+ myconf+=( --with-nss ) |
156 |
+ fi |
157 |
+ if use openssl || use curl_ssl_openssl; then |
158 |
+ einfo "SSL provided by openssl" |
159 |
+ myconf+=( --with-ssl --with-ca-path="${EPREFIX}"/etc/ssl/certs ) |
160 |
+ fi |
161 |
+ if use winssl || use curl_ssl_winssl; then |
162 |
+ einfo "SSL provided by Windows" |
163 |
+ myconf+=( --with-winssl ) |
164 |
+ fi |
165 |
+ |
166 |
+ if use curl_ssl_gnutls; then |
167 |
+ einfo "Default SSL provided by gnutls" |
168 |
+ myconf+=( --with-default-ssl-backend=gnutls ) |
169 |
+ elif use curl_ssl_mbedtls; then |
170 |
+ einfo "Default SSL provided by mbedtls" |
171 |
+ myconf+=( --with-default-ssl-backend=mbedtls ) |
172 |
+ elif use curl_ssl_nss; then |
173 |
+ einfo "Default SSL provided by nss" |
174 |
+ myconf+=( --with-default-ssl-backend=nss ) |
175 |
+ elif use curl_ssl_openssl; then |
176 |
+ einfo "Default SSL provided by openssl" |
177 |
+ myconf+=( --with-default-ssl-backend=openssl ) |
178 |
+ elif use curl_ssl_winssl; then |
179 |
+ einfo "Default SSL provided by Windows" |
180 |
+ myconf+=( --with-default-ssl-backend=winssl ) |
181 |
+ else |
182 |
+ eerror "We can't be here because of REQUIRED_USE." |
183 |
+ fi |
184 |
+ |
185 |
+ else |
186 |
+ einfo "SSL disabled" |
187 |
+ fi |
188 |
+ |
189 |
+ # These configuration options are organized alphabetically |
190 |
+ # within each category. This should make it easier if we |
191 |
+ # ever decide to make any of them contingent on USE flags: |
192 |
+ # 1) protocols first. To see them all do |
193 |
+ # 'grep SUPPORT_PROTOCOLS configure.ac' |
194 |
+ # 2) --enable/disable options second. |
195 |
+ # 'grep -- --enable configure | grep Check | awk '{ print $4 }' | sort |
196 |
+ # 3) --with/without options third. |
197 |
+ # grep -- --with configure | grep Check | awk '{ print $4 }' | sort |
198 |
+ |
199 |
+ ECONF_SOURCE="${S}" \ |
200 |
+ econf \ |
201 |
+ $(use_enable alt-svc) \ |
202 |
+ --enable-crypto-auth \ |
203 |
+ --enable-dict \ |
204 |
+ --disable-ech \ |
205 |
+ --enable-file \ |
206 |
+ $(use_enable ftp) \ |
207 |
+ $(use_enable gopher) \ |
208 |
+ $(use_enable hsts) \ |
209 |
+ --enable-http \ |
210 |
+ $(use_enable imap) \ |
211 |
+ $(use_enable ldap) \ |
212 |
+ $(use_enable ldap ldaps) \ |
213 |
+ --disable-ntlm-wb \ |
214 |
+ $(use_enable pop3) \ |
215 |
+ --enable-rt \ |
216 |
+ --enable-rtsp \ |
217 |
+ $(use_enable samba smb) \ |
218 |
+ $(use_with ssh libssh2) \ |
219 |
+ $(use_enable smtp) \ |
220 |
+ $(use_enable telnet) \ |
221 |
+ $(use_enable tftp) \ |
222 |
+ --enable-tls-srp \ |
223 |
+ $(use_enable adns ares) \ |
224 |
+ --enable-cookies \ |
225 |
+ --enable-dateparse \ |
226 |
+ --enable-dnsshuffle \ |
227 |
+ --enable-doh \ |
228 |
+ --enable-hidden-symbols \ |
229 |
+ --enable-http-auth \ |
230 |
+ $(use_enable ipv6) \ |
231 |
+ --enable-largefile \ |
232 |
+ --enable-manual \ |
233 |
+ --enable-mime \ |
234 |
+ --enable-netrc \ |
235 |
+ $(use_enable progress-meter) \ |
236 |
+ --enable-proxy \ |
237 |
+ --disable-sspi \ |
238 |
+ $(use_enable static-libs static) \ |
239 |
+ $(use_enable threads threaded-resolver) \ |
240 |
+ $(use_enable threads pthreads) \ |
241 |
+ --disable-versioned-symbols \ |
242 |
+ --without-amissl \ |
243 |
+ --without-bearssl \ |
244 |
+ --without-cyassl \ |
245 |
+ --without-darwinssl \ |
246 |
+ --without-fish-functions-dir \ |
247 |
+ $(use_with idn libidn2) \ |
248 |
+ $(use_with kerberos gssapi "${EPREFIX}"/usr) \ |
249 |
+ $(use_with metalink libmetalink) \ |
250 |
+ $(use_with http2 nghttp2) \ |
251 |
+ --without-libpsl \ |
252 |
+ $(use_with nghttp3) \ |
253 |
+ $(use_with nghttp3 ngtcp2) \ |
254 |
+ $(use_with quiche) \ |
255 |
+ $(use_with rtmp librtmp) \ |
256 |
+ $(use_with brotli) \ |
257 |
+ --without-schannel \ |
258 |
+ --without-secure-transport \ |
259 |
+ --without-spnego \ |
260 |
+ --without-winidn \ |
261 |
+ --without-wolfssl \ |
262 |
+ --with-zlib \ |
263 |
+ $(use_with zstd) \ |
264 |
+ "${myconf[@]}" |
265 |
+ |
266 |
+ if ! multilib_is_native_abi; then |
267 |
+ # avoid building the client |
268 |
+ sed -i -e '/SUBDIRS/s:src::' Makefile || die |
269 |
+ sed -i -e '/SUBDIRS/s:scripts::' Makefile || die |
270 |
+ fi |
271 |
+ |
272 |
+ # Fix up the pkg-config file to be more robust. |
273 |
+ # https://github.com/curl/curl/issues/864 |
274 |
+ local priv=() libs=() |
275 |
+ # We always enable zlib. |
276 |
+ libs+=( "-lz" ) |
277 |
+ priv+=( "zlib" ) |
278 |
+ if use http2; then |
279 |
+ libs+=( "-lnghttp2" ) |
280 |
+ priv+=( "libnghttp2" ) |
281 |
+ fi |
282 |
+ if use quiche; then |
283 |
+ libs+=( "-lquiche" ) |
284 |
+ priv+=( "quiche" ) |
285 |
+ fi |
286 |
+ if use nghttp3; then |
287 |
+ libs+=( "-lnghttp3" "-lngtcp2" ) |
288 |
+ priv+=( "libnghttp3" "-libtcp2" ) |
289 |
+ fi |
290 |
+ if use ssl && use curl_ssl_openssl; then |
291 |
+ libs+=( "-lssl" "-lcrypto" ) |
292 |
+ priv+=( "openssl" ) |
293 |
+ fi |
294 |
+ grep -q Requires.private libcurl.pc && die "need to update ebuild" |
295 |
+ libs=$(printf '|%s' "${libs[@]}") |
296 |
+ sed -i -r \ |
297 |
+ -e "/^Libs.private/s:(${libs#|})( |$)::g" \ |
298 |
+ libcurl.pc || die |
299 |
+ echo "Requires.private: ${priv[*]}" >> libcurl.pc |
300 |
+} |
301 |
+ |
302 |
+multilib_src_install_all() { |
303 |
+ einstalldocs |
304 |
+ find "${ED}" -type f -name '*.la' -delete |
305 |
+ rm -rf "${ED}"/etc/ |
306 |
+} |