diff options
author | Daniel Ahlberg <aliz@gentoo.org> | 2004-06-15 18:48:40 +0000 |
---|---|---|
committer | Daniel Ahlberg <aliz@gentoo.org> | 2004-06-15 18:48:40 +0000 |
commit | ecd34dccb4cebfd75132aa276de7e1d27fc510ca (patch) | |
tree | f69cc1ccfec869b1dc4a8ace1abc9e989f631d1e /dev-libs/openssl | |
parent | Add ~amd64, fixes bug #53110 (Manifest recommit) (diff) | |
download | gentoo-2-ecd34dccb4cebfd75132aa276de7e1d27fc510ca.tar.gz gentoo-2-ecd34dccb4cebfd75132aa276de7e1d27fc510ca.tar.bz2 gentoo-2-ecd34dccb4cebfd75132aa276de7e1d27fc510ca.zip |
Closing #50440 and #48475.
Diffstat (limited to 'dev-libs/openssl')
-rw-r--r-- | dev-libs/openssl/ChangeLog | 11 | ||||
-rw-r--r-- | dev-libs/openssl/files/digest-openssl-0.9.7d-r1 | 2 | ||||
-rw-r--r-- | dev-libs/openssl/files/openssl-0.9.7d-smime.patch | 22 | ||||
-rw-r--r-- | dev-libs/openssl/openssl-0.9.7d-r1.ebuild | 263 | ||||
-rw-r--r-- | dev-libs/openssl/openssl-0.9.7d.ebuild | 4 |
5 files changed, 299 insertions, 3 deletions
diff --git a/dev-libs/openssl/ChangeLog b/dev-libs/openssl/ChangeLog index 86cd8634de1f..e77680924a7c 100644 --- a/dev-libs/openssl/ChangeLog +++ b/dev-libs/openssl/ChangeLog @@ -1,10 +1,19 @@ # ChangeLog for dev-libs/openssl # Copyright 2002-2004 Gentoo Technologies, Inc.; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/dev-libs/openssl/ChangeLog,v 1.83 2004/06/15 06:32:44 solar Exp $ +# $Header: /var/cvsroot/gentoo-x86/dev-libs/openssl/ChangeLog,v 1.84 2004/06/15 18:48:40 aliz Exp $ + + 15 Jun 2004; Daniel Ahlberg <aliz@gentoo.org> openssl-0.9.7d-r1.ebuild, + openssl-0.9.7d.ebuild: + Fall back to single thread make if parallell fails. Hopefully closing #48475. 15 Jun 2004; <solar@gentoo.org> openssl-0.9.7d.ebuild: remove dep of bc when uclibc is used +*openssl-0.9.7d-r1 (14 Jun 2004) + + 14 Jun 2004; Daniel Ahlberg <aliz@gentoo.org> openssl-0.9.7d-r1.ebuild, + Add smime patch from CVS, closing #50440. + 06 Jun 2004; Aron Griffis <agriffis@gentoo.org> openssl-0.9.7c-r1.ebuild, openssl-0.9.7d.ebuild: Fix use invocation diff --git a/dev-libs/openssl/files/digest-openssl-0.9.7d-r1 b/dev-libs/openssl/files/digest-openssl-0.9.7d-r1 new file mode 100644 index 000000000000..53244e8e53f6 --- /dev/null +++ b/dev-libs/openssl/files/digest-openssl-0.9.7d-r1 @@ -0,0 +1,2 @@ +MD5 1b49e90fc8a75c3a507c0a624529aca5 openssl-0.9.7d.tar.gz 2798433 +MD5 1b63bfdca1c37837dddde9f1623498f9 openssl-0.9.6m.tar.gz 2184918 diff --git a/dev-libs/openssl/files/openssl-0.9.7d-smime.patch b/dev-libs/openssl/files/openssl-0.9.7d-smime.patch new file mode 100644 index 000000000000..6ccc8c3e980c --- /dev/null +++ b/dev-libs/openssl/files/openssl-0.9.7d-smime.patch @@ -0,0 +1,22 @@ +--- crypto/pkcs7/pk7_doit.c 2003/11/03 00:06:02 1.50.2.4.2.1 ++++ crypto/pkcs7/pk7_doit.c 2004/03/25 00:58:59 1.50.2.4.2.2 +@@ -257,10 +257,15 @@ + bio=BIO_new(BIO_s_null()); + else + { +- ASN1_OCTET_STRING *os; +- os = PKCS7_get_octet_string(p7->d.sign->contents); +- if (os && os->length > 0) +- bio = BIO_new_mem_buf(os->data, os->length); ++ if (PKCS7_type_is_signed(p7)) ++ { ++ ASN1_OCTET_STRING *os; ++ os = PKCS7_get_octet_string( ++ p7->d.sign->contents); ++ if (os && os->length > 0) ++ bio = BIO_new_mem_buf(os->data, ++ os->length); ++ } + if(bio == NULL) + { + bio=BIO_new(BIO_s_mem()); diff --git a/dev-libs/openssl/openssl-0.9.7d-r1.ebuild b/dev-libs/openssl/openssl-0.9.7d-r1.ebuild new file mode 100644 index 000000000000..79ed614981fc --- /dev/null +++ b/dev-libs/openssl/openssl-0.9.7d-r1.ebuild @@ -0,0 +1,263 @@ +# Copyright 1999-2004 Gentoo Technologies, Inc. +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/dev-libs/openssl/openssl-0.9.7d-r1.ebuild,v 1.1 2004/06/15 18:48:40 aliz Exp $ + +inherit eutils flag-o-matic gcc + +OLD_096_P="${PN}-0.9.6m" + +DESCRIPTION="Toolkit for SSL v2/v3 and TLS v1" +HOMEPAGE="http://www.openssl.org/" +SRC_URI="mirror://openssl/source/${P}.tar.gz + mirror://openssl/source/${OLD_096_P}.tar.gz" + +LICENSE="as-is" +SLOT="0" +KEYWORDS="x86 ppc sparc mips alpha arm hppa amd64 ia64 ppc64 s390" +IUSE="emacs" + +RDEPEND="virtual/glibc" +DEPEND="${RDEPEND} + >=dev-lang/perl-5 + >=sys-apps/sed-4 + sys-devel/bc" + +S=${WORKDIR} + +src_unpack() { + unpack ${A} + + # openssl-0.9.7 + cd ${WORKDIR}/${P} + + if [ "${ARCH}" = "ppc64" ]; then + epatch ${FILESDIR}/addppc64support.diff + fi + + epatch ${FILESDIR}/${P}-gentoo.diff + epatch ${FILESDIR}/${P}-smime.patch + + if [ "${ARCH}" = "hppa" ]; then + # Tells to compile a static version of openssl + sed -i -e \ + 's!^"linux-parisc"\(.*\)::BN\(.*\)::!"linux-parisc"\1:-ldl:BN\2::::::::::dlfcn:linux-shared:-fPIC::.so.\\$(SHLIB_MAJOR).\\$(SHLIB_MINOR)!' \ + Configure + # Fix detection of parisc running 64 bit kernel + sed -i -e 's/parisc-\*-linux2/parisc\*-\*-linux2/' config + fi + if [ "${ARCH}" = "arm" ]; then + # patch linker to add -ldl or things linking aginst libcrypto fail + sed -i -e \ + 's!^"linux-elf-arm"\(.*\)::BN\(.*\)!"linux-elf-arm"\1:-ldl:BN\2!' \ + Configure + fi + + if [ "${ARCH}" = "alpha" -a "${CC}" != "ccc" ]; then + # ccc compiled openssl will break things linked against + # a gcc compiled openssl, the configure will automatically detect + # ccc and use it, so stop that if user hasnt asked for it. + sed -i -e \ + 's!CC=ccc!CC=gcc!' config + fi + + case $( gcc-version ) in + 3.2 ) + filter-flags -fprefetch-loop-arrays -freduce-all-givs -funroll-loop ;; + 3.4 | 3.3 ) + filter-flags -fprefetch-loop-arrays -freduce-all-givs -funroll-loops + if [ "${ARCH}" = "ppc" -o "${ARCH}" = "ppc64" ]; then + append-flags -fno-strict-aliasing + fi + ;; + esac + + # replace CFLAGS + OLDIFS=$IFS + IFS=" +" + for a in $( grep -n -e "^\"linux-" Configure ); do + LINE=$( echo $a | awk -F: '{print $1}' ) + CUR_CFLAGS=$( echo $a | awk -F: '{print $3}' ) + # for ppc64 I have to be careful given current + # toolchain issues + if [ "${ARCH}" != "ppc64" ]; then + NEW_CFLAGS="$( echo $CUR_CFLAGS | sed -r -e "s|-O[23]||" -e "s/-fomit-frame-pointer//" -e "s/-mcpu=[-a-z0-9]+//" -e "s/-m486//" ) $CFLAGS" + else + NEW_CFLAGS="$( echo $CUR_CFLAGS | sed -r -e "s|-O[23]||" -e "s/-fomit-frame-pointer//" -e "s/-mcpu=[-a-z0-9]+//" -e "s/-m486//" ) " + + fi + + sed -i "${LINE}s/$CUR_CFLAGS/$NEW_CFLAGS/" Configure + done + IFS=$OLDIFS + + # openssl-0.9.6 + test -f ${ROOT}/usr/lib/libssl.so.0.9.6 && { + cd ${WORKDIR}/${OLD_096_P} + + epatch ${FILESDIR}/${OLD_096_P}-gentoo.diff + + case ${ARCH} in + mips) + epatch ${FILESDIR}/openssl-0.9.6-mips.diff + ;; + arm) + # patch linker to add -ldl or things linking aginst libcrypto fail + sed -i -e \ + 's!^"linux-elf-arm"\(.*\)::BN\(.*\)!"linux-elf-arm"\1:-ldl:BN\2!' \ + Configure + ;; + hppa) + # Tells to compile a static version of openssl + sed -i -e \ + 's!^"linux-parisc"\(.*\)::BN\(.*\)::!"linux-parisc"\1:-ldl:BN\2::::::::::dlfcn:linux-shared:-fPIC::.so.\\$(SHLIB_MAJOR).\\$(SHLIB_MINOR)!' \ + Configure + # Fix detection of parisc running 64 bit kernel + sed -i -e 's/parisc-\*-linux2/parisc\*-\*-linux2/' config + esac + + # replace CFLAGS + OLDIFS=$IFS + IFS=" +" + for a in $( grep -n -e "^\"linux-" Configure ); do + LINE=$( echo $a | awk -F: '{print $1}' ) + CUR_CFLAGS=$( echo $a | awk -F: '{print $3}' ) + NEW_CFLAGS="$( echo $CUR_CFLAGS | sed -r -e "s|-O[23]||" -e "s/-fomit-frame-pointer//" -e "s/-mcpu=[-a-z0-9]+//" -e "s/-m486//" ) $CFLAGS" + sed -i "${LINE}s/$CUR_CFLAGS/$NEW_CFLAGS/" Configure + done + IFS=$OLDIFS + } +} + +src_compile() { + # openssl-0.9.7 + cd ${WORKDIR}/${P} + + # Build correctly for mips, mips64, & mipsel + if use mips; then + if [ "`echo ${CHOST} | grep "mipsel"`" ]; then + mipsarch="linux-mipsel" + else + mipsarch="linux-mips" + fi + + ./Configure ${mipsarch} --prefix=/usr --openssldir=/etc/ssl \ + shared threads || die + # We have to force the target for hppa because detection + # is broken on SMP box + elif [ "`uname -m`" = "parisc" -o "`uname -m`" = "parisc64" ]; then + ./Configure linux-parisc --prefix=/usr --openssldir=/etc/ssl \ + shared threads || die + # force sparcv8 on sparc32 profile + elif [ "$PROFILE_ARCH" = "sparc" ]; then + ./Configure linux-sparcv8 --prefix=/usr --openssldir=/etc/ssl \ + shared threads || die + else + ./config --prefix=/usr --openssldir=/etc/ssl shared threads || die + fi + + einfo "Compiling ${P}" + emake all || make all || die + make test || die + + # openssl-0.9.6 + test -f ${ROOT}/usr/lib/libssl.so.0.9.6 && { + cd ${WORKDIR}/${OLD_096_P} + + # force sparcv8 on sparc32 profile + if [ "$PROFILE_ARCH" = "sparc" ]; then + SSH_TARGET="linux-sparcv8" + elif [ "`uname -m`" = "parisc" -o "`uname -m`" = "parisc64" ]; then + SSH_TARGET="linux-parisc" + elif use mips; then + if [ "`echo ${CHOST} | grep "mipsel"`" ]; then + SSH_TARGET="linux-mipsel" + else + SSH_TARGET="linux-mips" + fi + fi + + case ${CHOST} in + alphaev56*|alphaev6*) + SSH_TARGET="linux-alpha+bwx-${CC:-gcc}" + ;; + alpha*) + SSH_TARGET="linux-alpha-${CC:-gcc}" ;; + esac + + if [ ${SSH_TARGET} ]; then + einfo "Forcing ${SSH_TARGET} compile" + ./Configure ${SSH_TARGET} --prefix=/usr \ + --openssldir=/etc/ssl shared threads || die + else + ./config --prefix=/usr --openssldir=/etc/ssl shared threads || die + fi + + einfo "Compiling ${OLD_096_P}" + make all || die + make test || die + } +} + +src_install() { + # openssl-0.9.7 + cd ${WORKDIR}/${P} + make INSTALL_PREFIX=${D} MANDIR=/usr/share/man install || die + dodoc CHANGES* FAQ LICENSE NEWS README + dodoc doc/*.txt + dohtml doc/* + insinto /usr/share/emacs/site-lisp + doins doc/c-indentation.el + + if use emacs ; then + insinto /usr/share/emacs/site-lisp + doins doc/c-indentation.el + fi + + # create the certs directory. Previous openssl builds + # would need to create /usr/lib/ssl/certs but this looks + # to be the more FHS compliant setup... -raker + insinto /etc/ssl/certs + doins certs/*.pem + OPENSSL=${D}/usr/bin/openssl /usr/bin/perl tools/c_rehash ${D}/etc/ssl/certs + + # The man pages rand.3 and passwd.1 conflict with other packages + # Rename them to ssl-* and also make a symlink from openssl-* to ssl-* + cd ${D}/usr/share/man/man1 + mv passwd.1 ssl-passwd.1 + ln -sf ssl-passwd.1 openssl-passwd.1 + cd ${D}/usr/share/man/man3 + mv rand.3 ssl-rand.3 + ln -sf ssl-rand.3 openssl-rand.3 + + # openssl-0.9.6 + test -f ${ROOT}/usr/lib/libssl.so.0.9.6 && { + cd ${WORKDIR}/${OLD_096_P} + make || die + dolib.so ${WORKDIR}/${OLD_096_P}/libcrypto.so.0.9.6||die "libcrypto.so.0.9.6 not found" + dolib.so ${WORKDIR}/${OLD_096_P}/libssl.so.0.9.6|| die "libssl.so.0.9.6 not found" + } + + fperms a+x /usr/lib/pkgconfig #34088 +} + +pkg_postinst() { + local BN_H="${ROOT}$(gcc-config -L)/include/openssl/bn.h" + # Breaks things one some boxen, bug #13795. The problem is that + # if we have a 'gcc fixed' version in $(gcc-config -L) from 0.9.6, + # then breaks as it was defined as 'int BN_mod(...)' and in 0.9.7 it + # is a define with BN_div(...) - <azarah@gentoo.org> (24 Sep 2003) + if [ -f "${BN_H}" ] && [ -n "$(grep '^int[[:space:]]*BN_mod(' "${BN_H}")" ] + then + rm -f "${BN_H}" + fi + + test -f ${ROOT}/usr/lib/libssl.so.0.9.6 && { + einfo "You can now re-compile all packages that are linked against" + einfo "OpenSSL 0.9.6 by using revdep-rebuild from gentoolkit:" + einfo "# revdep-rebuild --soname libssl.so.0.9.6" + einfo "# revdep-rebuild --soname libcrypto.so.0.9.6" + einfo "After this, you can delete /usr/lib/libssl.so.0.9.6 and /usr/lib/libcrypto.so.0.9.6" + } +} diff --git a/dev-libs/openssl/openssl-0.9.7d.ebuild b/dev-libs/openssl/openssl-0.9.7d.ebuild index bca39b3a08f1..a034cd8f5489 100644 --- a/dev-libs/openssl/openssl-0.9.7d.ebuild +++ b/dev-libs/openssl/openssl-0.9.7d.ebuild @@ -1,6 +1,6 @@ # Copyright 1999-2004 Gentoo Technologies, Inc. # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/dev-libs/openssl/openssl-0.9.7d.ebuild,v 1.13 2004/06/15 06:32:44 solar Exp $ +# $Header: /var/cvsroot/gentoo-x86/dev-libs/openssl/openssl-0.9.7d.ebuild,v 1.14 2004/06/15 18:48:40 aliz Exp $ inherit eutils flag-o-matic gcc @@ -157,7 +157,7 @@ src_compile() { fi einfo "Compiling ${P}" - emake all || die + emake all || make all || die make test || die # openssl-0.9.6 |