packages/libtpms/PKGBUILD
2023-07-04 15:03:41 +02:00

43 lines
1.0 KiB
Bash

# POWER Maintainer: Alexander Baldeck <alex.bldck@gmail.com>
# Maintainer: Jonas Witschel <diabonas@archlinux.org>
pkgname=libtpms
pkgver=0.9.6
_tag=fccd9f0ec5febf75ccec2742e75889cdfa329e53 # git rev-parse "v$pkgver"
pkgrel=1
pkgdesc='Library providing a software emulation of a Trusted Platform Module (TPM 1.2 and TPM 2.0)'
arch=(x86_64 powerpc64le powerpc64 powerpc riscv64)
url='https://github.com/stefanberger/libtpms'
license=('BSD')
depends=('openssl')
makedepends=('git')
source=("git+$url.git?signed#tag=$_tag")
sha512sums=('SKIP')
validpgpkeys=('B818B9CADF9089C2D5CEC66B75AD65802A0B4211') # Stefan Berger <stefanb@linux.vnet.ibm.com>
pkgver() {
cd "$pkgname"
git describe | sed 's/^v//;s/\([^-]*-\)g/r\1/;s/-/./g'
}
prepare() {
cd "$pkgname"
autoreconf --install --force
}
build() {
cd "$pkgname"
./configure --prefix=/usr --with-openssl --with-tpm2
make
}
check() {
cd "$pkgname"
make check
}
package() {
cd "$pkgname"
make DESTDIR="$pkgdir" install
install -Dm644 LICENSE -t "$pkgdir/usr/share/licenses/$pkgname"
}