desktop/torcs/PKGBUILD

62 lines
1.5 KiB
Bash
Raw Normal View History

2012-02-25 06:40:47 +08:00
pkgbase=torcs
2016-01-15 07:55:47 +08:00
pkgname=('torcs' 'torcs-data')
pkgver=1.3.6
2013-11-16 02:53:53 +08:00
pkgrel=1
2012-02-25 06:40:47 +08:00
pkgdesc="A 3D racing cars simulator"
url="http://torcs.sourceforge.net"
license=("GPL2")
2016-01-15 07:55:47 +08:00
arch=('x86_64')
depends=('freealut' 'freeglut' 'libpng' 'libvorbis' 'libxi' 'libxmu' 'libxrandr' 'glu')
makedepends=('plib' 'mesa')
2012-02-25 06:40:47 +08:00
options=('!makeflags')
2012-03-07 19:00:46 +08:00
categories=('games')
2012-02-25 06:40:47 +08:00
source=(http://downloads.sourceforge.net/sourceforge/$pkgname/$pkgname-$pkgver.tar.bz2)
2016-01-15 07:55:47 +08:00
sha256sums=('193cb1820170eb18335dffeaa345499229a4b7972a78acbfaca197597a3075af')
2012-02-25 06:40:47 +08:00
build() {
cd $srcdir/$pkgname-$pkgver
unset LDFLAGS
./configure \
2012-03-20 09:28:41 +08:00
--datadir=/usr/share/$pkgbase \
2012-02-25 06:40:47 +08:00
--prefix=/usr \
2012-03-20 09:28:41 +08:00
--localstatedir=/usr/var/$pkgbase \
2012-02-25 06:40:47 +08:00
--x-includes=/usr/include \
--x-libraries=/usr/lib
make
}
package_torcs() {
depends=(${depends[@]} "torcs-data=$pkgver")
2012-10-20 05:12:09 +08:00
cd $srcdir/$pkgbase-$pkgver
2012-02-25 06:40:47 +08:00
# Basic installation
make DESTDIR=${pkgdir} install
# Desktop Integration.
install -Dm644 Ticon.png $pkgdir/usr/share/pixmaps/$pkgbase.png
install -Dm644 $pkgbase.desktop ${pkgdir}/usr/share/applications/$pkgbase.desktop
# Fix permissions.
find ${pkgdir} -type d -exec chmod 755 {} \;
2012-03-20 09:28:41 +08:00
# Fix library files destination.
mv $pkgdir/usr/lib/$pkgbase/lib/* $pkgdir/usr/lib/
rmdir $pkgdir/usr/lib/$pkgbase/lib
2012-02-25 06:40:47 +08:00
}
package_torcs-data() {
pkgdesc="Data files for TORCS."
arch=(any)
depends=()
makedepends=()
2012-02-25 06:40:47 +08:00
2012-10-20 05:12:09 +08:00
cd $srcdir/$pkgbase-$pkgver
2012-02-25 06:40:47 +08:00
# Data installation.
make DESTDIR=${pkgdir} datainstall
find ${pkgdir} -type d -exec chmod 755 {} \;
}