# Maintainer: orhun # https://github.com/orhun/pkgbuilds pkgname=termchat-git pkgver=1.3.0.r2.gbcfe60f pkgrel=1 pkgdesc="Terminal chat through the LAN (git)" arch=('x86_64') url="https://github.com/lemunozm/termchat" license=('Apache') depends=('gcc-libs') makedepends=('rust' 'clang' 'git') conflicts=("${pkgname%-git}") provides=("${pkgname%-git}") source=("git+${url}") sha512sums=('SKIP') pkgver() { cd "${pkgname%-git}" git describe --long --tags | sed 's/^v//;s/\([^-]*-g\)/r\1/;s/-/./g' } prepare() { cd "${pkgname%-git}" cargo fetch --locked } build() { cd "${pkgname%-git}" cargo build --release --frozen --all-features } check() { cd "${pkgname%-git}" cargo test --release --frozen --features stream-video } package() { cd "${pkgname%-git}" install -Dm 755 "target/release/${pkgname%-git}" -t "${pkgdir}/usr/bin" install -Dm 644 README.md -t "$pkgdir/usr/share/doc/$pkgname" }