summarylogtreecommitdiffstats
path: root/PKGBUILD.in
blob: 3d2e6d485eaf1252cd6fbc80a8181521e8312a45 (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
# Maintainer: Aki-nyan <aur@catgirl.link>

pkgname=prjoxide-nightly
pkgver=@OXIDE_VER@
pkgrel=1
epoch=1
pkgdesc="Documenting Lattice's 28nm FPGA parts"
arch=("x86_64")
url="https://github.com/gatecat/prjoxide"
license=("custom:ISC")
groups=()
options=("!strip")
depends=()
optdepends=()
makedepends=("git" "cargo")
conflicts=(
	"prjoxide-git"
)
replaces=()
source=(
	"prjoxide::git+https://github.com/gatecat/prjoxide.git#commit=@OXIDE_HASH@"
	"prjoxide-db::git+https://github.com/gatecat/prjoxide-db.git#commit=@DB_HASH@"
)
sha256sums=(
	"SKIP"
	"SKIP"
)


_PREFIX="/usr"
prepare() {
	cd "${srcdir}/prjoxide"
	git submodule init
	git config submodule.database.url "$srcdir/prjoxide-db"
	git -c protocol.file.allow=always submodule update
}

build() {
	cd "${srcdir}/prjoxide/libprjoxide"
	cargo build --release
}

package() {
	install -Dm755 "${srcdir}/prjoxide/libprjoxide/target/release/prjoxide" "${pkgdir}${_PREFIX}/bin/prjoxide"
	install -Dm644 "${srcdir}/prjoxide/libprjoxide/target/release/libpyprjoxide.so" "${pkgdir}${_PREFIX}/lib/libpyprjoxide.so"
	install -Dm644 "${srcdir}/prjoxide/COPYING" "${pkgdir}${_PREFIX}/share/licenses/prjoxide/COPYING"
}