summaryrefslogtreecommitdiff
path: root/libre/ogre-libre/PKGBUILD
diff options
context:
space:
mode:
authorLuke Shumaker <LukeShu@sbcglobal.net>2012-10-30 17:08:15 -0400
committerLuke Shumaker <LukeShu@sbcglobal.net>2012-10-30 17:08:15 -0400
commit1b8188ff873b23894883d31cb4ed2eb6c54e8d99 (patch)
tree86f31948151593f423c11fa65c66e754479ca9cc /libre/ogre-libre/PKGBUILD
parent32d8494f058ded2edb7663eb011ae4d168b0efd4 (diff)
parented68dfd7e006d795685ea7d7e934a2268339fffa (diff)
downloadabslibre-1b8188ff873b23894883d31cb4ed2eb6c54e8d99.tar.gz
abslibre-1b8188ff873b23894883d31cb4ed2eb6c54e8d99.tar.bz2
abslibre-1b8188ff873b23894883d31cb4ed2eb6c54e8d99.zip
Merge branch 'master' of ssh://parabolagnulinux.org:1863/srv/git/abslibre
Diffstat (limited to 'libre/ogre-libre/PKGBUILD')
-rw-r--r--libre/ogre-libre/PKGBUILD131
1 files changed, 131 insertions, 0 deletions
diff --git a/libre/ogre-libre/PKGBUILD b/libre/ogre-libre/PKGBUILD
new file mode 100644
index 000000000..673ee8435
--- /dev/null
+++ b/libre/ogre-libre/PKGBUILD
@@ -0,0 +1,131 @@
+# $Id$
+# Maintainer: Sven-Hendrik Haase <sh@lutzhaase.com>
+# Maintainer (Parabola): Márcio Silva <coadde@lavabit.com>
+
+pkgbase=ogre
+pkgname=(
+ ogre-libre
+ #ogre-docs
+)
+pkgver=1.8.1
+pkgrel=2
+pkgdesc='A scene-oriented, flexible 3D engine written in C++, without nonfree nvidia-cg-toolkit support'
+arch=(
+ i686
+ x86_64
+ mips64el
+)
+url="http://www.${pkgbase}3d.org"
+license=(
+ 'custom:MIT'
+)
+depends=(
+ boost-libs
+ freeimage
+ freetype2
+ libxaw
+ libxrandr
+ zziplib
+ ois
+ glu
+)
+makedepends=(
+ boost
+ cmake
+ doxygen
+ graphviz
+ ttf-dejavu
+ mesa
+)
+install=$pkgbase.install
+source=(
+ "https://downloads.sourceforge.net/$pkgbase/${pkgbase}_src_v${pkgver//./-}.tar.bz2"
+)
+sha512sums=(
+ 0bbce593e5a9ebf51e3cb53661f6447d99ae28a53365d7f518c6d408216690527ef7552385160cff8d5c3ef15d3ab5c2520ef2c1f51fda5541d5d4dca4663ae2
+)
+
+build() {
+ cd $srcdir/${pkgbase}_src_v${pkgver//./-}
+
+ # get a clean build dir
+ [[ -d build ]] && rm -rf build
+ mkdir build && cd build
+
+ # generate CMake Makefile
+ cmake .. \
+ -DCMAKE_INSTALL_PREFIX=/usr \
+ -D${pkgbase^^}_INSTALL_PLUGINS_HEADERS=TRUE \
+ -D${pkgbase^^}_INSTALL_SAMPLES=TRUE \
+ -D${pkgbase^^}_INSTALL_DOCS=TRUE \
+ -D${pkgbase^^}_INSTALL_MEDIA=TRUE \
+ -D${pkgbase^^}_INSTALL_SAMPLES_SOURCE=TRUE \
+ -DCMAKE_BUILD_TYPE=Release # set =Debug for debugging version
+
+ # compile
+ make
+
+ # generate docs
+ if [[ $(which dot) && $(which doxygen) ]]; then
+ make doc
+ fi
+}
+
+package_ogre-libre() {
+ optdepends=(
+ 'cppunit: unit testing'
+ 'intel-tbb: better threading support'
+ 'poco: portability'
+ "boost: for developing using $pkgbase"
+ "$pkgbase-docs: documentation"
+ )
+ provides=(
+ $pkgbase=$pkgver
+ )
+ conflicts=(
+ $pkgbase
+ )
+ replaces=(
+ $pkgbase
+ )
+
+ cd $srcdir/${pkgbase}_src_v${pkgver//./-}/build
+
+ # install the bugger
+ make DESTDIR=$pkgdir install
+
+ # fix up samples
+ install -dm775 -o root -g users $pkgdir/opt/${pkgbase^^}/samples
+ mv $pkgdir/usr/share/${pkgbase^^}/*.cfg $pkgdir/opt/${pkgbase^^}/samples
+ mv $pkgdir/usr/bin/SampleBrowser $pkgdir/opt/${pkgbase^^}/samples
+
+ # make sample launcher
+ echo '#!/bin/bash' > $pkgdir/usr/bin/${pkgbase^}SampleBrowser
+ echo 'cd /opt/${pkgbase^^}/samples && ./SampleBrowser' >> $pkgdir/usr/bin/${pkgbase^}SampleBrowser
+ chmod +x $pkgdir/usr/bin/${pkgbase^}SampleBrowser
+
+ # install license
+ install -Dm644 ../Docs/License.html $pkgdir/usr/share/licenses/$pkgbase/license.html
+
+ # move docs out of this package
+ mv $pkgdir/usr/share/${pkgbase^^}/docs $srcdir/docs
+}
+
+package_ogre-docs() {
+ pkgdesc="Documentation for $pkgbase"
+ depends=(
+ )
+
+ cd $srcdir/${pkgbase}_src_v${pkgver//./-}/build
+
+ # move docs into this package
+ install -dm755 $pkgdir/usr/share/doc
+ mv $srcdir/docs $pkgdir/usr/share/doc/${pkgbase^^}
+
+ # symlink for docs
+ install -dm755 $pkgdir/usr/share/${pkgbase^^}
+ cd $pkgdir/usr/share
+ ln -s doc/${pkgbase^^} ${pkgbase^^}/docs
+}
+
+# vim:set ts=2 sw=2 et: