summaryrefslogtreecommitdiffstats
path: root/rlr-git/PKGBUILD
diff options
context:
space:
mode:
Diffstat (limited to 'rlr-git/PKGBUILD')
-rw-r--r--rlr-git/PKGBUILD25
1 files changed, 14 insertions, 11 deletions
diff --git a/rlr-git/PKGBUILD b/rlr-git/PKGBUILD
index a1773e0..979f263 100644
--- a/rlr-git/PKGBUILD
+++ b/rlr-git/PKGBUILD
@@ -1,37 +1,40 @@
1# Maintainer: Yigit Sever <yigit at yigitsever dot com> 1# Maintainer: Yigit Sever <yigit at yigitsever dot com>
2
2pkgname=rlr-git # '-bzr', '-git', '-hg' or '-svn' 3pkgname=rlr-git # '-bzr', '-git', '-hg' or '-svn'
3pkgver=r19.3d62f7a 4pkgver=r25.5fd3169
4pkgrel=1 5pkgrel=1
5pkgdesc="interactive pixel screen ruler and protractor" 6pkgdesc="interactive pixel screen ruler and protractor"
6arch=('any') 7arch=('any')
7url="https://github.com/epilys/rlr" 8url="https://github.com/epilys/rlr"
8license=('GPL') 9license=('GPL')
9depends=()
10makedepends=('git' 'cargo') # 'bzr', 'git', 'mercurial' or 'subversion' 10makedepends=('git' 'cargo') # 'bzr', 'git', 'mercurial' or 'subversion'
11provides=("${pkgname%-git}") 11provides=("${pkgname%-git}")
12conflicts=("${pkgname%-git}") 12conflicts=("${pkgname%-git}")
13source=("${pkgname%-git}::git+${url}") 13source=("${pkgname%-git}::git+${url}" "${pkgname%-git}.desktop")
14sha256sums=('SKIP') 14sha256sums=('SKIP'
15 '7f659ea7e8cb794963ff6881294a8aba388c33bc10c7e14c1ecf58fb241386e7')
15 16
16pkgver() { 17pkgver() {
17 cd "$srcdir/${pkgname%-git}" 18 cd "$srcdir/${pkgname%-git}"
18 # Git, no tags available 19 # git, no tags available
19 printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)" 20 printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
20} 21}
21 22
22prepare() { 23prepare() {
23 cd "$srcdir/${pkgname%-git}" 24 cd "$srcdir/${pkgname%-git}"
24 cargo fetch --locked --target "$CARCH-unknown-linux-gnu" 25 cargo fetch --locked --target "$CARCH-unknown-linux-gnu"
25} 26}
26 27
27build() { 28build() {
28 cd "$srcdir/${pkgname%-git}" 29 cd "$srcdir/${pkgname%-git}"
29 export RUSTUP_TOOLCHAIN=stable 30 export RUSTUP_TOOLCHAIN=stable
30 export CARGO_TARGET_DIR=target 31 export CARGO_TARGET_DIR=target
31 cargo build --frozen --release --all-features 32 cargo build --frozen --release --all-features
32} 33}
33 34
34package() { 35package() {
35 cd "$srcdir/${pkgname%-git}" 36 # binary
36 install -Dm0755 -t "$pkgdir/usr/bin/" "target/release/${pkgname%-git}" 37 install -Dm0755 "${srcdir}/${pkgname%-git}/target/release/${pkgname%-git}" -t "${pkgdir}/usr/bin/"
38 # desktop file
39 install -Dm644 "${pkgname%-git}.desktop" "${pkgdir}/usr/share/applications/${pkgname%-git}.desktop"
37} 40}