* update swtpm to 0.10.0-3

This commit is contained in:
Alexander Baldeck 2025-02-12 10:39:56 +01:00
parent a3b0c58e52
commit 93279c775b
4 changed files with 20 additions and 10 deletions

View File

@ -1,7 +1,7 @@
pkgbase = swtpm
pkgdesc = Libtpms-based TPM emulator with socket, character device, and Linux CUSE interface
pkgver = 0.10.0
pkgrel = 1
pkgrel = 3
url = https://github.com/stefanberger/swtpm
arch = x86_64
arch = powerpc64le
@ -28,7 +28,11 @@ pkgbase = swtpm
depends = libtpms
depends = openssl
source = git+https://github.com/stefanberger/swtpm.git?signed#tag=v0.10.0
source = swtpm.sysusers
source = swtpm.tmpfiles
validpgpkeys = B818B9CADF9089C2D5CEC66B75AD65802A0B4211
sha512sums = 90ca3afa851804a4a5245fd8c0b2291753ef14011e9dc4ac62c1fe9dc8ac77710d85e14223f02cab28a3a1d1714c2bd879f31ce866e3789bbd517f530473621f
sha512sums = 4b316aa2947c31f0a34a1f84335e3b9bf8e6c033d1cb562022ff49d0297ed4855491e23f549671655143e8e1288a5ad1e215a25868cf7f0c6963d3dced55e890
sha512sums = 2e770313011ca07d3e3c534274897f835e3fa271586d0489f314d25bf2a4ab17f6ee1cfc9539865c0e51ca61f62ae1afd90885bd1ad5144fd4ee1f127a08984d
pkgname = swtpm

View File

@ -3,7 +3,7 @@
pkgname=swtpm
pkgver=0.10.0
pkgrel=1
pkgrel=3
pkgdesc='Libtpms-based TPM emulator with socket, character device, and Linux CUSE interface'
arch=(x86_64 powerpc64le powerpc64 powerpc riscv64)
url='https://github.com/stefanberger/swtpm'
@ -30,15 +30,20 @@ makedepends=(
'socat'
)
checkdepends=('softhsm')
source=("git+$url.git?signed#tag=v$pkgver")
sha512sums=('90ca3afa851804a4a5245fd8c0b2291753ef14011e9dc4ac62c1fe9dc8ac77710d85e14223f02cab28a3a1d1714c2bd879f31ce866e3789bbd517f530473621f')
source=(
"git+$url.git?signed#tag=v$pkgver"
"$pkgname.sysusers"
"$pkgname.tmpfiles"
)
sha512sums=('90ca3afa851804a4a5245fd8c0b2291753ef14011e9dc4ac62c1fe9dc8ac77710d85e14223f02cab28a3a1d1714c2bd879f31ce866e3789bbd517f530473621f'
'4b316aa2947c31f0a34a1f84335e3b9bf8e6c033d1cb562022ff49d0297ed4855491e23f549671655143e8e1288a5ad1e215a25868cf7f0c6963d3dced55e890'
'2e770313011ca07d3e3c534274897f835e3fa271586d0489f314d25bf2a4ab17f6ee1cfc9539865c0e51ca61f62ae1afd90885bd1ad5144fd4ee1f127a08984d')
validpgpkeys=('B818B9CADF9089C2D5CEC66B75AD65802A0B4211') # Stefan Berger <stefanb@linux.vnet.ibm.com>
case "${CARCH}" in
powerpc) options=(!lto)
esac
prepare() {
cd "$pkgname"
# Remove usage of /usr/bin/env to avoid PATH manipulation attacks
@ -53,6 +58,7 @@ build() {
cd "$pkgname"
./configure \
--prefix=/usr \
--libexecdir=/usr/lib \
--with-cuse \
--with-gnutls \
--with-seccomp
@ -67,10 +73,8 @@ check() {
package() {
cd "$pkgname"
make DESTDIR="$pkgdir" install
install -vDm644 -t "$pkgdir/usr/share/licenses/$pkgname" LICENSE
echo 'u tss - "tss user for tpm2"' \
| install -vDm644 /dev/stdin "$pkgdir/usr/lib/sysusers.d/$pkgname.conf"
echo 'z /var/lib/swtpm-localca 0750 tss root' \
| install -vDm644 /dev/stdin "$pkgdir/usr/lib/tmpfiles.d/$pkgname.conf"
chmod -v 750 "$pkgdir/var/lib/swtpm-localca"
install -vDm644 -t "$pkgdir/usr/share/licenses/$pkgname" LICENSE
install -vDm644 "$srcdir/$pkgname.sysusers" "$pkgdir/usr/lib/sysusers.d/$pkgname.conf"
install -vDm644 "$srcdir/$pkgname.tmpfiles" "$pkgdir/usr/lib/tmpfiles.d/$pkgname.conf"
}

1
swtpm/swtpm.sysusers Normal file
View File

@ -0,0 +1 @@
u! tss - "tss user for tpm2"

1
swtpm/swtpm.tmpfiles Normal file
View File

@ -0,0 +1 @@
z /var/lib/swtpm-localca 0750 tss root