# Maintainer: orhun # https://github.com/orhun/pkgbuilds pkgname=emptty pkgdesc="Dead simple CLI Display Manager on TTY" pkgver=0.5.2 pkgrel=1 arch=('x86_64') url="https://github.com/tvrzna/emptty" license=('MIT') depends=('pam' 'libx11') makedepends=('go' 'git') optdepends=('xorg-server: default display server' 'xorg-xauth: required if using xorg-server' 'util-linux: mcookie required if using xorg-server' 'wayland: alternative to xorg-server') backup=('etc/emptty/conf') install="$pkgname.install" source=("$pkgname-$pkgver.tar.gz::$url/archive/v$pkgver.tar.gz") sha512sums=('adb866ae4c7beb10a1144ea6fb9aef64631944470854b809d20c472b27efde0149a19998dedafec05b5d52e4bb7194ad831ec32eedbca1c9d3a390a874bda03e') build() { cd "$pkgname-$pkgver" export CGO_CPPFLAGS="${CPPFLAGS}" export CGO_CFLAGS="${CFLAGS}" export CGO_CXXFLAGS="${CXXFLAGS}" export CGO_LDFLAGS="${LDFLAGS}" export GOFLAGS="-buildmode=pie -trimpath -ldflags=-linkmode=external -mod=readonly -modcacherw" make build } package() { cd "$pkgname-$pkgver" make DESTDIR="$pkgdir/" install-all make DESTDIR="$pkgdir/" install-config make DESTDIR="$pkgdir/" install-systemd install -Dm 644 README.md -t "$pkgdir/usr/share/doc/$pkgname" install -Dm 644 LICENSE -t "$pkgdir/usr/share/licenses/$pkgname" }