summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 2c91fa992195dd1912bd2c32275a2de55831884a (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
50
51
52
53
54
55
56
57
58
# Maintainer: tblFlip <root@tblflipde>

pkgname=woomer
pkgver=0.1.0
pkgrel=1

pkgdesc="Zoomer application for Wayland inspired by tsoding's boomer"
url="https://github.com/coffeeispower/woomer"
license=("MIT")
arch=("i686" "x86_64")

depends=(
	gcc-libs
	glfw
	glibc
)

makedepends=(
	cargo
	clang
	cmake
	compiler-rt
	pkgconf
	wayland
)

source=(
	"$pkgname-$pkgver.tar.gz::$url/archive/refs/tags/$pkgver.tar.gz"
)

sha256sums=(
	"0e53ca0576c71a5931e75a45e734f2acacc0592260a06316b4b5a82a19faadac"
)

prepare() {
	cd "$pkgname-$pkgver"
	export RUSTUP_TOOLCHAIN=stable
	cargo fetch --locked --target "$(rustc -vV | sed -n 's/host: //p')"
}

build() {
	cd "$pkgname-$pkgver"
    export RUSTUP_TOOLCHAIN=stable
    export CARGO_TARGET_DIR=target
	export CFLAGS="${CFLAGS//-flto=auto/}"
    cargo build --frozen --release --all-features
}

check() {
	cd "$pkgname-$pkgver"
    export RUSTUP_TOOLCHAIN=stable
    cargo test --frozen --all-features
}

package() {
	cd "$pkgname-$pkgver"
    install -Dm0755 -t "$pkgdir/usr/bin/" "target/release/$pkgname"
}