archrelease: copy trunk to extra-x86_64
[arch-packages.git] / wolfssl / repos / community-x86_64 / PKGBUILD
blob06b74693547051fd951af08990353a6552b0e21e
1 # Maintainer: David Runge <dvzrv@archlinux.org>
3 pkgname=wolfssl
4 pkgver=5.5.1
5 pkgrel=1
6 pkgdesc="Lightweight, portable, C-language-based SSL/TLS library"
7 arch=(x86_64)
8 url="https://www.wolfssl.com/"
9 license=(GPL2)
10 depends=(glibc)
11 makedepends=(cmake)
12 provides=(libwolfssl.so)
13 options=(debug)
14 source=(
15   $pkgname-$pkgver-stable.tar.gz::https://github.com/$pkgname/$pkgname/archive/refs/tags/v$pkgver-stable.tar.gz
16   https://github.com/$pkgname/$pkgname/releases/download/v$pkgver-stable/$pkgname-$pkgver-stable.tar.gz.asc
17   $pkgname-5.5.1-cmake.patch
19 sha512sums=('821bb7b8105d53c614712eb9f7ebb39a5e20f03c1856edad4e4cdaed797f7940fbe7062905d64bd386878abae1ae3275a4b7792db9b1d673f2de5d903b60f32e'
20             'SKIP'
21             '02e2a6c370b2ad8e737b9d40d435a65babd8ce9c03892e1f1bf484d328f45bda4fe8be82cc051fdcda4946c405f8ea4baa6840d1db5ae54bec0dbc0dcce7da28')
22 b2sums=('b735beee96bdc9fde6aca5048c732d77bb86ecbe29ba8ad8cd6528fef340859b3017faa4b84e00c476e017dde741e276440408c3ae6fc90d6790961c6ed26001'
23         'SKIP'
24         '82cee658075ffb8a2e1ebb2b0a8018b7edbacd29727f7aaca026c8d8808e48cfd617c2e22a01601a80d377423f57d7b6c7dc18186c2f59d8a7ab60bf37ce75ff')
25 validpgpkeys=(
26   A2A48E7BCB96C5BECB987314EBC80E415CA29677  # wolfSSL <secure@wolfssl.com>
29 prepare() {
30   # -Werror not even once: https://github.com/wolfSSL/wolfssl/issues/5553
31   patch -Np1 -d $pkgname-$pkgver-stable -i ../$pkgname-5.5.1-cmake.patch
34 build() {
35   cmake \
36     -DCMAKE_INSTALL_PREFIX=/usr \
37     -DCMAKE_BUILD_TYPE=None \
38     -DWOLFSSL_CURVE25519=ON \
39     -DWOLFSSL_CURVE448=ON \
40     -DWOLFSSL_ED25519=ON \
41     -DWOLFSSL_ED448=ON \
42     -DWOLFSSL_REPRODUCIBLE_BUILD=ON \
43     -Wno-dev \
44     -B build \
45     -S $pkgname-$pkgver-stable
46   cmake --build build --verbose
49 check() {
50   cd build
51   ctest --output-on-failure
54 package() {
55   DESTDIR="$pkgdir" cmake --install build
56   install -vDm 644 $pkgname-$pkgver-stable/{README,ChangeLog}.md -t "$pkgdir/usr/share/doc/$pkgname/"