summaryrefslogtreecommitdiffstats
path: root/PKGBUILD
diff options
context:
space:
mode:
authorYigit Sever2022-09-13 18:26:09 +0300
committerYigit Sever2022-09-13 18:26:09 +0300
commit84b3dae3d12c3b4acbc371a56bc37f0ecb9490dc (patch)
tree8eefbe67de5e748a463d70a4d159274fda355d6a /PKGBUILD
parentbacdbc90efc8cd407b5ce658e3616748ae6c8ea3 (diff)
downloadpackages-84b3dae3d12c3b4acbc371a56bc37f0ecb9490dc.tar.gz
packages-84b3dae3d12c3b4acbc371a56bc37f0ecb9490dc.tar.bz2
packages-84b3dae3d12c3b4acbc371a56bc37f0ecb9490dc.zip
Add desktop file
Courtesy of AUR user somepaulo
Diffstat (limited to 'PKGBUILD')
-rw-r--r--PKGBUILD25
1 files changed, 14 insertions, 11 deletions
diff --git a/PKGBUILD b/PKGBUILD
index a1773e0..979f263 100644
--- a/PKGBUILD
+++ b/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}