summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 3b20aea89c43bf97b8987be12a1345023c271409 (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: Adrian Fluturel <adrian.fluturel@protonmail.com>
pkgname=wolff-lang-git
pkgver=0.1.3
pkgrel=1
epoch=
pkgdesc="This is the official bleeding-edge package for the Wolff language interpreter"
arch=(x86_64 i686)
url="https://github.com/Flu/wolff-lang.git"
license=('MIT')
groups=()
depends=(gcc-libs)
makedepends=(cargo git)
checkdepends=()
optdepends=()
provides=(wolff)
conflicts=(wolff)
replaces=()
backup=()
options=()
install=
changelog=
source=("git+$url")
noextract=()
md5sums=('SKIP')
validpgpkeys=()

prepare() {
    cd wolff-lang
    cargo fetch --locked --target "$CARCH-unknown-linux-gnu"
}

build() {
    cd wolff-lang
    export RUSTUP_TOOLCHAIN=nightly
    export CARGO_TARGET_DIR=target
    cargo build --frozen --release --all-features
}

check() {
    cd wolff-lang
    export RUSTUP_TOOLCHAIN=nightly
    cargo test --frozen --all-features
}

package() {
    cd wolff-lang
    install -Dt "$pkgdir/usr/bin/" target/release/wolff
    install -Dt "$pkgdir/usr/share/doc/$pkgname" -m644 README.md
}