jobcore/cryptsetup/PKGBUILD-arch
2022-11-15 17:49:16 +02:00

52 lines
1.9 KiB
Text

# Maintainer: Bartłomiej Piotrowski <bpiotrowski@archlinux.org>
# Contributor: Thomas Bächler <thomas@archlinux.org>
pkgname=cryptsetup
pkgver=2.5.0
pkgrel=4
pkgdesc='Userspace setup tool for transparent encryption of block devices using dm-crypt'
arch=(x86_64)
license=('GPL')
url='https://gitlab.com/cryptsetup/cryptsetup/'
depends=('device-mapper' 'libdevmapper.so' 'openssl' 'popt' 'util-linux-libs'
'libuuid.so' 'json-c' 'libjson-c.so' 'argon2' 'libargon2.so')
makedepends=('util-linux' 'asciidoctor')
provides=('libcryptsetup.so')
options=('debug' '!emptydirs')
validpgpkeys=('2A2918243FDE46648D0686F9D9B0577BD93E98FC') # Milan Broz <gmazyland@gmail.com>
source=("https://www.kernel.org/pub/linux/utils/cryptsetup/v${pkgver%.*}/${pkgname}-${pkgver}.tar."{xz,sign}
'hooks-encrypt'
'install-encrypt'
'install-sd-encrypt')
sha256sums=('9184a6ebbd9ce7eb211152e7f741a6c82f2d1cc0e24a84ec9c52939eee0f0542'
'SKIP'
'29a3f1db5b86a8e6b7c914125e2c46711d6d5985bbf4089e158e06af551c8307'
'2b71c6c56ef81e5bf4f49dcc08dbd1651b46bda51a8f75a0a342b344b2d0eccd'
'24cd81419c8f3fd8341dfa3c4616946180a16ea762b6ea7576d2214f83f875db')
build() {
cd "${srcdir}"/$pkgname-${pkgver}
./configure \
--prefix=/usr \
--sbindir=/usr/bin \
--enable-libargon2 \
--disable-ssh-token \
--disable-static
sed -i -e 's/ -shared / -Wl,-O1,--as-needed\0/g' libtool
make
}
package() {
cd "${srcdir}"/$pkgname-${pkgver}
make DESTDIR="${pkgdir}" install
# install docs
install -D -m0644 -t "${pkgdir}"/usr/share/doc/cryptsetup/ FAQ.md docs/{Keyring,LUKS2-locking}.txt
# install hook
install -D -m0644 "${srcdir}"/hooks-encrypt "${pkgdir}"/usr/lib/initcpio/hooks/encrypt
install -D -m0644 "${srcdir}"/install-encrypt "${pkgdir}"/usr/lib/initcpio/install/encrypt
install -D -m0644 "${srcdir}"/install-sd-encrypt "${pkgdir}"/usr/lib/initcpio/install/sd-encrypt
}