openssl update
Hanno Böck

Hanno Böck commited on 2015-02-21 11:53:02
Zeige 2 geänderte Dateien mit 266 Einfügungen und 0 Löschungen.

... ...
@@ -7,10 +7,15 @@ AUX openssl-1.0.1-x32.patch 3273 SHA256 a4f05b8757e225a05a9c5a3ea485159066760d87
7 7
 AUX openssl-1.0.1e-s_client-verify.patch 592 SHA256 6f540fce663eefbe68cee16ad7d8d561d6c898eeb4180c2f4a4caa7e43c6d0c9 SHA512 117b1017e1259667078d3ccdcd9fd46357c6f85cf2702794f49c612b37acdc044fe88f871dbe46fcad9ed4cd8aaaaee800dddb5286203322802efd7549a43b68 WHIRLPOOL 70a4cc36b1dcb24d7e9bcef016684fb2394977f7f20aa332ebd0aa15e3f4c16c74563d2fc0ba8d70669f6cc9a13bf8a30cdb28ebafe2d102cd2859a4e32c38d7
8 8
 AUX openssl-1.0.1f-revert-alpha-perl-generation.patch 3102 SHA256 6e502275b32ac0eca80f28448ae1bb88506f9135258f420fd857ea0b9b485778 SHA512 c80439da3d268e70fd492d0ca73c0a17ddb088b9330610794a338d1921ee13dad9caca4c81ca103b82a7541c8712f77e51f352ec1b1b02789d9aed291acb0cdc WHIRLPOOL cb760366c8759b1c78c5307134bb48c4fc12b1556276c2ef55455ea54725d20cb433ade966a7453f512d2feb5ae89a9798078ab535e4605366633a8e003c7ac6
9 9
 AUX openssl-1.0.1h-ipv6.patch 17788 SHA256 7adeeb88cc544f8b210efbe2baff48fccf5029b582dff7010ae70e0e1f097d7b SHA512 0f0990d4294abcb5f3e51c84080883046a054c710b57a23f99b3323727d5e9aeb5ddeb6b6c2565b4be364f7c21419c90ce5288154e404cd663678f87e0d1c259 WHIRLPOOL cfe7a2e141a4a6252ffcfe215b16dd1082bc14a757dad7eb01bb9819de41ef0ee51a4b2dbf110c27b52e483341c337bf4d1f77f4f9f3172d2fee9e348c30af7e
10
+AUX openssl-1.0.2-ipv6.patch 18811 SHA256 9ff3150c75f3f3e6a9773ffe54d90994cbf68cc919134aea68e09e7ed921763d SHA512 58e293f8f19a3fad08729b842dd977b73fedb0c49208d87a056bfea857c0e2b79a310d7d098c04429b65564fce64defeda6d1dcc3068ad5a80ef276db6421e54 WHIRLPOOL 36a0fffc7238011b93077bed94c9507f2ffc1cf199e6c06e94d01589cdc84a6568b9122e1a120b8262bd0a1c43f25169a29796c92a78338dd9f03b4cc2cdf0b8
11
+AUX openssl-1.0.2-parallel-build.patch 10661 SHA256 bc5622150a964dc2d9909f41557140b696ce1bdfa4e2b12cc3e0e51029ead32b SHA512 a4957304a4424016cd8a1c6552c422cd042d737e12f96235ec54d1e601ccbe8cb79d931ac8777d1a599bd4a70eac4e6700a24362f14fb04eb273df82f2de0d01 WHIRLPOOL 5b34e45dcb0db6649e26d275925ca008f5201afbc22184e15c5324513bc0ed40ee271a70686e10a20bb219b3c4bd2148323b317ead97cdc27a3c897c0a07d228
12
+AUX openssl-1.0.2-s_client-verify.patch 648 SHA256 b6ca2278dd9833f87a1d0037cb3cac8aee0f8326ff13ece1f08a536b8545eb77 SHA512 78b09ae700096205582785584a268776af46fc5bc94a0faa1ce6087ffcc945649e69269ff7fa88dedd5df1a5cdecc53e885de1e39506470f23b02028ca962104 WHIRLPOOL 8e7c90d37c1736b4b2f2c38d1c12dcfee4996a50a2a7dd07645a0c0b6616006d11232dd0f88ab735833e1c46aa171ceb5e1288c3d57296010bdda59295de7599
10 13
 DIST openssl-1.0.1i.tar.gz 4422117 SHA256 3c179f46ca77069a6a0bac70212a9b3b838b2f66129cb52d568837fc79d8fcc7 SHA512 6cbcdcec8568236e8f20f0461f93df8a193a0ad88102ff548443e6ec87e2a7f649e314beee1e6bafda693934b4fb142244b61d14bf736828dda09e277b941d93 WHIRLPOOL 4baefe8a203243d08c2ca4dc9e1019a539135604a8ddfb09b9a7f2711108ad6ebd45eef1cfa09331f19fe57defbe7e1390f9ac2de086437a484c5819cabb5a4a
11 14
 DIST openssl-1.0.1j.tar.gz 4432964 SHA256 1b60ca8789ba6f03e8ef20da2293b8dc131c39d83814e775069f02d26354edf3 SHA512 a786bb99b68d88c1de79d3c5372767f091ebeefb5abc1d4883253fd3ab5a86af53389f5ff36fdd8faa27c5fb78be8bbff406392c373358697da80d250eadebb8 WHIRLPOOL 467aa3b02d04837e3281670401985e492d15b561c03b97246e3c8e61b0d3b1927332e3a226de4ed5bd02265a04fb31ce84c3501f4af9685633d00a9b43c56978
12 15
 DIST openssl-1.0.1k.tar.gz 4434910 SHA256 8f9faeaebad088e772f4ef5e38252d472be4d878c6b3a2718c10a4fcebe7a41c SHA512 8b000fbd1bf919d9913a314f99aedd48a69f6caa4ccf43237889e73e08cbe0d82bfc27e9c7c4cade09fc459f91d6c4a831a9b3fc8bca0344fb864eadd7d1e8e8 WHIRLPOOL 5236a966d610c971e473cfc30e5412a72eef116fd259ada9c50da08bcd4ca967f80bb19babf530b4e5b9f1f24e9275e00391eb2e12a26d4544f593e2b4ba20b8
16
+DIST openssl-1.0.2.tar.gz 5265809 SHA256 8c48baf3babe0d505d16cfc0cf272589c66d3624264098213db0fb00034728e9 SHA512 dea46225a5445edc4986b02b99fbc90153819374b9a9bfdd892b60cd18ac7fefaf21a7e9d2bb05d0e3bfa4d2704e0ee24b06cc8e7081a542d7598cc9e73c67c5 WHIRLPOOL fe628a38125390deb75728b31427c308efbf65637a569fd1f139f6313fea533514ef05bf3d01bbdc793f77eb259400c95c53074a294d32d73576939d16f22e25
13 17
 DIST openssl-c_rehash.sh.1.7 4167 SHA256 4999ee79892f52bd6a4a7baba9fac62262454d573bbffd72685d3aae9e48cee0 SHA512 55e8c2e827750a4f375cb83c86bfe2d166c01ffa5d7e9b16657b72b38b747c8985dd2c98f854c911dfbbee2ff3e92aff39fdf089d979b2e3534b7685ee8b80da WHIRLPOOL c88f06a3b8651f76b6289552cccceb64e13f6697c5f0ce3ff114c781ce1c218912b8ee308af9d087cd76a9600fdacda1953175bff07d7d3eb21b0c0b7f4f1ce1
14 18
 EBUILD openssl-1.0.1i.ebuild 8776 SHA256 99e7d64748e9448cd1f3d8738e1a97b5daab3c56b3e5f0168186f6644d83bbd8 SHA512 e1b922da0678ac59ed09f4cffd714b45ba8e028aa844e089a4385391fcb4e02b7fc731f855e2537acf10e817710e06aa61fac91233db78a053416212e83a9bf2 WHIRLPOOL 3537527dde49f7fd39c73c7a4053c5bf44fdf3e2544fd7148019729abd01120c7f3fe85e83a38b89630ff0bb38b7d044e42234cfaf4cf68612b630900e5b209a
15 19
 EBUILD openssl-1.0.1j.ebuild 8848 SHA256 823be5d97748b5b7e6f134746f13850b5a97cbf4ad0639c7238367d741386cb6 SHA512 f426b8bcd82113fc27eb001491e2c5ff03f276fd449f3ab763b58e1e5366f75d77eb5bb26648130ed1775e418181cc9d4cc744e507185cb12855b117bd86096c WHIRLPOOL 690246218ae96ec269249c23b65f6ec5f59e3e19388cb2bcd2f1e125fc75ba43124e9f63dc5ea4b0af62fd8aee024a9cff5fddf9ddd123e6fe9dc3a164860c48
16 20
 EBUILD openssl-1.0.1k.ebuild 8848 SHA256 654fb54cb45c343adea6b81d0850a2f9a62c43bd663c3f2d9a402ab90af0f05f SHA512 4372499d07a14131a05f9f62ef99eab1a86b50ab12356d58037e5d7d3754450a6c35947811282ad990c4d1897bc9ce6a4e16bf60ce6926d532e308ad80d28264 WHIRLPOOL 8f4c9224f9637cccb1362a343cfd17cd6b322eb96b15f18f34e2e26c8688d4eb0278a48618eee61e771c65c0d22e11e19a5e81e1fefdca3c9faaca75d74d7930
21
+EBUILD openssl-1.0.2-r1.ebuild 8829 SHA256 b07881d45227d608973c699e146081b2d3d164b741cc127995d2537cc8bb5c95 SHA512 0dbaae39454349726633993ffb71596344b0898cfe420fcc315b07fa0d314e780e9b61a978881b2c091b113523fd0ab37410a771c831b58f8bcd2c67e5c84234 WHIRLPOOL 1b167afb27753e66aa474e23ca2df504e8e3d70d67428af8179e88b238350e988014d8d33f5fe683d4fb345c847b0d954a558b5b69d22836b154c4bc6c15738a
... ...
@@ -0,0 +1,261 @@
1
+# Copyright 1999-2015 Gentoo Foundation
2
+# Distributed under the terms of the GNU General Public License v2
3
+# $Header: /var/cvsroot/gentoo-x86/dev-libs/openssl/openssl-1.0.2-r1.ebuild,v 1.2 2015/01/28 19:35:28 mgorny Exp $
4
+
5
+EAPI="4"
6
+
7
+inherit eutils flag-o-matic toolchain-funcs multilib multilib-minimal
8
+
9
+REV="1.7"
10
+MY_P=${P/_/-}
11
+DESCRIPTION="full-strength general purpose cryptography library (including SSL and TLS)"
12
+HOMEPAGE="http://www.openssl.org/"
13
+SRC_URI="mirror://openssl/source/${MY_P}.tar.gz
14
+	http://cvs.pld-linux.org/cgi-bin/cvsweb.cgi/packages/${PN}/${PN}-c_rehash.sh?rev=${REV} -> ${PN}-c_rehash.sh.${REV}"
15
+
16
+LICENSE="openssl"
17
+SLOT="0"
18
+KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~sparc-fbsd ~x86-fbsd ~arm-linux ~x86-linux"
19
+IUSE="bindist gmp kerberos rfc3779 sctp cpu_flags_x86_sse2 static-libs test +tls-heartbeat vanilla zlib -insecure-ssl2 -insecure-ssl3"
20
+
21
+# The blocks are temporary just to make sure people upgrade to a
22
+# version that lack runtime version checking.  We'll drop them in
23
+# the future.
24
+RDEPEND="gmp? ( >=dev-libs/gmp-5.1.3-r1[static-libs(+)?,${MULTILIB_USEDEP}] )
25
+	zlib? ( >=sys-libs/zlib-1.2.8-r1[static-libs(+)?,${MULTILIB_USEDEP}] )
26
+	kerberos? ( >=app-crypt/mit-krb5-1.11.4[${MULTILIB_USEDEP}] )
27
+	abi_x86_32? (
28
+		!<=app-emulation/emul-linux-x86-baselibs-20140508
29
+		!app-emulation/emul-linux-x86-baselibs[-abi_x86_32(-)]
30
+	)
31
+	!<net-misc/openssh-5.9_p1-r4
32
+	!<net-libs/neon-0.29.6-r1"
33
+DEPEND="${RDEPEND}
34
+	sys-apps/diffutils
35
+	>=dev-lang/perl-5
36
+	sctp? ( net-misc/lksctp-tools )
37
+	test? ( sys-devel/bc )"
38
+PDEPEND="app-misc/ca-certificates"
39
+
40
+S="${WORKDIR}/${MY_P}"
41
+
42
+MULTILIB_WRAPPED_HEADERS=(
43
+	usr/include/openssl/opensslconf.h
44
+)
45
+
46
+src_prepare() {
47
+	SSL_CNF_DIR="/etc/ssl"
48
+	sed \
49
+		-e "/^DIR=/s:=.*:=${EPREFIX}${SSL_CNF_DIR}:" \
50
+		-e "s:SSL_CMD=/usr:SSL_CMD=${EPREFIX}/usr:" \
51
+		"${DISTDIR}"/${PN}-c_rehash.sh.${REV} \
52
+		> "${WORKDIR}"/c_rehash || die #416717
53
+
54
+	# Make sure we only ever touch Makefile.org and avoid patching a file
55
+	# that gets blown away anyways by the Configure script in src_configure
56
+	rm -f Makefile
57
+
58
+	if ! use vanilla ; then
59
+		epatch "${FILESDIR}"/${PN}-1.0.0a-ldflags.patch #327421
60
+		epatch "${FILESDIR}"/${PN}-1.0.0d-windres.patch #373743
61
+		epatch "${FILESDIR}"/${PN}-1.0.2-parallel-build.patch
62
+		epatch "${FILESDIR}"/${PN}-1.0.2-ipv6.patch
63
+		epatch "${FILESDIR}"/${PN}-1.0.2-s_client-verify.patch #472584
64
+
65
+		epatch_user #332661
66
+	fi
67
+
68
+	# disable fips in the build
69
+	# make sure the man pages are suffixed #302165
70
+	# don't bother building man pages if they're disabled
71
+	sed -i \
72
+		-e '/DIRS/s: fips : :g' \
73
+		-e '/^MANSUFFIX/s:=.*:=ssl:' \
74
+		-e '/^MAKEDEPPROG/s:=.*:=$(CC):' \
75
+		-e $(has noman FEATURES \
76
+			&& echo '/^install:/s:install_docs::' \
77
+			|| echo '/^MANDIR=/s:=.*:='${EPREFIX}'/usr/share/man:') \
78
+		Makefile.org \
79
+		|| die
80
+	# show the actual commands in the log
81
+	sed -i '/^SET_X/s:=.*:=set -x:' Makefile.shared
82
+
83
+	# since we're forcing $(CC) as makedep anyway, just fix
84
+	# the conditional as always-on
85
+	# helps clang (#417795), and versioned gcc (#499818)
86
+	sed -i 's/expr.*MAKEDEPEND.*;/true;/' util/domd || die
87
+
88
+	# quiet out unknown driver argument warnings since openssl
89
+	# doesn't have well-split CFLAGS and we're making it even worse
90
+	# and 'make depend' uses -Werror for added fun (#417795 again)
91
+	[[ ${CC} == *clang* ]] && append-flags -Qunused-arguments
92
+
93
+	# allow openssl to be cross-compiled
94
+	cp "${FILESDIR}"/gentoo.config-1.0.1 gentoo.config || die
95
+	chmod a+rx gentoo.config
96
+
97
+	append-flags -fno-strict-aliasing
98
+	append-flags $(test-flags-CC -Wa,--noexecstack)
99
+	append-cppflags -DOPENSSL_NO_BUF_FREELISTS
100
+
101
+	sed -i '1s,^:$,#!'${EPREFIX}'/usr/bin/perl,' Configure #141906
102
+	# The config script does stupid stuff to prompt the user.  Kill it.
103
+	sed -i '/stty -icanon min 0 time 50; read waste/d' config || die
104
+	./config --test-sanity || die "I AM NOT SANE"
105
+
106
+	multilib_copy_sources
107
+}
108
+
109
+multilib_src_configure() {
110
+	unset APPS #197996
111
+	unset SCRIPTS #312551
112
+	unset CROSS_COMPILE #311473
113
+
114
+	tc-export CC AR RANLIB RC
115
+
116
+	# Clean out patent-or-otherwise-encumbered code
117
+	# Camellia: Royalty Free            http://en.wikipedia.org/wiki/Camellia_(cipher)
118
+	# IDEA:     Expired                 http://en.wikipedia.org/wiki/International_Data_Encryption_Algorithm
119
+	# EC:       ????????? ??/??/2015    http://en.wikipedia.org/wiki/Elliptic_Curve_Cryptography
120
+	# MDC2:     Expired                 http://en.wikipedia.org/wiki/MDC-2
121
+	# RC5:      5,724,428 03/03/2015    http://en.wikipedia.org/wiki/RC5
122
+
123
+	use_ssl() { usex $1 "enable-${2:-$1}" "no-${2:-$1}" " ${*:3}" ; }
124
+	echoit() { echo "$@" ; "$@" ; }
125
+
126
+	local krb5=$(has_version app-crypt/mit-krb5 && echo "MIT" || echo "Heimdal")
127
+
128
+	# See if our toolchain supports __uint128_t.  If so, it's 64bit
129
+	# friendly and can use the nicely optimized code paths. #460790
130
+	local ec_nistp_64_gcc_128
131
+	# Disable it for now though #469976
132
+	#if ! use bindist ; then
133
+	#	echo "__uint128_t i;" > "${T}"/128.c
134
+	#	if ${CC} ${CFLAGS} -c "${T}"/128.c -o /dev/null >&/dev/null ; then
135
+	#		ec_nistp_64_gcc_128="enable-ec_nistp_64_gcc_128"
136
+	#	fi
137
+	#fi
138
+
139
+	local sslout=$(./gentoo.config)
140
+	einfo "Use configuration ${sslout:-(openssl knows best)}"
141
+	local config="Configure"
142
+	[[ -z ${sslout} ]] && config="config"
143
+
144
+	echoit \
145
+	./${config} \
146
+		${sslout} \
147
+		$(use sctp && echo "sctp") \
148
+		$(use cpu_flags_x86_sse2 || echo "no-sse2") \
149
+		enable-camellia \
150
+		$(use_ssl !bindist ec) \
151
+		${ec_nistp_64_gcc_128} \
152
+		enable-idea \
153
+		enable-mdc2 \
154
+		$(use_ssl !bindist rc5) \
155
+		enable-tlsext \
156
+		$(use_ssl gmp gmp -lgmp) \
157
+		$(use_ssl kerberos krb5 --with-krb5-flavor=${krb5}) \
158
+		$(use_ssl rfc3779) \
159
+		$(use_ssl tls-heartbeat heartbeats) \
160
+		$(use_ssl zlib) \
161
+		$(use_ssl insecure-ssl2 ssl2) \
162
+		$(use_ssl insecure-ssl3 ssl3) \
163
+		--prefix="${EPREFIX}"/usr \
164
+		--openssldir="${EPREFIX}"${SSL_CNF_DIR} \
165
+		--libdir=$(get_libdir) \
166
+		shared threads \
167
+		|| die
168
+
169
+	# Clean out hardcoded flags that openssl uses
170
+	local CFLAG=$(grep ^CFLAG= Makefile | LC_ALL=C sed \
171
+		-e 's:^CFLAG=::' \
172
+		-e 's:-fomit-frame-pointer ::g' \
173
+		-e 's:-O[0-9] ::g' \
174
+		-e 's:-march=[-a-z0-9]* ::g' \
175
+		-e 's:-mcpu=[-a-z0-9]* ::g' \
176
+		-e 's:-m[a-z0-9]* ::g' \
177
+	)
178
+	sed -i \
179
+		-e "/^CFLAG/s|=.*|=${CFLAG} ${CFLAGS}|" \
180
+		-e "/^SHARED_LDFLAGS=/s|$| ${LDFLAGS}|" \
181
+		Makefile || die
182
+}
183
+
184
+multilib_src_compile() {
185
+	# depend is needed to use $confopts; it also doesn't matter
186
+	# that it's -j1 as the code itself serializes subdirs
187
+	emake -j1 depend
188
+	emake all
189
+	# rehash is needed to prep the certs/ dir; do this
190
+	# separately to avoid parallel build issues.
191
+	emake rehash
192
+}
193
+
194
+multilib_src_test() {
195
+	emake -j1 test
196
+}
197
+
198
+multilib_src_install() {
199
+	emake INSTALL_PREFIX="${D}" install
200
+}
201
+
202
+multilib_src_install_all() {
203
+	dobin "${WORKDIR}"/c_rehash #333117
204
+	dodoc CHANGES* FAQ NEWS README doc/*.txt doc/c-indentation.el
205
+	dohtml -r doc/*
206
+	use rfc3779 && dodoc engines/ccgost/README.gost
207
+
208
+	# This is crappy in that the static archives are still built even
209
+	# when USE=static-libs.  But this is due to a failing in the openssl
210
+	# build system: the static archives are built as PIC all the time.
211
+	# Only way around this would be to manually configure+compile openssl
212
+	# twice; once with shared lib support enabled and once without.
213
+	use static-libs || rm -f "${ED}"/usr/lib*/lib*.a
214
+
215
+	# create the certs directory
216
+	dodir ${SSL_CNF_DIR}/certs
217
+	cp -RP certs/* "${ED}"${SSL_CNF_DIR}/certs/ || die
218
+	rm -r "${ED}"${SSL_CNF_DIR}/certs/{demo,expired}
219
+
220
+	# Namespace openssl programs to prevent conflicts with other man pages
221
+	cd "${ED}"/usr/share/man
222
+	local m d s
223
+	for m in $(find . -type f | xargs grep -L '#include') ; do
224
+		d=${m%/*} ; d=${d#./} ; m=${m##*/}
225
+		[[ ${m} == openssl.1* ]] && continue
226
+		[[ -n $(find -L ${d} -type l) ]] && die "erp, broken links already!"
227
+		mv ${d}/{,ssl-}${m}
228
+		# fix up references to renamed man pages
229
+		sed -i '/^[.]SH "SEE ALSO"/,/^[.]/s:\([^(, ]*(1)\):ssl-\1:g' ${d}/ssl-${m}
230
+		ln -s ssl-${m} ${d}/openssl-${m}
231
+		# locate any symlinks that point to this man page ... we assume
232
+		# that any broken links are due to the above renaming
233
+		for s in $(find -L ${d} -type l) ; do
234
+			s=${s##*/}
235
+			rm -f ${d}/${s}
236
+			ln -s ssl-${m} ${d}/ssl-${s}
237
+			ln -s ssl-${s} ${d}/openssl-${s}
238
+		done
239
+	done
240
+	[[ -n $(find -L ${d} -type l) ]] && die "broken manpage links found :("
241
+
242
+	dodir /etc/sandbox.d #254521
243
+	echo 'SANDBOX_PREDICT="/dev/crypto"' > "${ED}"/etc/sandbox.d/10openssl
244
+
245
+	diropts -m0700
246
+	keepdir ${SSL_CNF_DIR}/private
247
+}
248
+
249
+pkg_preinst() {
250
+	has_version ${CATEGORY}/${PN}:0.9.8 && return 0
251
+	preserve_old_lib /usr/$(get_libdir)/lib{crypto,ssl}.so.0.9.8
252
+}
253
+
254
+pkg_postinst() {
255
+	ebegin "Running 'c_rehash ${EROOT%/}${SSL_CNF_DIR}/certs/' to rebuild hashes #333069"
256
+	c_rehash "${EROOT%/}${SSL_CNF_DIR}/certs" >/dev/null
257
+	eend $?
258
+
259
+	has_version ${CATEGORY}/${PN}:0.9.8 && return 0
260
+	preserve_old_lib_notify /usr/$(get_libdir)/lib{crypto,ssl}.so.0.9.8
261
+}
0 262