desktop/box2d/PKGBUILD

45 lines
1.2 KiB
Bash
Raw Normal View History

2012-01-01 03:41:33 +08:00
#
# Games Packages for Chakra, part of chakra-project.org
#
# Maintainer: Adrián Chaves Fernández (Gallaecio) <adriyetichaves@gmail.com>
# Contributor: Zie Evolution <zie.evolution@googlemail.com>
# Contributor: Sven-Hendrik Haase <sh@lutzhaase.com>
pkgname=box2d
2014-07-30 01:53:59 +08:00
pkgver=2.3.0
2012-01-01 03:41:33 +08:00
pkgrel=1
pkgdesc="2D rigid body simulation library for games"
url="http://www.box2d.org/"
license=('zlib')
arch=('i686' 'x86_64')
2014-07-30 01:53:59 +08:00
depends=('libgl')
2012-01-01 03:41:33 +08:00
makedepends=('cmake')
optdepends=()
2014-07-30 01:53:59 +08:00
source=(http://box2d.googlecode.com/files/Box2D_v${pkgver}.7z)
md5sums=('696a457fc6260a9bb6d2c380b9100279')
2012-01-01 03:41:33 +08:00
build() {
2014-07-30 01:53:59 +08:00
cd ${srcdir}/Box2D_v${pkgver}/Box2D
2012-01-01 03:41:33 +08:00
2014-07-30 01:53:59 +08:00
cmake . \
2012-01-01 03:41:33 +08:00
-DBOX2D_INSTALL=ON \
-DBOX2D_BUILD_SHARED=ON \
-DBOX2D_BUILD_STATIC=ON \
-DBOX2D_BUILD_EXAMPLES=OFF \
-DCMAKE_INSTALL_PREFIX=/usr
make
}
package() {
2014-07-30 01:53:59 +08:00
cd ${srcdir}/Box2D_v${pkgver}/Box2D
2012-01-01 03:41:33 +08:00
make DESTDIR=${pkgdir} install
mkdir -p ${pkgdir}/usr/share/doc/box2d/
2014-07-30 01:53:59 +08:00
cp -r Documentation/* ${pkgdir}/usr/share/doc/box2d/
2012-01-01 03:41:33 +08:00
find ${pkgdir}/usr/share/doc/box2d/ -type f | xargs chmod 644
find ${pkgdir}/usr/share/doc/box2d/ -type d | xargs chmod 755
2014-07-30 01:53:59 +08:00
install -Dm644 License.txt ${pkgdir}/usr/share/licenses/box2d/LICENSE
}