--- openssl-0.9.8o.ebuild 2010-07-14 14:51:12.000000000 +0300 +++ openssl-0.9.8o.ebuild 2010-07-15 10:18:43.000000000 +0300 @@ -9,8 +9,8 @@ SRC_URI="mirror://openssl/source/${P}.tar.gz" LICENSE="openssl" -SLOT="0" -KEYWORDS="alpha amd64 arm hppa ia64 m68k ~mips ppc ppc64 s390 sh sparc x86 ~sparc-fbsd ~x86-fbsd" +SLOT="0.9.8" +KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~sparc-fbsd ~x86-fbsd" IUSE="bindist gmp kerberos sse2 test zlib" RDEPEND="gmp? ( dev-libs/gmp ) @@ -22,6 +22,12 @@ test? ( sys-devel/bc )" PDEPEND="app-misc/ca-certificates" +pkg_setup() { + if [[ -e ${ROOT}/usr/$(get_libdir)/lib{crypto,ssl}.so.0.9.8 ]]; then + rm -f "${ROOT}"/usr/$(get_libdir)/lib{crypto,ssl}.so.0.9.8 + fi +} + src_unpack() { unpack ${A} cd "${S}" @@ -124,48 +130,5 @@ } src_install() { - emake -j1 INSTALL_PREFIX="${D}" install || die - dodoc CHANGES* FAQ NEWS README doc/*.txt doc/c-indentation.el - dohtml -r doc/* - - # create the certs directory - dodir /etc/ssl/certs - cp -RP certs/* "${D}"/etc/ssl/certs/ || die "failed to install certs" - rm -r "${D}"/etc/ssl/certs/{demo,expired} - - # Namespace openssl programs to prevent conflicts with other man pages - cd "${D}"/usr/share/man - local m d s - for m in $(find . -type f | xargs grep -L '#include') ; do - d=${m%/*} ; d=${d#./} ; m=${m##*/} - # fix up references to renamed man pages - sed -i '/^[.]SH "SEE ALSO"/,/^[.][^I]/s:\([^(, I]*([15])\):ssl-\1:g' ${d}/${m} - [[ ${m} == openssl.1* ]] && continue - [[ -n $(find -L ${d} -type l) ]] && die "erp, broken links already!" - mv ${d}/{,ssl-}${m} - ln -s ssl-${m} ${d}/openssl-${m} - # locate any symlinks that point to this man page ... we assume - # that any broken links are due to the above renaming - for s in $(find -L ${d} -type l) ; do - s=${s##*/} - rm -f ${d}/${s} - ln -s ssl-${m} ${d}/ssl-${s} - ln -s ssl-${s} ${d}/openssl-${s} - done - done - [[ -n $(find -L ${d} -type l) ]] && die "broken manpage links found :(" - - dodir /etc/sandbox.d #254521 - echo 'SANDBOX_PREDICT="/dev/crypto"' > "${D}"/etc/sandbox.d/10openssl - - diropts -m0700 - keepdir /etc/ssl/private -} - -pkg_preinst() { - preserve_old_lib /usr/$(get_libdir)/lib{crypto,ssl}.so.0.9.{6,7} -} - -pkg_postinst() { - preserve_old_lib_notify /usr/$(get_libdir)/lib{crypto,ssl}.so.0.9.{6,7} + dolib.so lib{crypto,ssl}.so.0.9.8 || die }