blob: 2b7767aac7204b1947aa67b4c846fee16e853e52 (
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
37
38
39
40
41
42
43
44
45
46
47
48
49
|
# Maintainer:
: ${CARGO_HOME:=$SRCDEST/cargo-home}
_pkgname="vdhcoapp-filepicker"
pkgname="$_pkgname"
pkgver=1.0.1
pkgrel=1
pkgdesc="Filepicker for VDHCoApp" # added in 2.0.16
url="https://github.com/paulrouget/static-filepicker"
license=('GPL-2.0-or-later')
arch=('x86_64')
depends=(
'gtk3'
)
makedepends=(
'cargo'
'git'
)
_pkgsrc="$_pkgname"
source=("$_pkgsrc"::"git+$url.git#tag=v$pkgver")
sha256sums=('SKIP')
_cargo_env() {
export CARGO_HOME
export RUSTUP_TOOLCHAIN=stable
export CARGO_TARGET_DIR=target
}
prepare() {
_cargo_env
cd "$_pkgsrc"
cargo fetch --locked --target "$(rustc -vV | sed -n 's/host: //p')"
}
build() {
_cargo_env
cd "$_pkgsrc"
cargo build --frozen --release --all-features
}
package() {
_cargo_env
install -Dm755 "$_pkgsrc/$CARGO_TARGET_DIR/release/filepicker" -t "$pkgdir/usr/bin/"
}
|