summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 2b50ca408645c7d98c1738e0abb3d07a501e766b (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
pkgname=ydcv-rs-git
_pkgname="ydcv-rs"
pkgdesc="A Rust version of ydcv."
pkgver=0.4.1.133
pkgrel=1
arch=('i686' 'x86_64')
conflicts=("ydcv")
provides=("ydcv")
url="https://github.com/farseerfc/ydcv-rs"
license=('GPL2')
depends=("openssl" "libdbus" "libxcb")
optdepends=()
makedepends=('git' 'cargo' 'python')
source=('git://github.com/farseerfc/ydcv-rs.git')
sha256sums=('SKIP')

pkgver() {
	cd $_pkgname
	echo $(grep '^version =' Cargo.toml|head -n1|cut -d\" -f2).$(git rev-list --count HEAD)
}

build() {
	cd $_pkgname
	cargo build --release
}

check() {
	cd $_pkgname
	cargo test --release
}

package() {
	cd $_pkgname
	install -D -m755 "$srcdir/$_pkgname/target/release/ydcv-rs" "$pkgdir/usr/bin/ydcv"
}