OCaml 5.0.0 rebuild: Fix Pervasives deprecation
[arch-packages.git] / openssl / trunk / PKGBUILD
blob3b9e5c1157aa73a57f19de0e3853595d94327292
1 # Maintainer: Pierre Schmitz <pierre@archlinux.de>
3 pkgname=openssl
4 pkgver=3.0.8
5 pkgrel=1
6 pkgdesc='The Open Source toolkit for Secure Sockets Layer and Transport Layer Security'
7 arch=('x86_64')
8 url='https://www.openssl.org'
9 license=('Apache')
10 depends=('glibc')
11 makedepends=('perl')
12 optdepends=('ca-certificates' 'perl')
13 replaces=('openssl-perl' 'openssl-doc')
14 provides=('libcrypto.so' 'libssl.so')
15 backup=('etc/ssl/openssl.cnf')
16 source=("https://www.openssl.org/source/${pkgname}-${pkgver}.tar.gz"{,.asc}
17         'ca-dir.patch')
18 sha256sums=('6c13d2bf38fdf31eac3ce2a347073673f5d63263398f1f69d0df4a41253e4b3e'
19             'SKIP'
20             '0a32d9ca68e8d985ce0bfef6a4c20b46675e06178cc2d0bf6d91bd6865d648b7')
21 validpgpkeys=('8657ABB260F056B1E5190839D9C4D26D0E604491'
22               '7953AC1FBC3DC8B3B292393ED5E9E43F7DF9EE8C'
23               'A21FAB74B0088AA361152586B8EF1A6BA9DA2D5C')
25 prepare() {
26         cd "$srcdir/$pkgname-$pkgver"
28         # set ca dir to /etc/ssl by default
29         patch -Np1 -i "$srcdir/ca-dir.patch"
32 build() {
33         cd "$srcdir/$pkgname-$pkgver"
35         # mark stack as non-executable: http://bugs.archlinux.org/task/12434
36         ./Configure --prefix=/usr --openssldir=/etc/ssl --libdir=lib \
37                 shared enable-ktls enable-ec_nistp_64_gcc_128 linux-x86_64 \
38                 "-Wa,--noexecstack ${CPPFLAGS} ${CFLAGS} ${LDFLAGS}"
40         make depend
41         make
44 check() {
45         cd "$srcdir/$pkgbase-$pkgver"
47         # the test fails due to missing write permissions in /etc/ssl
48         # revert this patch for make test
49         patch -Rp1 -i "$srcdir/ca-dir.patch"
51         make HARNESS_JOBS=$(nproc) test
53         patch -Np1 -i "$srcdir/ca-dir.patch"
54         # re-run make to re-generate CA.pl from the patched .in file.
55         make apps/CA.pl
58 package() {
59         cd "$srcdir/$pkgname-$pkgver"
61         make DESTDIR="$pkgdir" MANDIR=/usr/share/man MANSUFFIX=ssl install_sw install_ssldirs install_man_docs
63         install -D -m644 LICENSE.txt "$pkgdir/usr/share/licenses/$pkgname/LICENSE.txt"