blob: 4aa4798fdd62f7b3e086711eba6425dae895f8a3 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
|
# Maintainer: Márcio Silva <coadde@parabola.nu>
_pkgname=yafaray
_pkgver=1.5
_pkgrel=1
_pkgdate=20140508
_bldname=blender
_bldver=2.71
_bldep=12
_gitname=Core
_addname=${_bldname^}-Exporter
_addrel=1
_adddate=20140425
_pyver=3.4
# Thu May 8 12:59:36 2014 +0200 - Add support for read 'curve' objects on .xml scene files
_srcver=ff262af4b50a90dcf39da04040b53509d7dc789d
# Fri Apr 25 21:43:23 2014 +0200 - Fix progress bar, Now, Blender use same range to YafaRay
_addver=c3d4ff74593d5bd9552306f597f6b36e342687da
pkgname=(
$_pkgname
$_bldname-addon-$_pkgname
)
pkgver=$_pkgver.$_pkgdate
pkgrel=$_pkgrel
pkgdesc='A free software raytracing engine'
arch=(
mips64el
x86_64
i686
)
url=http://www.$_pkgname.org
license=LGPL2.1
depends=(
freetype2
libjpeg
libxml2
openexr
)
optdepends=(
'python: Python bindings'
'qt4: QT GUI'
"${pkgname[1]}: ${_bldname^} addon renderer"
)
makedepends=(
cmake
git
python
qt4
swig
)
source=(
$_gitname-$_srcver.tar.gz::https://github.com/YafaRay/$_gitname/archive/$_srcver.tar.gz
$_addname-$_addver.tar.gz::https://github.com/YafaRay/$_addname/archive/$_addver.tar.gz
)
sha512sums=(
089373ebe702361ccd5a8b8ee789188bdb569338f0f406f2fe5e355ef69d2de5f793a5b9e5f85e998fd0b5a42500124d0d35bffee00d177e710347a1a107228e
38b85b14ccf0042012de0e8791ed9264ff389b223ef033f2c9daeccb0388a483c38f9a8aa178819183795ff5dd37c5cdd201f2af23d5e28231bffad7deecd523
)
prepare() {
cd $srcdir/$_gitname-$_srcver
msg 'Renaming addon dir'
mv -v $srcdir/$_addname-$_addver $srcdir/$_pkgname
msg 'renaming wrong OS name'
sed -i 's|Linux|GNU/Linux|
' $srcdir/$_pkgname/prop/yaf_scene.py
[[ -d build ]] && rm -vr build
mkdir -v build
}
build() {
cd $srcdir/$_gitname-$_srcver/build
cmake .. -DCMAKE_INSTALL_PREFIX=/usr\
-DYAF_PY_VERSION=$_pyver\
-DYAF_BINDINGS_PY_DIR=/usr/lib/python$_pyver
make
}
package_yafaray() {
cd $srcdir/$_gitname-$_srcver/build
make DESTDIR=$pkgdir install
}
package_blender-addon-yafaray() {
pkgdesc="A addon for the ${_bldname^} which allows render with YafaRay (built for the $_bldname-libre package)"
arch=any
depends=(
$_pkgname=$pkgver
"$_bldname-libre>=$_bldep:$_bldver"
"$_bldname-libre<$(($_bldep+1)):${_bldver::2}$((${_bldver:2:4}+1))"
)
pkgver=$_pkgver.$_adddate.v$_bldver
pkgrel=$_addrel
optdepends=
cd $srcdir
a=/usr/lib
b=$pkgdir/usr/share/$_bldname/$_bldver/scripts/addons/$_pkgname/bin
install -vd $b && cp -a $_pkgname ${b%$_pkgname/bin}
ln -vsf $a/lib${_pkgname}core.so $b/lib${_pkgname}core.so
ln -vsf $a/lib${_pkgname}plugin.so $b/lib${_pkgname}plugin.so
ln -vsf $a/$_pkgname $b/plugins
}
# vim:set ts=2 sw=2 et:
|