From 3b0c40ec459a7400606a911433728c5b6d4ee985 Mon Sep 17 00:00:00 2001 From: Xavier Date: Mon, 12 Feb 2024 00:55:49 -0500 Subject: [PATCH] Initial Commit --- .SRCINFO | 31 +++++++++++++++++++++++++++++++ PKGBUILD | 53 +++++++++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 84 insertions(+) create mode 100644 .SRCINFO create mode 100644 PKGBUILD diff --git a/.SRCINFO b/.SRCINFO new file mode 100644 index 0000000..e800527 --- /dev/null +++ b/.SRCINFO @@ -0,0 +1,31 @@ +pkgbase = pacwrap + pkgdesc = Facilitates the creation, management, and execution of Arch-baesd unprivileged bubblewrap containers. + pkgver = 0.7.0 + pkgrel = 1 + url = https://pacwrap.sapphirus.org/ + arch = x86_64 + license = GPLv3-only + makedepends = cargo + makedepends = git + makedepends = fakeroot + makedepends = pacman + makedepends = zstd + makedepends = busybox + makedepends = fakechroot + options = !lto + source = pacwrap-0.7.0.tar.zst::https://github.com/pacwrap/pacwrap/releases/download/0.7.0/pacwrap-0.7.0.tar.zst + sha512sums = b79b118be628c506f5d79d747e89172d839847b5610dd62a913deb586b591abe5d58f20c065ccc4a975627637f667b4e35ff63a83857e9226f01156684db9ccb + +pkgname = pacwrap + depends = bash + depends = bubblewrap + depends = gnupg + depends = pacman + depends = libseccomp + depends = pacwrap-dist=0.7.0 + depends = zstd + optdepends = xdg-dbus-proxy + provides = pacwrap + +pkgname = pacwrap-dist + provides = pacwrap-dist diff --git a/PKGBUILD b/PKGBUILD new file mode 100644 index 0000000..640622f --- /dev/null +++ b/PKGBUILD @@ -0,0 +1,53 @@ +# Maintainer: Xavier R.M. (sapphirus at azorium dot net) + +pkgname=('pacwrap' 'pacwrap-dist') +pkgver=0.7.0 +pkgrel=1 +pkgdesc="Facilitates the creation, management, and execution of Arch-baesd unprivileged bubblewrap containers." +arch=('x86_64') +url="https://pacwrap.sapphirus.org/" +license=('GPLv3-only') +makedepends=('cargo' 'git' 'fakeroot' 'pacman' 'zstd' 'busybox' 'fakechroot') +source=("${pkgname}-${pkgver}.tar.zst::https://github.com/pacwrap/pacwrap/releases/download/${pkgver}/${pkgname}-${pkgver}.tar.zst") +sha512sums=('b79b118be628c506f5d79d747e89172d839847b5610dd62a913deb586b591abe5d58f20c065ccc4a975627637f667b4e35ff63a83857e9226f01156684db9ccb') +options=('!lto') + +prepare() { + cd "${srcdir}" + cargo fetch --locked --target "$CARCH-unknown-linux-gnu" + ./dist/tools/schema.sh release +} + +build() { + cd "${srcdir}" + cargo build --release --frozen + ./dist/tools/runtime.sh release + ./target/release/pacwrap --help=all --format=man > ./pacwrap.1 + ./target/release/pacwrap --help=pacwrap.yml --format=man > ./pacwrap.yml.2 +} + +package_pacwrap() { + provides=('pacwrap') + depends=('bash' 'bubblewrap' 'gnupg' 'pacman' 'libseccomp' "pacwrap-dist=$pkgver" 'zstd') + optdepends=('xdg-dbus-proxy') + + install -d "${pkgdir}/usr/share/pacwrap" + install -Dm 755 "target/release/${pkgname}" "${pkgdir}/usr/bin/${pkgname}" + install -Dm 755 "bin/${pkgname}-common" "${pkgdir}/usr/bin/${pkgname}-common" + install -Dm 755 "bin/${pkgname}-utils" "${pkgdir}/usr/bin/${pkgname}-utils" + install -Dm 644 "pacwrap.1" "${pkgdir}/usr/share/man/man1/pacwrap.1" + install -Dm 644 "pacwrap.yml.2" "${pkgdir}/usr/share/man/man2/pacwrap.yml.2" + install -Dm 644 LICENSE "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE" +} + +package_pacwrap-dist() { + provides=('pacwrap-dist') + + install -Dm 644 LICENSE "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE" + install -d "${pkgdir}/usr/share/pacwrap" + + cd dist + cp -r "filesystem.tar.zst" "${pkgdir}/usr/share/pacwrap" + cp -r "filesystem.dat" "${pkgdir}/usr/share/pacwrap" + cp -r "runtime" "${pkgdir}/usr/share/pacwrap" +}