PKGBUILDs/extra/wolfssl/PKGBUILD
2022-09-12 12:42:51 +00:00

61 lines
2 KiB
Bash

# Maintainer: David Runge <dvzrv@archlinux.org>
# ALARM: Kevin Mihelich <kevin@archlinuxarm.org>
# - cmake with -DWOLFSSL_SHA3=ON, required and not set by default for v7
pkgname=wolfssl
pkgver=5.5.0
pkgrel=1
pkgdesc="Lightweight, portable, C-language-based SSL/TLS library"
arch=(x86_64)
url="https://www.wolfssl.com/"
license=(GPL2)
depends=(glibc)
makedepends=(cmake)
provides=(libwolfssl.so)
options=(debug)
source=(
$pkgname-$pkgver-stable.tar.gz::https://github.com/$pkgname/$pkgname/archive/refs/tags/v$pkgver-stable.tar.gz
https://github.com/$pkgname/$pkgname/releases/download/v$pkgver-stable/$pkgname-$pkgver-stable.tar.gz.asc
$pkgname-5.5.0-cmake.patch
)
sha512sums=('1f9ffd8e83b26f97c3685315790f3f2b451a23e9dad9e2f09142a3e1e136012293ca2d04f46c267f8275ac9e60894c46c7875353765df6d4fdd93ba666228459'
'SKIP'
'44aef4fc39dc81b113563b78c8732e8d1d6371e1c0ad0e73d8b13115e6623d8d92e6162400453fe36473616e2f6f9a283f8a440c94588860e92b204669672be4')
b2sums=('92f2f1c7072cf6bb0ea5007cb4c1662c147534021fe63929202a2c4e46bdd40bc2e61fdec6d3c8720bfd1be8e946588536ba2a7e9c02a84e11be3e01ca2db1c3'
'SKIP'
'8179223e2536d672896be7b5afab45df3326a14d6330c031d6631bb8075a666c4106d8a47b56d6640254cf91c75b7a4fc3801a1ef5626f847dd90926472c0370')
validpgpkeys=(
A2A48E7BCB96C5BECB987314EBC80E415CA29677 # wolfSSL <secure@wolfssl.com>
)
prepare() {
# -Werror not even once: https://github.com/wolfSSL/wolfssl/issues/5553
patch -Np1 -d $pkgname-$pkgver-stable -i ../$pkgname-5.5.0-cmake.patch
}
build() {
cmake \
-DCMAKE_INSTALL_PREFIX=/usr \
-DCMAKE_BUILD_TYPE=None \
-DWOLFSSL_CURVE25519=ON \
-DWOLFSSL_CURVE448=ON \
-DWOLFSSL_ED25519=ON \
-DWOLFSSL_ED448=ON \
-DWOLFSSL_SHA3=ON \
-DWOLFSSL_REPRODUCIBLE_BUILD=ON \
-Wno-dev \
-B build \
-S $pkgname-$pkgver-stable
cmake --build build --verbose
}
check() {
cd build
ctest --output-on-failure
}
package() {
DESTDIR="$pkgdir" cmake --install build
install -vDm 644 $pkgname-$pkgver-stable/{README,ChangeLog}.md -t "$pkgdir/usr/share/doc/$pkgname/"
}