# Maintainer: Bendik Aagaard Lynghaug # Built from the tagged checkout by .gitea/workflows/release.yml, once # per architecture, and uploaded to the [uhhm] registry on # project.uhhm.no (namespace bl). pkgver is the version; the tag has # to agree with it. pkgname=gdo pkgver=0.1.1 pkgrel=2 pkgdesc="Sends the code that opens the iris: delivers portal's outgoing mail from JetStream to the host's SMTP" arch=('x86_64' 'aarch64') url="https://project.uhhm.no/uhhm/gdo" license=('MIT') depends=('glibc' 'gcc-libs') makedepends=('cargo') optdepends=('postfix: the SMTP it hands mail to' 'nats-server: the JetStream it reads from' 'typst: PDF themes (GDO_TYPST_THEME)') backup=('etc/gdo/env') # !lto: makepkg's -flto would turn ring's C objects into GCC bitcode the # Rust linker cannot see (undefined ring_core_* symbols). options=('!debug' '!lto') # Sources are the checkout itself: makepkg resolves local sources by # basename next to the PKGBUILD, so the tagged tree CI builds from is # the source of truth, as in uhhm/corp. build() { cd "$startdir" cargo build --release --locked } check() { cd "$startdir" cargo test --release --locked } package() { cd "$startdir" install -Dm755 "${CARGO_TARGET_DIR:-target}/release/gdo" "$pkgdir/usr/bin/gdo" install -Dm644 deploy/gdo.service "$pkgdir/usr/lib/systemd/system/gdo.service" install -Dm600 deploy/env "$pkgdir/etc/gdo/env" install -Dm644 README.md "$pkgdir/usr/share/doc/$pkgname/README.md" install -Dm644 LICENSE "$pkgdir/usr/share/licenses/$pkgname/LICENSE" }