# Maintainer: Oliver Smith # Co-Maintainer: Clayton Craft pkgname=postmarketos-mkinitfs pkgver=1.4.1 pkgrel=4 pkgdesc="Tool to generate initramfs images for postmarketOS" url="https://postmarketos.org" depends=" boot-deploy busybox-extras btrfs-progs bzip2 cryptsetup device-mapper e2fsprogs e2fsprogs-extra f2fs-tools lz4 multipath-tools parted postmarketos-fde-unlocker unudhcpd xz " makedepends="go" replaces="mkinitfs" triggers="$pkgname.trigger=/etc/postmarketos-mkinitfs/hooks:/usr/share/kernel/*:/usr/share/postmarketos-mkinitfs-triggers" source=" https://gitlab.com/postmarketOS/postmarketos-mkinitfs/-/archive/$pkgver/postmarketos-mkinitfs-$pkgver.tar.gz 00-default.modules init.sh init_functions.sh " install="$pkgname.post-upgrade" arch="all" license="GPL-2.0-or-later" provides="mkinitfs=3.6.0" export GOPATH="$srcdir" export CGO_ENABLED=0 build() { # "-s -w" build a stripped binary go build -v -ldflags="-s -w" } package() { install -Dm644 "$srcdir/init_functions.sh" \ "$pkgdir/usr/share/postmarketos-mkinitfs/init_functions.sh" install -Dm755 "$srcdir/init.sh" \ "$pkgdir/usr/share/postmarketos-mkinitfs/init.sh" install -Dm644 "$srcdir/00-default.modules" \ "$pkgdir/etc/postmarketos-mkinitfs/modules/00-default.modules" install -Dm755 postmarketos-mkinitfs \ "$pkgdir/sbin/postmarketos-mkinitfs" ln -s /sbin/postmarketos-mkinitfs \ "$pkgdir/sbin/mkinitfs" mkdir -p "$pkgdir/etc/postmarketos-mkinitfs/hooks/" } check() { go test ./... } sha512sums=" f827acb0a10c0e5c1631f1b712e91fde7eb4ade0f1174eb2ef1754018bf4518ea1ad3229fd335c25fb0c6fe46ae20890f5cf43e58c8143ae17b5ab9bb36f0199 postmarketos-mkinitfs-1.4.1.tar.gz 08a3e79c6fa7d3839d43515b8da7817cb36f4ab014552fd0164957c232bb16fde337e57c47c9734d396a5fca3328fbf49ebabe4728c6071c80b04dad14886bba 00-default.modules d16dc495afcab64e8ae70b8de06444aac3d655ca59c544717ea779d160d597a0a32da62e55e7493b0c7626e1e7fcefa3f94b917ae16ac7d2990a3038934a6fac init.sh ef099d394406462268fe9e2d28a5355ef09a30fa7283d58e2c567088bd767fb8079399426ccaabe48dbc7774cf9cd7a5b853d850a978ae05e0d74909cee5b207 init_functions.sh "