blob: fb0e3eea6799a24105fe1f4fa76cf90556d33a1b (
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
|
# Maintainer: Arthur HUGEAT <hugeat dot arthur at gmail dot com>
pkgname=gf-git
pkgver=1.0.0.r1607.877e07e
pkgrel=1
pkgdesc="Gamedev Framework (gf) is a framework to build 2D games in C++17. It is based on SDL and OpenGL ES 2.0, and presents an API that is very similar to the graphics module of SFML with additional features (development version)."
arch=('x86_64' 'i686')
url="https://gamedevframework.github.io/"
license=('ZLIB')
depends=('sdl2' 'boost-libs' 'freetype2' 'zlib' 'pugixml')
makedepends=('boost' 'cmake' 'git')
provides=('gf')
conflicts=('gf')
source=("git+https://github.com/GamedevFramework/gf")
sha256sums=('SKIP')
pkgver() {
VERSION=$(grep " VERSION" gf/CMakeLists.txt | tr -s " " | cut -f 3 -d " ")
echo "${VERSION}.r$(git -C gf rev-list --count HEAD).$(git -C gf rev-parse --short HEAD)"
}
prepare() {
cd "${srcdir}/gf"
git checkout master
git submodule update --init
}
build() {
cd "${srcdir}/gf"
cmake -DGF_DEBUG=OFF \
-DGF_BUILD_EXAMPLES=OFF \
-DGF_BUILD_DOCUMENTATION=OFF \
-DGF_BUILD_GAMES=OFF \
-DGF_USE_EMBEDDED_LIBS=ON \
-DGF_SINGLE_COMPILTATION_UNIT=ON \
-DCMAKE_BUILD_TYPE=Release \
-DCMAKE_INSTALL_PREFIX=/usr \
-S ${srcdir}/gf \
-B ${srcdir}/build
cmake --build ${srcdir}/build --parallel
}
check() {
ctest --test-dir ${srcdir}/build/tests
}
package() {
cmake --install ${srcdir}/build --prefix ${pkgdir}/usr
mv ${pkgdir}/usr/share/doc/GF ${pkgdir}/usr/share/doc/gf
install -Dm644 ${srcdir}/gf/LICENSE.txt ${pkgdir}/usr/share/licenses/${pkgname}/LICENSE.txt
}
|