1 |
commit: 788cf647289416d1464bca4556f0207b8b07c390 |
2 |
Author: Thomas Deutschmann <whissi <AT> gentoo <DOT> org> |
3 |
AuthorDate: Wed Nov 27 08:26:19 2019 +0000 |
4 |
Commit: Thomas Deutschmann <whissi <AT> gentoo <DOT> org> |
5 |
CommitDate: Wed Nov 27 08:27:22 2019 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=788cf647 |
7 |
|
8 |
dev-libs/openssl: move stable keywords |
9 |
|
10 |
Package-Manager: Portage-2.3.79, Repoman-2.3.18 |
11 |
Signed-off-by: Thomas Deutschmann <whissi <AT> gentoo.org> |
12 |
|
13 |
dev-libs/openssl/openssl-1.1.1d-r2.ebuild | 331 ------------------------------ |
14 |
dev-libs/openssl/openssl-1.1.1d-r3.ebuild | 2 +- |
15 |
2 files changed, 1 insertion(+), 332 deletions(-) |
16 |
|
17 |
diff --git a/dev-libs/openssl/openssl-1.1.1d-r2.ebuild b/dev-libs/openssl/openssl-1.1.1d-r2.ebuild |
18 |
deleted file mode 100644 |
19 |
index 4104fdaa8e1..00000000000 |
20 |
--- a/dev-libs/openssl/openssl-1.1.1d-r2.ebuild |
21 |
+++ /dev/null |
22 |
@@ -1,331 +0,0 @@ |
23 |
-# Copyright 1999-2019 Gentoo Authors |
24 |
-# Distributed under the terms of the GNU General Public License v2 |
25 |
- |
26 |
-EAPI="7" |
27 |
- |
28 |
-inherit flag-o-matic toolchain-funcs multilib multilib-minimal |
29 |
- |
30 |
-MY_P=${P/_/-} |
31 |
- |
32 |
-# This patch set is based on the following files from Fedora 31, |
33 |
-# see https://src.fedoraproject.org/rpms/openssl/blob/f31/f/openssl.spec |
34 |
-# for more details: |
35 |
-# - hobble-openssl (SOURCE1) |
36 |
-# - ec_curve.c (SOURCE12) -- MODIFIED |
37 |
-# - ectest.c (SOURCE13) |
38 |
-# - openssl-1.1.1-ec-curves.patch (PATCH37) -- MODIFIED |
39 |
-BINDIST_PATCH_SET="openssl-1.1.1d-bindist-1.0.tar.xz" |
40 |
- |
41 |
-DESCRIPTION="full-strength general purpose cryptography library (including SSL and TLS)" |
42 |
-HOMEPAGE="https://www.openssl.org/" |
43 |
-SRC_URI="mirror://openssl/source/${MY_P}.tar.gz |
44 |
- bindist? ( |
45 |
- mirror://gentoo/${BINDIST_PATCH_SET} |
46 |
- https://dev.gentoo.org/~whissi/dist/openssl/${BINDIST_PATCH_SET} |
47 |
- )" |
48 |
- |
49 |
-LICENSE="openssl" |
50 |
-SLOT="0/1.1" # .so version of libssl/libcrypto |
51 |
-[[ "${PV}" = *_pre* ]] || \ |
52 |
-KEYWORDS="alpha amd64 arm arm64 hppa ia64 m68k ~mips ppc ppc64 ~riscv s390 sh sparc x86 ~x86-linux" |
53 |
-IUSE="+asm bindist elibc_musl rfc3779 sctp cpu_flags_x86_sse2 sslv3 static-libs test tls-heartbeat vanilla zlib" |
54 |
-RESTRICT="!bindist? ( bindist ) |
55 |
- !test? ( test )" |
56 |
- |
57 |
-RDEPEND=">=app-misc/c_rehash-1.7-r1 |
58 |
- zlib? ( >=sys-libs/zlib-1.2.8-r1[static-libs(+)?,${MULTILIB_USEDEP}] )" |
59 |
-DEPEND="${RDEPEND}" |
60 |
-BDEPEND=" |
61 |
- >=dev-lang/perl-5 |
62 |
- sctp? ( >=net-misc/lksctp-tools-1.0.12 ) |
63 |
- test? ( |
64 |
- sys-apps/diffutils |
65 |
- sys-devel/bc |
66 |
- )" |
67 |
-PDEPEND="app-misc/ca-certificates" |
68 |
- |
69 |
-PATCHES=( |
70 |
- "${FILESDIR}"/${PN}-1.1.0j-parallel_install_fix.patch #671602 |
71 |
- "${FILESDIR}"/${P}-fix-zlib.patch |
72 |
- "${FILESDIR}"/${P}-fix-potential-memleaks-w-BN_to_ASN1_INTEGER.patch |
73 |
-) |
74 |
- |
75 |
-S="${WORKDIR}/${MY_P}" |
76 |
- |
77 |
-# force upgrade to prevent broken login, bug 696950 |
78 |
-RDEPEND+=" !<net-misc/openssh-8.0_p1-r3" |
79 |
- |
80 |
-MULTILIB_WRAPPED_HEADERS=( |
81 |
- usr/include/openssl/opensslconf.h |
82 |
-) |
83 |
- |
84 |
-pkg_setup() { |
85 |
- [[ ${MERGE_TYPE} == binary ]] && return |
86 |
- |
87 |
- # must check in pkg_setup; sysctl don't work with userpriv! |
88 |
- if has test ${FEATURES}; then |
89 |
- if use sctp; then |
90 |
- # test_ssl_new will fail with "Ensure SCTP AUTH chunks are enabled in kernel" |
91 |
- # if sctp.auth_enable is not enabled. |
92 |
- local sctp_auth_status=$(sysctl -n net.sctp.auth_enable 2>/dev/null) |
93 |
- if [[ -z "${sctp_auth_status}" || ${sctp_auth_status} != 1 ]]; then |
94 |
- die "FEATURES=test with USE=sctp requires net.sctp.auth_enable=1!" |
95 |
- fi |
96 |
- fi |
97 |
- fi |
98 |
-} |
99 |
- |
100 |
-src_prepare() { |
101 |
- # allow openssl to be cross-compiled |
102 |
- cp "${FILESDIR}"/gentoo.config-1.0.2 gentoo.config || die |
103 |
- chmod a+rx gentoo.config || die |
104 |
- |
105 |
- if use bindist; then |
106 |
- mv "${WORKDIR}"/bindist-patches/hobble-openssl "${WORKDIR}" || die |
107 |
- bash "${WORKDIR}"/hobble-openssl || die |
108 |
- |
109 |
- cp -f "${WORKDIR}"/bindist-patches/ec_curve.c "${S}"/crypto/ec/ || die |
110 |
- cp -f "${WORKDIR}"/bindist-patches/ectest.c "${S}"/test/ || die |
111 |
- |
112 |
- eapply "${WORKDIR}"/bindist-patches/ec-curves.patch |
113 |
- |
114 |
- local known_failing_test |
115 |
- for known_failing_test in \ |
116 |
- 30-test_evp_extra.t \ |
117 |
- 80-test_ssl_new.t \ |
118 |
- ; do |
119 |
- ebegin "Disabling test '${known_failing_test}' which is known to fail with USE=bindist" |
120 |
- rm test/recipes/${known_failing_test} || die |
121 |
- eend $? |
122 |
- done |
123 |
- |
124 |
- # Also see the configure parts below: |
125 |
- # enable-ec \ |
126 |
- # $(use_ssl !bindist ec2m) \ |
127 |
- fi |
128 |
- |
129 |
- # keep this in sync with app-misc/c_rehash |
130 |
- SSL_CNF_DIR="/etc/ssl" |
131 |
- |
132 |
- # Make sure we only ever touch Makefile.org and avoid patching a file |
133 |
- # that gets blown away anyways by the Configure script in src_configure |
134 |
- rm -f Makefile |
135 |
- |
136 |
- if ! use vanilla ; then |
137 |
- if [[ $(declare -p PATCHES 2>/dev/null) == "declare -a"* ]] ; then |
138 |
- [[ ${#PATCHES[@]} -gt 0 ]] && eapply "${PATCHES[@]}" |
139 |
- fi |
140 |
- fi |
141 |
- |
142 |
- eapply_user #332661 |
143 |
- |
144 |
- if has test ${FEATURES}; then |
145 |
- if use sctp; then |
146 |
- if has network-sandbox ${FEATURES}; then |
147 |
- ebegin "Disabling test '80-test_ssl_new.t' which is known to fail with FEATURES=network-sandbox" |
148 |
- rm test/recipes/80-test_ssl_new.t || die |
149 |
- eend $? |
150 |
- fi |
151 |
- fi |
152 |
- fi |
153 |
- |
154 |
- # make sure the man pages are suffixed #302165 |
155 |
- # don't bother building man pages if they're disabled |
156 |
- # Make DOCDIR Gentoo compliant |
157 |
- sed -i \ |
158 |
- -e '/^MANSUFFIX/s:=.*:=ssl:' \ |
159 |
- -e '/^MAKEDEPPROG/s:=.*:=$(CC):' \ |
160 |
- -e $(has noman FEATURES \ |
161 |
- && echo '/^install:/s:install_docs::' \ |
162 |
- || echo '/^MANDIR=/s:=.*:='${EPREFIX}'/usr/share/man:') \ |
163 |
- -e "/^DOCDIR/s@\$(BASENAME)@&-${PVR}@" \ |
164 |
- Configurations/unix-Makefile.tmpl \ |
165 |
- || die |
166 |
- |
167 |
- # quiet out unknown driver argument warnings since openssl |
168 |
- # doesn't have well-split CFLAGS and we're making it even worse |
169 |
- # and 'make depend' uses -Werror for added fun (#417795 again) |
170 |
- [[ ${CC} == *clang* ]] && append-flags -Qunused-arguments |
171 |
- |
172 |
- append-flags -fno-strict-aliasing |
173 |
- append-flags $(test-flags-CC -Wa,--noexecstack) |
174 |
- append-cppflags -DOPENSSL_NO_BUF_FREELISTS |
175 |
- |
176 |
- # Prefixify Configure shebang (#141906) |
177 |
- sed \ |
178 |
- -e "1s,/usr/bin/env,${EPREFIX}&," \ |
179 |
- -i Configure || die |
180 |
- # Remove test target when FEATURES=test isn't set |
181 |
- if ! use test ; then |
182 |
- sed \ |
183 |
- -e '/^$config{dirs}/s@ "test",@@' \ |
184 |
- -i Configure || die |
185 |
- fi |
186 |
- # The config script does stupid stuff to prompt the user. Kill it. |
187 |
- sed -i '/stty -icanon min 0 time 50; read waste/d' config || die |
188 |
- ./config --test-sanity || die "I AM NOT SANE" |
189 |
- |
190 |
- multilib_copy_sources |
191 |
-} |
192 |
- |
193 |
-multilib_src_configure() { |
194 |
- unset APPS #197996 |
195 |
- unset SCRIPTS #312551 |
196 |
- unset CROSS_COMPILE #311473 |
197 |
- |
198 |
- tc-export CC AR RANLIB RC |
199 |
- |
200 |
- # Clean out patent-or-otherwise-encumbered code |
201 |
- # Camellia: Royalty Free https://en.wikipedia.org/wiki/Camellia_(cipher) |
202 |
- # IDEA: Expired https://en.wikipedia.org/wiki/International_Data_Encryption_Algorithm |
203 |
- # EC: ????????? ??/??/2015 https://en.wikipedia.org/wiki/Elliptic_Curve_Cryptography |
204 |
- # MDC2: Expired https://en.wikipedia.org/wiki/MDC-2 |
205 |
- # RC5: Expired https://en.wikipedia.org/wiki/RC5 |
206 |
- |
207 |
- use_ssl() { usex $1 "enable-${2:-$1}" "no-${2:-$1}" " ${*:3}" ; } |
208 |
- echoit() { echo "$@" ; "$@" ; } |
209 |
- |
210 |
- local krb5=$(has_version app-crypt/mit-krb5 && echo "MIT" || echo "Heimdal") |
211 |
- |
212 |
- # See if our toolchain supports __uint128_t. If so, it's 64bit |
213 |
- # friendly and can use the nicely optimized code paths. #460790 |
214 |
- local ec_nistp_64_gcc_128 |
215 |
- # Disable it for now though #469976 |
216 |
- #if ! use bindist ; then |
217 |
- # echo "__uint128_t i;" > "${T}"/128.c |
218 |
- # if ${CC} ${CFLAGS} -c "${T}"/128.c -o /dev/null >&/dev/null ; then |
219 |
- # ec_nistp_64_gcc_128="enable-ec_nistp_64_gcc_128" |
220 |
- # fi |
221 |
- #fi |
222 |
- |
223 |
- local sslout=$(./gentoo.config) |
224 |
- einfo "Use configuration ${sslout:-(openssl knows best)}" |
225 |
- local config="Configure" |
226 |
- [[ -z ${sslout} ]] && config="config" |
227 |
- |
228 |
- # Fedora hobbled-EC needs 'no-ec2m' |
229 |
- # 'srp' was restricted until early 2017 as well. |
230 |
- # "disable-deprecated" option breaks too many consumers. |
231 |
- # Don't set it without thorough revdeps testing. |
232 |
- # Make sure user flags don't get added *yet* to avoid duplicated |
233 |
- # flags. |
234 |
- CFLAGS= LDFLAGS= echoit \ |
235 |
- ./${config} \ |
236 |
- ${sslout} \ |
237 |
- $(use cpu_flags_x86_sse2 || echo "no-sse2") \ |
238 |
- enable-camellia \ |
239 |
- enable-ec \ |
240 |
- $(use_ssl !bindist ec2m) \ |
241 |
- enable-srp \ |
242 |
- $(use elibc_musl && echo "no-async") \ |
243 |
- ${ec_nistp_64_gcc_128} \ |
244 |
- enable-idea \ |
245 |
- enable-mdc2 \ |
246 |
- enable-rc5 \ |
247 |
- $(use_ssl sslv3 ssl3) \ |
248 |
- $(use_ssl sslv3 ssl3-method) \ |
249 |
- $(use_ssl asm) \ |
250 |
- $(use_ssl rfc3779) \ |
251 |
- $(use_ssl sctp) \ |
252 |
- $(use_ssl tls-heartbeat heartbeats) \ |
253 |
- $(use_ssl zlib) \ |
254 |
- --prefix="${EPREFIX}"/usr \ |
255 |
- --openssldir="${EPREFIX}"${SSL_CNF_DIR} \ |
256 |
- --libdir=$(get_libdir) \ |
257 |
- shared threads \ |
258 |
- || die |
259 |
- |
260 |
- # Clean out hardcoded flags that openssl uses |
261 |
- local DEFAULT_CFLAGS=$(grep ^CFLAGS= Makefile | LC_ALL=C sed \ |
262 |
- -e 's:^CFLAGS=::' \ |
263 |
- -e 's:\(^\| \)-fomit-frame-pointer::g' \ |
264 |
- -e 's:\(^\| \)-O[^ ]*::g' \ |
265 |
- -e 's:\(^\| \)-march=[^ ]*::g' \ |
266 |
- -e 's:\(^\| \)-mcpu=[^ ]*::g' \ |
267 |
- -e 's:\(^\| \)-m[^ ]*::g' \ |
268 |
- -e 's:^ *::' \ |
269 |
- -e 's: *$::' \ |
270 |
- -e 's: \+: :g' \ |
271 |
- -e 's:\\:\\\\:g' |
272 |
- ) |
273 |
- |
274 |
- # Now insert clean default flags with user flags |
275 |
- sed -i \ |
276 |
- -e "/^CFLAGS=/s|=.*|=${DEFAULT_CFLAGS} ${CFLAGS}|" \ |
277 |
- -e "/^LDFLAGS=/s|=[[:space:]]*$|=${LDFLAGS}|" \ |
278 |
- Makefile || die |
279 |
-} |
280 |
- |
281 |
-multilib_src_compile() { |
282 |
- # depend is needed to use $confopts; it also doesn't matter |
283 |
- # that it's -j1 as the code itself serializes subdirs |
284 |
- emake -j1 depend |
285 |
- emake all |
286 |
-} |
287 |
- |
288 |
-multilib_src_test() { |
289 |
- emake -j1 test |
290 |
-} |
291 |
- |
292 |
-multilib_src_install() { |
293 |
- # We need to create $ED/usr on our own to avoid a race condition #665130 |
294 |
- if [[ ! -d "${ED}/usr" ]]; then |
295 |
- # We can only create this directory once |
296 |
- mkdir "${ED}"/usr || die |
297 |
- fi |
298 |
- |
299 |
- emake DESTDIR="${D}" install |
300 |
-} |
301 |
- |
302 |
-multilib_src_install_all() { |
303 |
- # openssl installs perl version of c_rehash by default, but |
304 |
- # we provide a shell version via app-misc/c_rehash |
305 |
- rm "${ED}"/usr/bin/c_rehash || die |
306 |
- |
307 |
- dodoc CHANGES* FAQ NEWS README doc/*.txt doc/${PN}-c-indent.el |
308 |
- |
309 |
- # This is crappy in that the static archives are still built even |
310 |
- # when USE=static-libs. But this is due to a failing in the openssl |
311 |
- # build system: the static archives are built as PIC all the time. |
312 |
- # Only way around this would be to manually configure+compile openssl |
313 |
- # twice; once with shared lib support enabled and once without. |
314 |
- use static-libs || rm -f "${ED}"/usr/lib*/lib*.a |
315 |
- |
316 |
- # create the certs directory |
317 |
- keepdir ${SSL_CNF_DIR}/certs |
318 |
- |
319 |
- # Namespace openssl programs to prevent conflicts with other man pages |
320 |
- cd "${ED}"/usr/share/man || die |
321 |
- local m d s |
322 |
- for m in $(find . -type f | xargs grep -L '#include') ; do |
323 |
- d=${m%/*} ; d=${d#./} ; m=${m##*/} |
324 |
- [[ ${m} == openssl.1* ]] && continue |
325 |
- [[ -n $(find -L ${d} -type l) ]] && die "erp, broken links already!" |
326 |
- mv ${d}/{,ssl-}${m} |
327 |
- # fix up references to renamed man pages |
328 |
- sed -i '/^[.]SH "SEE ALSO"/,/^[.]/s:\([^(, ]*(1)\):ssl-\1:g' ${d}/ssl-${m} |
329 |
- ln -s ssl-${m} ${d}/openssl-${m} |
330 |
- # locate any symlinks that point to this man page ... we assume |
331 |
- # that any broken links are due to the above renaming |
332 |
- for s in $(find -L ${d} -type l) ; do |
333 |
- s=${s##*/} |
334 |
- rm -f ${d}/${s} |
335 |
- # We don't want to "|| die" here |
336 |
- ln -s ssl-${m} ${d}/ssl-${s} |
337 |
- ln -s ssl-${s} ${d}/openssl-${s} |
338 |
- done |
339 |
- done |
340 |
- [[ -n $(find -L ${d} -type l) ]] && die "broken manpage links found :(" |
341 |
- |
342 |
- dodir /etc/sandbox.d #254521 |
343 |
- echo 'SANDBOX_PREDICT="/dev/crypto"' > "${ED}"/etc/sandbox.d/10openssl |
344 |
- |
345 |
- diropts -m0700 |
346 |
- keepdir ${SSL_CNF_DIR}/private |
347 |
-} |
348 |
- |
349 |
-pkg_postinst() { |
350 |
- ebegin "Running 'c_rehash ${EROOT}${SSL_CNF_DIR}/certs/' to rebuild hashes #333069" |
351 |
- c_rehash "${EROOT}${SSL_CNF_DIR}/certs" >/dev/null |
352 |
- eend $? |
353 |
-} |
354 |
|
355 |
diff --git a/dev-libs/openssl/openssl-1.1.1d-r3.ebuild b/dev-libs/openssl/openssl-1.1.1d-r3.ebuild |
356 |
index 803db123632..932e1a155f5 100644 |
357 |
--- a/dev-libs/openssl/openssl-1.1.1d-r3.ebuild |
358 |
+++ b/dev-libs/openssl/openssl-1.1.1d-r3.ebuild |
359 |
@@ -27,7 +27,7 @@ SRC_URI="mirror://openssl/source/${MY_P}.tar.gz |
360 |
LICENSE="openssl" |
361 |
SLOT="0/1.1" # .so version of libssl/libcrypto |
362 |
[[ "${PV}" = *_pre* ]] || \ |
363 |
-KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sh ~sparc ~x86 ~x86-linux" |
364 |
+KEYWORDS="alpha amd64 arm arm64 hppa ia64 m68k ~mips ppc ppc64 ~riscv s390 sh sparc x86 ~x86-linux" |
365 |
IUSE="+asm bindist elibc_musl rfc3779 sctp cpu_flags_x86_sse2 sslv3 static-libs test tls-heartbeat vanilla zlib" |
366 |
RESTRICT="!bindist? ( bindist ) |
367 |
!test? ( test )" |