makedeb


tuxkart 0.4.0-1


The ancestor of SuperTuxKart.

Viewing /PKGBUILD.

View raw.

Click here to go back to the Git tree for tuxkart.

# Maintainer: exponential <echo ZXhwb25lbnRpYWxtYXRyaXhAcHJvdG9ubWFpbC5jb20K | base64 -d>

_name=TuxKart
pkgname=tuxkart
pkgver=0.4.0
pkgrel=1
pkgdesc="The ancestor of SuperTuxKart."
arch=('amd64')
url="http://tuxkart.sourceforge.net/"
license=('GPL2')
depends=('libplib1' 'libxmu6')
# osspd renders the game unplayable on slow CPUs,
# it can also block computer shutdown.
# aoss/alsa-oss and padsp (pulse audio) don't work here.
optdepends=('osspd: inefficient and buggy sound compatibility layer')
makedepends=('libplib-dev' 'libxmu-dev')
source=("http://$pkgname.sourceforge.net/dist/$pkgname-$pkgver.tar.gz")
b2sums=('36b188cbba2f6bee07b3c2e32da13dfb0372b291d47e10d15049571ad2e9114bec79e5418353928b76fb85f7d4ba36a3a8612f1acf7e0b8e454e7f4410cf5fb5')

build() {
  cd ${srcdir}/$pkgname-$pkgver

export _DESKTOPFILE="[Desktop Entry]
Version=1.0
Type=Application
Name=$_name
Comment=$pkgdesc
Exec=$pkgname
Icon=$pkgname
Terminal=false
StartupNotify=false
Categories=Game;ActionGame;"

  CXXFLAGS=-fPIC CFLAGS='-fPIC' LDFLAGS=-fPIC ./configure --prefix=/usr
  make
}

package() {
  cd ${srcdir}/$pkgname-$pkgver

  make DESTDIR="${pkgdir}" install

  install -m0644 -d "$pkgdir/usr/share/applications/"
  echo "$_DESKTOPFILE" > "$pkgdir/usr/share/applications/$pkgname.desktop"
  install -dm644 "$pkgdir/usr/share/pixmaps/"
  ln -sf "/usr/share/doc/$pkgname/$pkgname/title_screen.png" "$pkgdir/usr/share/pixmaps/$pkgname.png"

  install -D -m644 COPYING ${pkgdir}/usr/share/doc/$pkgname/COPYING
  install -D -m644 CHANGES ${pkgdir}/usr/share/doc/$pkgname/changelog
  install -D -m644 README ${pkgdir}/usr/share/doc/$pkgname/readme
  install -D -m644 AUTHORS ${pkgdir}/usr/share/doc/$pkgname/authors

  gzip ${pkgdir}/usr/share/doc/$pkgname/changelog

  mv "$pkgdir/usr/share/$pkgname" "$pkgdir/usr/share/doc/$pkgname/"
}