summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: e8ef2387e2dcc1ee15c409e4f27548a04588be12 (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
# Maintainer: Tobias Frisch <thejackimonster@gmail.com>

pkgname=funemustation-git
_name=funemustation
_export=FunEmuStation_Launcher
pkgver=r14.765d4e4
pkgrel=1
pkgdesc="A simple but elegant launcher of emulators and pc games"
url="https://dannygaray60.itch.io/funemustation-launcher"
depends=('libxcursor' 'libxinerama' 'freetype2' 'alsa-lib' 'libxrandr' 'libxi' 'libglvnd')
makedepends=('godot' 'git')
optdepends=()
license=('GPL3')
arch=('any')
source=("git+https://github.com/dannygaray60/${_name}.git")
sha256sums=('SKIP')
provides=('funemustation')

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

build() {
	cd ${srcdir}/${_name}
	
	mkdir -p "bin"
	echo "#!/bin/sh" > "bin/${_name}"
	echo "cd /usr/share/$_name" >> "bin/${_name}"
	echo "./${_export}.x86_64" >> "bin/${_name}"

	godot --no-window --path "." --export "Linux/X11" "bin/${_export}.x86_64"
}

package() {
	cd ${srcdir}/${_name}
	
	install -Dm755 "bin/${_export}.x86_64" "$pkgdir/usr/share/$_name/${_export}.x86_64"
	install -Dm644 "bin/${_export}.pck" "$pkgdir/usr/share/$_name/${_export}.pck"
	install -Dm755 "bin/${_name}" "$pkgdir/usr/bin/${_name}"
}