desktop/supertuxkart/PKGBUILD
2012-03-07 11:00:46 +00:00

61 lines
1.9 KiB
Bash
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

#
# Games Packages for Chakra, part of chakra-project.org
#
# Maintainer: Adrián Chaves Fernández (Gallaecio) <adriyetichaves gmail.com>
pkgname=supertuxkart
_pkgname=SuperTuxKart
pkgver=0.7.3
pkgrel=2
pkgdesc="Kart racing game featuring Tux and friends."
url="http://supertuxkart.sourceforge.net/"
arch=('i686' 'x86_64')
license=('GPL3' 'GPL2' 'CCPL-by' 'CCPL-by-sa' 'custom:Creative Commons Sampling Plus 1.0' 'custom:SoundSnap license' 'custom:Public Domain')
depends=('bzip2' 'enet' 'freeglut' 'irrlicht' 'libgl' 'libjpeg' 'libogg' 'libpng' 'libvorbis' 'openal')
conflicts=('supertuxkart-svn')
categories=('games')
changelog=ChangeLog
source=("http://downloads.sourceforge.net/project/${pkgname}/${_pkgname}/${pkgver}/${pkgname}-${pkgver}-src.tar.bz2")
md5sums=('502664b2ec9ad5ab88b1882fef4c074d')
build() {
cd "${srcdir}/${pkgname}-${pkgver}"
LDFLAGS="-lpng -ljpeg" \
LIBS="-lbz2" \
./configure \
--prefix=/usr \
--datadir=/usr/share
make
}
package() {
cd "${srcdir}/${pkgname}-${pkgver}"
make DESTDIR="${pkgdir}" install
# Add executable link from /usr/bin.
mkdir -p "${pkgdir}/usr/bin"
echo '#!/bin/bash' > "${pkgdir}/usr/bin/${pkgname}"
echo "/usr/games/${pkgname} \"\${@}\"" >> "${pkgdir}/usr/bin/${pkgname}"
chmod +x "${pkgdir}/usr/bin/${pkgname}"
# Set right game version in .desktop file.
sed -i -e "s/0.5/${pkgver}/" "${pkgdir}/usr/share/applications/${pkgname}.desktop"
# Remove AUTHORS file from documentation folder.
rm "${pkgdir}/usr/share/doc/${pkgname}/AUTHORS"
# Create license folder.
install -d "${pkgdir}/usr/share/licenses/${pkgname}"
# Link credits from license folder.
ln -s "${pkgdir}/usr/share/games/${pkgname}/data/CREDITS" "${pkgdir}/usr/share/licenses/${pkgname}/AUTHORS"
# Move license from documentation folder to license folder.
mv "${pkgdir}/usr/share/doc/${pkgname}/COPYING" "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
}
# vim:set ts=2 sw=2 et: