desktop/speed-dreams/PKGBUILD

81 lines
3.0 KiB
Bash
Raw Normal View History

2012-04-27 09:29:06 +08:00
pkgbase=speed-dreams
pkgname=('speed-dreams' 'speed-dreams-data')
2016-06-09 08:33:57 +08:00
pkgver=2.2.1
_pkgver=2.2.1-r6404
2015-04-23 08:08:29 +08:00
pkgrel=1
2012-04-27 09:29:06 +08:00
pkgdesc="A racing simulator with rich graphics and physics"
2015-04-23 08:08:29 +08:00
arch=('x86_64')
2011-02-10 02:44:43 +08:00
url="http://speed-dreams.sourceforge.net/"
license=('GPL2')
2015-04-23 08:08:29 +08:00
depends=('enet' 'freeglut' 'glu' 'libgl' 'libjpeg' 'libpng' 'libxi' 'libxmu'
2016-06-09 08:33:57 +08:00
'libxrandr' 'openal' 'plib' 'sdl2' 'zlib' 'libogg' 'libvorbis' 'enet' 'openscenegraph')
2015-04-23 08:08:29 +08:00
makedepends=('cmake' 'mesa' 'tar')
2012-03-07 19:00:46 +08:00
categories=('games')
2015-04-23 08:08:29 +08:00
noextract=("${pkgname}-src-base-${_pkgver}.tar.xz"
"${pkgname}-src-unmaintained-${_pkgver}.tar.xz"
"${pkgname}-src-wip-cars-and-tracks-${_pkgver}.tar.xz"
"${pkgname}-src-hq-cars-and-tracks-${_pkgver}.tar.xz"
"${pkgname}-src-more-hq-cars-and-tracks-${_pkgver}.tar.xz")
source=("http://downloads.sourceforge.net/sourceforge/${pkgname}/${pkgname}-src-base-${_pkgver}.tar.xz"
"http://downloads.sourceforge.net/sourceforge/${pkgname}/${pkgname}-src-unmaintained-${_pkgver}.tar.xz"
"http://downloads.sourceforge.net/sourceforge/${pkgname}/${pkgname}-src-wip-cars-and-tracks-${_pkgver}.tar.xz"
"http://downloads.sourceforge.net/sourceforge/${pkgname}/${pkgname}-src-hq-cars-and-tracks-${_pkgver}.tar.xz"
"http://downloads.sourceforge.net/sourceforge/${pkgname}/${pkgname}-src-more-hq-cars-and-tracks-${_pkgver}.tar.xz"
"${pkgname}.desktop")
2016-06-09 08:33:57 +08:00
md5sums=('a1a296ab737d5144f1f570f4cabc7937'
'0a9b1572d0660c60fa0553195578a36a'
'3413d9d5e2111cd9e87628df5818d2b4'
'e4efd3b16e53a54c23e606947739abe5'
'b6079ca11202595ac312a28262e793ee'
2015-04-23 08:08:29 +08:00
'634f8cb8f4f96686c8049c8a025e72d0')
2011-02-10 02:44:43 +08:00
2015-04-23 08:08:29 +08:00
prepare() {
# extract these manually as bsdtar can't handle these
tar xf "${pkgname}-src-base-${_pkgver}.tar.xz"
tar xf "${pkgname}-src-unmaintained-${_pkgver}.tar.xz"
tar xf "${pkgname}-src-wip-cars-and-tracks-${_pkgver}.tar.xz"
tar xf "${pkgname}-src-hq-cars-and-tracks-${_pkgver}.tar.xz"
tar xf "${pkgname}-src-more-hq-cars-and-tracks-${_pkgver}.tar.xz"
}
build() {
cmake . \
-DCMAKE_BUILD_TYPE=Release \
-DCMAKE_INSTALL_PREFIX=/usr \
-DSD_BINDIR=/usr/bin \
-DOPTION_OFFICIAL_ONLY=ON \
-DSD_LOCALDIR=~/.speed-dreams \
-DSD_DATADIR=/usr/share/speed-dreams-2 \
-DSD_LIBDIR=/usr/lib/speed-dreams-2
2011-02-10 02:44:43 +08:00
make
}
2012-04-27 09:29:06 +08:00
package_speed-dreams() {
depends=(${depends[@]} speed-dreams-data)
2015-04-23 08:08:29 +08:00
make DESTDIR="${pkgdir}/" install
rm -r "${pkgdir}/usr/share"
install -Dm644 "data/data/icons/icon.png" "${pkgdir}/usr/share/pixmaps/speed-dreams.png"
install -Dm644 "${srcdir}/${pkgname}.desktop" "${pkgdir}/usr/share/applications/speed-dreams.desktop"
mkdir -p "${pkgdir}/usr/share/doc/${pkgname}"
cp -r doc/* "${pkgdir}/usr/share/doc/${pkgname}/"
# Symlink for backwards compatibility
cd "${pkgdir}/usr/bin"
ln -s speed-dreams-2 speed-dreams
2012-04-27 09:29:06 +08:00
}
2012-04-27 09:29:06 +08:00
package_speed-dreams-data() {
depends=()
pkgdesc="$pkgdesk (data files)"
2015-04-23 08:08:29 +08:00
make DESTDIR="${pkgdir}/" install
rm -r "${pkgdir}/usr/bin"
rm -r "${pkgdir}/usr/lib"
rm -r "${pkgdir}/usr/include"
2011-02-10 02:44:43 +08:00
}