diff options
author | Márcio Alexandre Silva Delgado <coadde@lavabit.com> | 2013-03-08 06:17:46 -0200 |
---|---|---|
committer | Márcio Alexandre Silva Delgado <coadde@lavabit.com> | 2013-03-08 06:17:46 -0200 |
commit | 84afef49fb98338992aa7fd00d86728fd44ddd9a (patch) | |
tree | 9b8e10fd23c1fe7b4bc28e9cfa71b993d8a3200c /pcr | |
parent | 4c9bb54c04602e83b1bd709f971745f654c1c2d5 (diff) |
yafaray-git: updating pkg
Diffstat (limited to 'pcr')
-rw-r--r-- | pcr/yafaray-git/PKGBUILD | 159 | ||||
-rw-r--r-- | pcr/yafaray-git/gcc47.patch | 10 |
2 files changed, 105 insertions, 64 deletions
diff --git a/pcr/yafaray-git/PKGBUILD b/pcr/yafaray-git/PKGBUILD index 0c5d4f6e4..e60fe8324 100644 --- a/pcr/yafaray-git/PKGBUILD +++ b/pcr/yafaray-git/PKGBUILD @@ -1,78 +1,129 @@ -# Maintainer: Lukas Jirkovsky <l.jirkovsky@gmail.com> -# Maintainer (Parabola): Márcio Silva <coadde@adinet.com.uy> -pkgname=yafaray-git -_blendver=2.62 -pkgver=20120420 +# $Id$ +# Maintainer: Márcio Silva <coadde@lavabit.com> + +pkgbase=yafaray +pkgname=( + yafaray-git + yafaray-blender-exporter-git +) +_pkgflag=git +pkgver=$(LC_ALL=C date -u +%Y%m%d) +_pkgver=1.2 +_bldver=2.66 +_bldepoch=6 +_pyver=3.3 pkgrel=1 -pkgdesc="A libre software raytracing engine" -arch=('i686' 'x86_64') -url="http://www.yafaray.org/" -license=('LGPL2.1') -depends=('libxml2' 'openexr' 'libjpeg') -optdepends=('qt: QT GUI' 'python: Python bindings, Blender exporter') -makedepends=('cmake' 'git' 'qt' 'swig' 'python') -provides=('yafaray') -conflicts=('yafaray') -source=('gcc47.patch') -md5sums=('d99eb7db30885549687a8f7a775a582d') - -_gitroot=git://github.com/YafaRay/Core.git -_gitname=yafaray -_gitrootexport=git://github.com/YafaRay/Blender-2.5-Exporter.git +pkgdesc='A libre software raytracing engine' +arch=( + i686 + x86_64 + mips64el +) +url="http://www.$pkgbase.org" +license=LGPL2.1 +depends=( + freetype2 + libjpeg + libxml2 + openexr +) +optdepends=( + 'python: Python bindings' + 'qt4: QT GUI' + #'ruby: Ruby bindings' + 'yafaray-blender-exporter-git: Blender exporter' +) +makedepends=( + cmake + git + python + qt4 + #ruby-headers + swig +) +provides=( + $pkgbase=$_pkgver +) +conflicts=$pkgbase + +_gitroot="https://github.com/YafaRay/Core.git" +_gitname=$pkgbase +_gitrootexport="https://github.com/YafaRay/Blender-Exporter.git" _gitnameexport=exporter build() { - cd "$srcdir" - msg "Connecting to GIT server...." + cd $srcdir + msg 'Connecting to GIT server....' # core - if [[ -d "$_gitname" ]]; then - cd "$_gitname" && git pull origin + if [[ -d $_gitname ]]; then + cd $_gitname && git pull origin cd .. - msg "The local files are updated." + msg 'The local files are updated.' else - git clone "$_gitroot" "$_gitname" + git clone $_gitroot $_gitname fi # exporter - if [[ -d "$_gitnameexport" ]]; then - cd "$_gitnameexport" && git pull origin + if [[ -d $_gitnameexport ]]; then + cd $_gitnameexport && git pull origin cd .. - msg "The local files are updated." + msg 'The local files are updated.' else - git clone "$_gitrootexport" "$_gitnameexport" + git clone $_gitrootexport $_gitnameexport fi - msg "GIT checkout done or server timeout" - msg "Starting build..." + msg 'GIT checkout done or server timeout' + msg 'Starting build...' - if [ -e "$srcdir"/$_gitname-build ]; then - rm -rf "$srcdir"/$_gitname-build + if [ -e $srcdir/$_gitname-build ]; then + rm -rf $srcdir/$_gitname-build fi - mkdir "$srcdir/$_gitname-build" + mkdir $srcdir/$_gitname-build + cd $srcdir/$_gitname-build - patch -Np0 -i "$srcdir/gcc47.patch" + setarch $CARCH cmake -DCMAKE_INSTALL_PREFIX=/usr\ + -DYAF_PY_VERSION=$_pyver\ + -DYAF_BINDINGS_PY_DIR=/usr/lib/python$_pyver\ + ../$_gitname - cd "$srcdir/$_gitname-build" + #-DWITH_YAF_PY_BINDINGS=ON\ + #-DBLENDER_ADDON=ON\ + #-DBLENDER_EXPORTER_BRANCH=master\ + #-DWITH_YAF_RUBY_BINDINGS=ON\ + #-DYAF_USER_INCLUDE_DIRS=/usr/include/ruby-1.9.1/$CARCH-linux\ + + setarch $CARCH make +} - cmake -DCMAKE_INSTALL_PREFIX=/usr \ - -DYAF_PY_VERSION=3.2 \ - -DYAF_BINDINGS_PY_DIR=/usr/lib/python3.2 \ - "../$_gitname" - make +package_yafaray-git() { + cd $srcdir/$_gitname-build + setarch $CARCH make DESTDIR=$pkgdir install } -package() { - cd "$srcdir/$_gitname-build" - make DESTDIR="$pkgdir/" install - - # install exporter - cd "$srcdir/$_gitnameexport" - git checkout-index -a -f --prefix="$pkgdir/usr/share/blender/$_blendver/scripts/addons/yafaray/" - # create symlinks to make exporter fully work - install -d -m755 "$pkgdir/usr/share/blender/$_blendver/scripts/addons/yafaray/bin" - ln -sf "/usr/lib/libyafaraycore.so" "$pkgdir/usr/share/blender/$_blendver/scripts/addons/yafaray/bin/libyafaraycore.so" - ln -sf "/usr/lib/libyafarayplugin.so" "$pkgdir/usr/share/blender/$_blendver/scripts/addons/yafaray/bin/libyafarayplugin.so" - ln -sf "/usr/lib/yafaray" "$pkgdir/usr/share/blender/$_blendver/scripts/addons/yafaray/bin/plugins" +package_yafaray-blender-exporter-git() { + pkgver=$pkgver.v$_bldver + pkgdesc='YafaRay exporter for Blender' + arch=any + depends=( + $pkgbase=$pkgver + "blender>=$_bldepoch:$_bldver" + ) + provides=( + ${pkgname[1]%-$_pkgflag}=$_pkgver.v$_bldver + ) + conflicts=${pkgname[1]%-$_pkgflag} + + cd $srcdir/$_gitnameexport + + a=/usr/lib + b=usr/share/blender/$bldver/scripts/addon/$pkgbase/bin + + git checkout-index -a -f --prefix=$pkgdir/${b%bin} + + install -d -m755 $pkgdir/$b + ln -sf $a/lib${pkgbase}core.so $pkgdir/$b/lib${pkgbase}core.so + ln -sf $a/lib${pkgbase}plugin.so $pkgdir/$b/lib${pkgbase}plugin.so + ln -sf $a/$pkgbase $pkgdir/$b/plugins } # vim:set ts=2 sw=2 et: diff --git a/pcr/yafaray-git/gcc47.patch b/pcr/yafaray-git/gcc47.patch deleted file mode 100644 index 75775498b..000000000 --- a/pcr/yafaray-git/gcc47.patch +++ /dev/null @@ -1,10 +0,0 @@ ---- yafaray.orig/src/yafraycore/scene.cc 2012-04-18 00:03:16.508415920 -0300 -+++ yafaray/src/yafraycore/scene.cc 2012-04-18 00:29:59.090117108 -0300 -@@ -39,6 +39,7 @@ - #include <iostream> - #include <limits> - #include <sstream> -+#include <unistd.h> - - __BEGIN_YAFRAY - |