diff options
author | Fantix King | 2012-10-29 08:00:46 +0000 |
---|---|---|
committer | Fantix King | 2015-11-07 16:08:50 +0800 |
commit | a4e48edab6a9b33f63006b7be45fd87f808a61bc (patch) | |
tree | b59425c6bab3b5d2402e96befac1749fce5f8809 | |
parent | 787c35e7f613bda2c18372edc700bc39d94a0912 (diff) | |
download | aur-a4e48edab6a9b33f63006b7be45fd87f808a61bc.tar.gz |
1.0.1.c-1.2
-rw-r--r-- | .SRCINFO | 5 | ||||
-rw-r--r-- | PKGBUILD | 15 | ||||
-rw-r--r-- | libx32-openssl.install | 21 | ||||
-rw-r--r-- | opensslconf-stub.h | 13 |
4 files changed, 50 insertions, 4 deletions
@@ -1,7 +1,7 @@ pkgbase = libx32-openssl pkgdesc = The Open Source toolkit for Secure Sockets Layer and Transport Layer Security (x32 ABI) pkgver = 1.0.1.c - pkgrel = 1.1 + pkgrel = 1.2 url = https://www.openssl.org arch = x86_64 license = custom:BSD @@ -15,11 +15,14 @@ pkgbase = libx32-openssl source = no-rpath.patch source = ca-dir.patch source = openssl-1.0.1-x32.patch + source = opensslconf-stub.h md5sums = ae412727c8c15b67880aef7bd2999b2e md5sums = a3d90bc42253def61cd1c4237f1ce5f7 md5sums = dc78d3d06baffc16217519242ce92478 md5sums = 3bf51be3a1bbd262be46dc619f92aa90 md5sums = 10d0cebf2d9c0f64c307e82542f519e3 + md5sums = dbb0b2e285f9ba95f189a0eaf3586011 pkgname = libx32-openssl + install = libx32-openssl.install @@ -1,5 +1,6 @@ # $Id: PKGBUILD 70628 2012-05-13 11:42:39Z bluewind $ -# Maintainer: Pierre Schmitz <pierre@archlinux.de> +# Upstream Maintainer: Pierre Schmitz <pierre@archlinux.de> +# Maintainer: Fantix King <fantix.king at gmail.com> _pkgbasename=openssl pkgname=libx32-$_pkgbasename @@ -8,7 +9,7 @@ _ver=1.0.1c pkgver=1.0.1.c true && pkgver=${_ver/[a-z]/.${_ver//[0-9.]/}} #pkgver=$_ver -pkgrel=1.1 +pkgrel=1.2 pkgdesc='The Open Source toolkit for Secure Sockets Layer and Transport Layer Security (x32 ABI)' arch=('x86_64') url='https://www.openssl.org' @@ -22,12 +23,14 @@ source=("https://www.openssl.org/source/${_pkgbasename}-${_ver}.tar.gz" 'no-rpath.patch' 'ca-dir.patch' 'openssl-1.0.1-x32.patch' + 'opensslconf-stub.h' ) md5sums=('ae412727c8c15b67880aef7bd2999b2e' 'a3d90bc42253def61cd1c4237f1ce5f7' 'dc78d3d06baffc16217519242ce92478' '3bf51be3a1bbd262be46dc619f92aa90' - '10d0cebf2d9c0f64c307e82542f519e3') + '10d0cebf2d9c0f64c307e82542f519e3' + 'dbb0b2e285f9ba95f189a0eaf3586011') build() { export CC="gcc -mx32" @@ -65,10 +68,16 @@ check() { } package() { + install="${pkgname}.install" + cd $srcdir/$_pkgbasename-$_ver make INSTALL_PREFIX=$pkgdir install + mv "${pkgdir}/usr/include/openssl/opensslconf.h" "${srcdir}/opensslconf-x32.h" rm -rf ${pkgdir}/{usr/{include,share,bin},etc} + install -Dm644 "${srcdir}/opensslconf-x32.h" "${pkgdir}/usr/include/openssl/opensslconf-x32.h" + install -Dm644 "${srcdir}/opensslconf-stub.h" "${pkgdir}/usr/include/openssl/opensslconf-stub.h" + mkdir -p $pkgdir/usr/share/licenses ln -s $_pkgbasename $pkgdir/usr/share/licenses/$pkgname } diff --git a/libx32-openssl.install b/libx32-openssl.install new file mode 100644 index 000000000000..860d03582bca --- /dev/null +++ b/libx32-openssl.install @@ -0,0 +1,21 @@ +post_install() { + mv /usr/include/openssl/opensslconf.h /usr/include/openssl/opensslconf-64.h + ln -s opensslconf-stub.h /usr/include/openssl/opensslconf.h +} + +post_upgrade() { + if [ ! -L /usr/include/openssl/opensslconf.h ]; then + post_install + elif [ ${1::-2} != ${2::-2} ]; then + echo WARNING: libx32-openssl is upgraded before openssl, + echo WARNING: you probably need to reinstall libx32-openssl. + fi +} + +post_remove() { + if [ -L /usr/include/openssl/opensslconf.h ]; then + rm /usr/include/openssl/opensslconf.h + mv /usr/include/openssl/opensslconf-64.h /usr/include/openssl/opensslconf.h + fi +} + diff --git a/opensslconf-stub.h b/opensslconf-stub.h new file mode 100644 index 000000000000..bfecf37ec935 --- /dev/null +++ b/opensslconf-stub.h @@ -0,0 +1,13 @@ +// This is replaced by libx32-openssl. +// Old file is renamed to opensslconf-64.h. + +#if !defined __x86_64__ +# include "opensslconf-64.h" // lib32-openssl did not deliver opensslconf-32.h yet +#endif +#if defined __x86_64__ && defined __LP64__ +# include "opensslconf-64.h" +#endif +#if defined __x86_64__ && defined __ILP32__ +# include "opensslconf-x32.h" +#endif + |