summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 41c493a0ad80b6bb6ef9a1717bd2075b7b6a2f6a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
# Maintainer: Jelle van der Waa <jelle@archlinux.org>

pkgname=readlater-git
pkgver=r11.a83fb84
pkgrel=1
pkgdesc="Read web articles later via RSS/Epub"
arch=('x86_64')
url="https://github.com/jelly/readlater"
license=('MIT')
depends=(glibc openssl sqlite)
makedepends=(rust git)
provides=("${pkgname%-git}")
conflicts=("${pkgname%-git}")
source=(git+https://github.com/jelly/readlater.git)
sha256sums=('SKIP')

pkgver() {
  cd "${pkgname%-git}"
  printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
}

prepare() {
  cd "${pkgname%-git}"
  cargo fetch --locked --target "$CARCH-unknown-linux-gnu"
}

build() {
  cd "${pkgname%-git}"
  cargo build --frozen --release --all-features
}

package() {
  cd "${pkgname%-git}"
  install -Dm0755 -t "$pkgdir/usr/bin/" "target/release/${pkgname%-git}"
  install -Dm0644 -t "$pkgdir/usr/share/licenses/${pkgname}" LICENSE 
}