blob: 1a9796c4537b2a1e941ecde4e3d3bc695f728497 (
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
56
57
58
59
60
61
62
63
|
pkgname=bgfx-git
pkgver=r7631.741028840
pkgrel=1
pkgdesc="Cross-platform, graphics API agnostic, \"Bring Your Own Engine/Framework\" style rendering library."
arch=('x86_64')
url="https://bkaradzic.github.io"
license=('BSD')
depends=('mesa' 'libx11')
makedepends=('git')
conflicts=("${pkgname%-git}")
provides=("${pkgname%-git}")
source=('git://github.com/bkaradzic/bx.git'
'git://github.com/bkaradzic/bimg.git'
'git://github.com/bkaradzic/bgfx.git')
sha256sums=('SKIP' 'SKIP' 'SKIP')
pkgver() {
cd "${srcdir}/${pkgname%-git}"
printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
}
build() {
cd "${srcdir}/${pkgname%-git}"
if [ `check_option debug`=y ]
then
make linux-debug64
else
make linux-release64
fi
}
package() {
cd "${srcdir}/${pkgname%-git}"
CONFIG=Release
if [ `check_option debug`=y ]
then
CONFIG=Debug
fi
install -D .build/linux64_gcc/bin/libbgfx-shared-lib${CONFIG}.so ${pkgdir}/usr/lib/libbgfx.so
install -dm755 ${pkgdir}/usr/include
for PROJ in bx bimg bgfx
do
cp -r ${srcdir}/${PROJ}/include ${pkgdir}/usr
done
# add shader includes to include
install -m644 src/bgfx_shader.sh ${pkgdir}/usr/include/bgfx/
install -m644 src/bgfx_compute.sh ${pkgdir}/usr/include/bgfx/
# prepend bgfx to bin names to avoid naming conflicts
for BIN in geometryc geometryv shaderc texturec texturev
do
install -D .build/linux64_gcc/bin/${BIN}${CONFIG} ${pkgdir}/usr/bin/bgfx-${BIN}
done
# remove helper and 3rdparty includes used to compile bgfx
rm -rf ${pkgdir}/usr/include/compat
rm -rf ${pkgdir}/usr/include/tinystl
}
# vim:set ts=2 sw=2 et:
|