desktop/sumwars/PKGBUILD

69 lines
2.1 KiB
Bash
Raw Normal View History

2011-03-08 07:34:37 +08:00
#
# Games Packages for Chakra, part of chakra-project.org
#
# Maintainer: Adrián Chaves Fernández (Gallaecio) <adriyetichaves@gmail.com>
pkgname=sumwars
2013-02-17 06:05:34 +08:00
pkgver=0.5.6
pkgrel=1
2011-03-08 07:34:37 +08:00
pkgdesc="Summoning Wars is a role-playing game, featuring both a single-player and a multiplayer mode for about 2 to 8 players."
arch=('i686' 'x86_64')
url="http://sumwars.org/"
license=('GPL3')
2013-02-17 06:05:34 +08:00
depends=('cegui>=0.7.0' 'freealut' 'libogg' 'libvorbis' 'lua>=5.1.0' 'ogre>=1.7.0' 'ois' 'openal' 'poco')
2012-03-07 19:00:46 +08:00
categories=('games')
2013-02-17 06:05:34 +08:00
source=("http://downloads.sourceforge.net/project/$pkgname/$pkgver/${pkgname}-${pkgver}-src.tar.bz2")
md5sums=('89f53fe1023072785e039bdef312a04b')
2011-03-08 07:34:37 +08:00
build() {
2013-02-17 06:05:34 +08:00
cd $srcdir/${pkgname}-${pkgver}
sed -e "s#TARGET_LINK_LIBRARIES(sumwars \${LINK_LIBS})#TARGET_LINK_LIBRARIES(sumwars \${LINK_LIBS} \"boost_system\")#" -i CMakeLists.txt
mkdir -p build && cd build
2011-03-08 07:34:37 +08:00
cmake \
-DCMAKE_INSTALL_PREFIX=/usr \
-DCMAKE_BUILD_TYPE=RelWithDebInfo \
..
make
}
package() {
2013-02-17 06:05:34 +08:00
cd $srcdir/${pkgname}-${pkgver}
2011-03-08 07:34:37 +08:00
#make install is broken
#make DESTDIR=$pkgdir install
2013-02-17 06:05:34 +08:00
# Executable.
install -Dm755 build/$pkgname $pkgdir/usr/share/$pkgname/$pkgname
# Credits.
install -Dm644 AUTHORS $pkgdir/usr/share/$pkgname/authors.txt
2011-03-08 07:34:37 +08:00
2013-02-17 06:05:34 +08:00
# Savegames.
install -dm775 $pkgdir/usr/share/$pkgname/save
chown :games $pkgdir/usr/share/$pkgname/save
2011-03-08 07:34:37 +08:00
2013-02-17 06:05:34 +08:00
# Desktop Integration.
install -Dm644 share/icon/SumWarsIcon_128x128.png $pkgdir/usr/share/pixmaps/$pkgname.png
install -Dm755 packaging/$pkgname.desktop $pkgdir/usr/share/applications/$pkgname.desktop
sed \
-e "s#/games/#/bin/#g" \
-e "s#icons/hicolor/128x128/$pkgname.png#/pixmaps/$pkgname.png#" \
-i $pkgdir/usr/share/applications/$pkgname.desktop
cp -r share/* $pkgdir/usr/share/$pkgname
for filename in CEGUI Ogre $pkgname; do
touch $pkgdir/usr/share/$pkgname/$filename.log
2011-03-08 07:34:37 +08:00
done
chmod 777 $pkgdir/usr/share/$pkgname/*.log
# Execution script.
2013-02-17 06:05:34 +08:00
install -dm755 $pkgdir/usr/bin
2011-03-08 07:34:37 +08:00
echo "#!/bin/bash" > $pkgdir/usr/bin/$pkgname
echo "cd /usr/share/$pkgname" >> $pkgdir/usr/bin/$pkgname
echo "./$pkgname" >> $pkgdir/usr/bin/$pkgname
chmod 775 $pkgdir/usr/bin/$pkgname
}