summaryrefslogtreecommitdiff
path: root/libre/blender-libre/PKGBUILD
blob: b4d9c47b8f6edce965a9bcdf3dfbc45e8646b662 (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@lavabit.com>

_spacenav=false
_pkgname=blender-libre
_pkgflag=libre
if [ $_spacenav == true ]; then
  pkgname=blender-spacenav-libre
  _spndesc=' (with spacenav support)'
else
  pkgname=blender-libre
  _spndesc=''
fi
epoch=7
pkgver=2.67
_pyver=3.3
pkgrel=1
pkgdesc="Fully integrated 3D graphics creation suite, without nonfree povray and cuda support$_spndesc"
arch=(
  i686
  x86_64
  mips64el
)
license=GPL
url=http://www.${_pkgname%-$_pkgflag}.org
depends=(
  desktop-file-utils
  'ffmpeg=1:1.2'
  fftw #3.3.3
  freetype2 #2.4.11
  hicolor-icon-theme
  'ilmbase=2.0.0'
  jack
  'libpng=1.6.2'
  libtiff #4.0.3
  openal #1.15.1
  'openexr=2.0.0'
  openimageio #1.1.9
  'opencollada=20130413'
  opencolorio #1.0.8
  openshadinglanguage #1.3.0
  shared-mime-info
  xdg-utils
)
if [ $_spacenav == true ]; then
  depends+=(
    libspnav
  )
fi
optdepends=(
  'bullet: for Rigid Bodies and Physics Simulation'
  'xcftools: for import GIMP images to scene (pcr repo)'
)
makedepends=(
  boost
  cmake
  mesa
  subversion
)
provides=(${_pkgname%-$_pkgflag}=$epoch:$pkgver)
conflicts=${_pkgname%-$_pkgflag}
replaces=${_pkgname%-$_pkgflag}
install=$_pkgname.install
source=http://download.${_pkgname%-$_pkgflag}.org/source/${_pkgname%-$_pkgflag}-$pkgver.tar.gz
sha512sums=678ff15b4c7aa5695ac31189c2532d959867dfd003d101a52fc8e294b2d7bc5a4699844db9fa6cc6f5e825aa5ba2da37cec0dc56bfd2686957eca075bf935f44

prepare() {
  mkdir cd $srcdir/${_pkgname%-$_pkgflag}-$pkgver/build
}

build() {
  cd $srcdir/${_pkgname%-$_pkgflag}-$pkgver/build

  [[ $CARCH == i686 ]] && DSUPPORT_SSE2_BUILD='-DSUPPORT_SSE2_BUILD=OFF'

  setarch $CARCH cmake ..\
    -DCMAKE_BUILD_TYPE=Release\
    -DCMAKE_INSTALL_PREFIX=/usr\
    -DOPENIMAGEIO_ROOT_DIR=/usr\
    -DPYTHON_INCLUDE_DIRS=/usr/include/python${_pyver}m\
    -DPYTHON_LIBPATH=/usr/lib\
    -DPYTHON_LIBRARY=python${_pyver}m\
    -DPYTHON_VERSION=${_pyver}\
    $DSUPPORT_SSE2_BUILD\
    -DWITH_CODEC_FFMPEG=ON\
    -DWITH_CODEC_SNDFILE=ON\
    -DWITH_CYCLES=ON\
    -DWITH_CYCLES_CUDA_BINARIES=OFF\
    -DWITH_CYCLES_OSL=ON\
    -DWITH_FFTW3=ON\
    -DWITH_GAMEENGINE=ON\
    -DWITH_IMAGE_REDCODE=OFF\
    -DWITH_INSTALL_PORTABLE=OFF\
    -DWITH_JACK=ON\
    -DWITH_MOD_OCEANSIM=ON\
    -DWITH_OPENCOLLADA=ON\
    -DWITH_PLAYER=ON\
    -DWITH_PYTHON_INSTALL=OFF\
    -DWITH_SYSTEM_GLEW=ON

  setarch $CARCH make $MAKEFLAGS
  setarch $CARCH make
}

package() {
  cd $srcdir/${_pkgname%-$_pkgflag}-$pkgver/build
  setarch $CARCH make DESTDIR=$pkgdir install
  setarch $CARCH python -m compileall $pkgdir/usr/share/${_pkgname%-$_pkgflag}
  # drop nonfree povray render support
  rm -vrf $pkgdir/usr/share/${_pkgname%-$_pkgflag}/${pkgver::4}/scripts/addons/render_povray
}

# vim:set ts=2 sw=2 et: