summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 02b9a5be7a2d68ee5726d57bce38ce32b1beeb15 (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
# Maintainer: Kimiblock Moe

pkgname=automatamp-git
pkgver=r138.3104a3f
pkgrel=1
pkgdesc="NieR: Automata Multiplayer Mod (Server)"
arch=("any")
url="https://github.com/praydog/AutomataMP"
license=("MIT")
depends=('enet')
makedepends=('go' 'git')
conflicts=('automatamp')
provides=('automatamp')
backup=()
source=("git+https://github.com/praydog/AutomataMP.git")
sha256sums=('SKIP')

function pkgver() {
	cd "${srcdir}/AutomataMP"
	printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
}

function build() {
	cd "${srcdir}/AutomataMP/server"
	go build -trimpath -buildmode=pie -mod=readonly -modcacherw -ldflags "-linkmode external -extldflags \"${LDFLAGS}\""
}

#function check() {
#	cd "${srcdir}/AutomataMP/server"
#	go test ./...
#}

function package() {
	install -Dm755 "${srcdir}/AutomataMP/server/server" "${pkgdir}/usr/bin/automatamp-server"
}