1 # Maintainer: Beej Jorgensen <beej@beej.us>
2 # Maintainer: Eric Belanger <belanger@astro.umontreal.ca>
3 # Contributor: Peter Baldwin <bald_pete@hotmail.com>
5 # This was in community, but was dropped due to old age.
10 pkgdesc="Open source multiplayer and singleplayer first person shooter game"
11 arch=('i686' 'x86_64')
12 url="http://www.cubeengine.com/"
14 depends=('sdl_mixer' 'sdl_image' 'mesa' 'libgl' 'enet')
16 backup=(opt/cube/autoexec.cfg opt/cube/servers.cfg)
18 source=(http://downloads.sourceforge.net/sourceforge/cube/${pkgname}_${pkgver}_unix.tar.gz \
19 http://downloads.sourceforge.net/sourceforge/cube/cube_${pkgver}_src.zip \
20 cube.xpm cube.desktop cube.sh cubed.sh LICENSE)
21 md5sums=('e77f3cf85292bf61100d2f8511a254cc' 'e376c49ac209b095cb6d29490834d060'\
22 'd8c1368a2ac729e168fe3dac7e7bd284' 'a09afc0facfb3f048bcc4d9377af3189'\
23 '6a2fb52692891df61fc8d240869a5b2e' 'a5f6262cc6274f1a5c244ea0999d13de'\
24 'f4d9ce2d2b79983f1ef221929cd86a5f')
28 # cd ${srcdir}/cube_source/enet
30 # ./configure --prefix=/usr
35 # trying to use system enet instead of bundled - does not work
36 # sed -i 's|\.\./enet/include|/usr/include/enet|g' Makefile
37 # sed -i 's|\.\./enet|/usr/lib|g' Makefile
39 # workaround compilation error
40 sed -i 's|pointer|pointer -fpermissive|g' Makefile
46 # so we compiled against bundled enet includes but linked with system enet
47 # I know it is an ugly hack but it's the only way I could build cube
49 install -d ${pkgdir}/opt
50 cp -r ${srcdir}/cube ${pkgdir}/opt
53 touch servers.cfg packages/base/temp.{cfg,cgz}
54 chown root:20 servers.cfg autoexec.cfg packages/base/temp.{cfg,cgz}
55 chown root:20 savegames demos screenshots
56 chmod 664 servers.cfg autoexec.cfg packages/base/temp.{cfg,cgz}
57 chmod 775 savegames demos screenshots
59 install -Dm644 ${srcdir}/cube.desktop ${pkgdir}/usr/share/applications/cube.desktop
60 install -Dm644 ${srcdir}/cube.xpm ${pkgdir}/usr/share/pixmaps/cube.xpm
62 install -D -m755 ${srcdir}/cube.sh ${pkgdir}/usr/bin/cube
63 install -D -m755 ${srcdir}/cubed.sh ${pkgdir}/usr/bin/cubed
64 install -m755 ${srcdir}/cube_source/src/cube_client cube_client
65 install -m755 ${srcdir}/cube_source/src/cube_server cube_server
66 rm -r ${pkgdir}/opt/cube/{bin_unix,cube_unix}
67 install -D -m644 ${srcdir}/LICENSE $pkgdir/usr/share/licenses/$pkgname/LICENSE