blob: 43562c785199f5659d1048c4c9e6fc8d01ad83e1 (
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: lrobbins at silktown dot software
pkgname=rigelengine-git
pkgver=0.9.1.r4.g011976b3
pkgrel=2
# Description taken from desktop file
pkgdesc='A modern re-implementation of the classic DOS game Duke Nukem II'
url='https://github.com/lethal-guitar/RigelEngine'
arch=('x86_64')
license=('GPL2')
depends=(sdl2_mixer)
makedepends=(git cmake sdl2)
source=("git+https://github.com/lethal-guitar/RigelEngine")
sha256sums=('SKIP')
_executable_name=RigelEngine
_source_dir="RigelEngine"
pkgver() {
cd "$_source_dir"
git describe --long --tag | sed 's/^v//;s/\([^-]*-g\)/r\1/;s/-/./g'
}
prepare() {
cd "$_source_dir"
git submodule update --init --recursive
}
build() {
cd "$_source_dir"
mkdir -p build
cd build
cmake .. -Wno-dev -DBUILD_TESTS=ON
make -j$(nproc)
}
package() {
cd "$_source_dir"
mkdir -p "$pkgdir/usr/bin"
cp "build/src/$_executable_name" "$pkgdir/usr/bin"
# copy over the destop file from the dist directory
mkdir -p "$pkgdir/usr/share/applications"
cp dist/linux/rigelengine.desktop "$pkgdir/usr/share/applications"
# copy over the icons from the dist directory
mkdir -p "$pkgdir/usr/share/icons"
cp dist/linux/rigelengine_128.png "$pkgdir/usr/share/icons"
# add icon path to the desktop entry
echo Icon=/usr/share/icons/rigelengine_128.png >> "$pkgdir/usr/share/applications/rigelengine.desktop"
}
check() {
cd "$_source_dir"
ctest --test-dir build --output-on-failure
}
|