summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 317321e2a1af048efa22c2c826613afd90510937 (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
53
54
55
# Maintainer: Paris Oplopoios <parisoplop@gmail.com>

_pkgname=Panda3DS
_latest_release=0.8
_executable_name=Alber
_install_name=panda3ds

pkgname=panda3ds-git
pkgver=0.8.r1780.3c25be4c
pkgrel=1
pkgdesc="HLE 3DS emulator"
arch=('x86_64')
url="https://panda3ds.com"
license=('GPL3')

# Panda3DS Dependencies
depends=(
	gcc-libs
	libxext
)

# Build Dependencies
makedepends=(
	cmake
	ninja
	git
	clang
)

provides=(panda3ds)
conflicts=(panda3ds)
source=("git+https://github.com/wheremyfoodat/Panda3DS")
sha256sums=('SKIP')

pkgver() {
	cd $_pkgname
	printf "%s.r%s.%s" \
	"$_latest_release" \
	"$(git rev-list --count HEAD)" \
	"$(git rev-parse --short HEAD)"
}

build() {
	export CXX=clang++
	export CC=clang
	cd $_pkgname
	git submodule update --init --recursive
	cmake -S . -B build -Wno-dev -DCMAKE_INSTALL_PREFIX=/usr -DCMAKE_BUILD_TYPE=Release -DENABLE_USER_BUILD=ON -DENABLE_VULKAN=OFF -GNinja
	cmake --build build -j$(nproc)
}

package() {
	cd $_pkgname
	install -vDm 755 "build/$_executable_name" "$pkgdir/usr/bin/$_install_name"
}