blob: d587ebad560b983c654c126b08a16f99d6d73328 (
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
|
# Maintainer: John Bernard <loqusion@gmail.com>
_pkgname=hyprshade
pkgname=${_pkgname}-rewrite-git
pkgver=r703.87f984e
pkgrel=1
pkgdesc="(WIP rewrite) Hyprland shader configuration tool"
arch=('x86_64')
url="https://github.com/loqusion/${_pkgname}-rewrite"
license=('MIT')
depends=('hyprland')
makedepends=('git' 'cargo')
# WARN: This package is intended for testing purposes only.
# It should not be shown to users trying to install hyprshade.
# provides=("$_pkgname")
conflicts=("$_pkgname")
install="${_pkgname}.install"
source=("${_pkgname}::git+https://github.com/loqusion/${_pkgname}-rewrite.git")
sha512sums=('SKIP')
prepare() {
cd "$_pkgname"
export RUSTUP_TOOLCHAIN=stable
cargo fetch --locked --target "$(rustc -vV | sed -n 's/host: //p')"
}
pkgver() {
cd "$_pkgname"
{
set -o pipefail
git describe --long 2>/dev/null | sed 's/^v//;s/\([^-]*-g\)/r\1/;s/-/./g' ||
printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
}
}
build() {
cd "$_pkgname"
export RUSTUP_TOOLCHAIN=stable
export CARGO_TARGET_DIR=target
cargo build --frozen --release
}
package() {
cd "$_pkgname"
install -Dm755 "target/release/${_pkgname}" "$pkgdir/usr/bin/${_pkgname}"
install -Dm644 "LICENSE" "$pkgdir/usr/share/licenses/${_pkgname}/LICENSE"
}
|