summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAnthoine Bourgeois <anthoine.bourgeois@gmail.com>2012-04-01 22:20:21 +0200
committerAnthoine Bourgeois <anthoine.bourgeois@gmail.com>2012-04-01 22:20:21 +0200
commit75db4f39240ae00035428086aa3c1aaac8e80a0b (patch)
treea903faf10f5c03b721b63ba3dc267a0c348a0499
parent+blender-2.62-r1.ebuild (diff)
downloadaluco-75db4f39240ae00035428086aa3c1aaac8e80a0b.tar.gz
aluco-75db4f39240ae00035428086aa3c1aaac8e80a0b.tar.bz2
aluco-75db4f39240ae00035428086aa3c1aaac8e80a0b.zip
+blender-2.62-r2.ebuild
-Fix sandbox violation with use flag apidoc. -Fix bug#403357: patch from Bernd Waibel -Fix bug#409283: patch from Bernd Feige (upstream)
-rw-r--r--media-gfx/blender/Manifest4
-rw-r--r--media-gfx/blender/blender-2.62-r2.ebuild450
-rw-r--r--media-gfx/blender/files/blender-2.62-doxyfile.patch11
-rw-r--r--media-gfx/blender/files/blender-2.62-jp2.patch22
4 files changed, 476 insertions, 11 deletions
diff --git a/media-gfx/blender/Manifest b/media-gfx/blender/Manifest
index 7cd330d..f5351c9 100644
--- a/media-gfx/blender/Manifest
+++ b/media-gfx/blender/Manifest
@@ -27,11 +27,12 @@ AUX blender-2.62-CVE-2009-3850-v4.patch 9194 RMD160 cf5519882821c318f32ac3ff16f0
AUX blender-2.62-colamd.patch 8741 RMD160 8eb93e079870b6f81258de1360b4d4e999ab7966 SHA1 2a1d55845cf100ff1c9858f4b54195ea18a06914 SHA256 ccd58de527b59f62195f2b9862f24cc9e790088a13ed428937aa3b2f76eb3a88
AUX blender-2.62-collada.patch 1402 RMD160 89c91ad636614f06ab8b007c5064c06171943ebf SHA1 a2e444d6c25f07d07a9b77eee2a364015a57c28d SHA256 0b5d31b31e113053a998a8c16244b2d5801a8dac0f63fbd5905a51308981b4af
AUX blender-2.62-desktop.patch 645 RMD160 a383502bc0fc8c2145955ef623e6e31aa07a16e8 SHA1 5453acb4d2a845d1fa1428c4eab6b460d44f5551 SHA256 1d50caf9b4e78731a49d4c94b705751b3161ce34886359afc790e42058a8a382
+AUX blender-2.62-doxyfile.patch 591 RMD160 f64970f00cbc123a5d5d6ce34a979b70060e5e7e SHA1 56c31bf42c60622d7d675ea8447f0c4fafb1fccf SHA256 f9ae6bb3fee939a66a191dbad319f9c958862ce6b4de2011a0b85bee431d491a
AUX blender-2.62-eigen.patch 27619 RMD160 75de46a15f741b71de856b80a2397c94f8c8656a SHA1 778379ed1f9c7c0e25b344194f0603c56d35a617 SHA256 62c2701db4920ad064103d7190da214eaebf553b3c805a0f1afbf0310fb785b0
AUX blender-2.62-enable_site_module.patch 1560 RMD160 bab416661e683545d8b66fb177fbd89353c0cf6f SHA1 22b82b86b221cb59f7811c182ad8d8fab77983a4 SHA256 670545321753d65038f5e37c7c3eb94a2ed20bc0d58f045ad3adc142125de9d8
AUX blender-2.62-glew.patch 2039 RMD160 29a967d1cb167b26076e1e73fa7220d7d21364d3 SHA1 1fb29d1c3f0183aa272a928382e92a17548fbea2 SHA256 a96f6a9d12f2b6479883965589661f3435c1acf18205997d69ff2e29e7a8c98b
AUX blender-2.62-insecure.desktop 596 RMD160 a986b8c2f3ab5fea15c3201c5733f848bc1b299c SHA1 d0a52d00c8912c253e5a066f397321e9f178be71 SHA256 b1dfac484638b86f1256eb7b04270ad6433c3a2bc7c20bf5bdd1a8ebed31aea2
-AUX blender-2.62-jp2.patch 378 RMD160 ffbe3efc67947d77dfdd2c50f3392820ef2c0b7a SHA1 6dac1d8d8edc1c28c049dfb3d3bbef78ffc7a639 SHA256 44a6f776c654d51e71601997f1e759880df8fb1ce89cb0fa752af90ac76482d3
+AUX blender-2.62-jp2.patch 393 RMD160 ebd2e45c8643628d7f50b20b195ca699da3f2bdb SHA1 e11148ba1da9814a3820a1507b5f871eea485bc0 SHA256 cd4c0d77577fdd47d14262fd0e46d47fa41f597c736df41f1738942b8a97c7a7
AUX blender-2.62-opencollada-debug.patch 876 RMD160 38b989f11e7880a27c3eac3bf0d3eb5146dfa3e0 SHA1 836ddc2562b9eb4a0f48d467c4e0c008d120e0b3 SHA256 c781a1fc7f808c25fd0bc57524bc07ce36133dbfb2e2bdc27fa19b215597d905
AUX blender-desktop.patch 641 RMD160 5be612d2836005e51e1bcfed10959e75315f201f SHA1 b0f99cdefc6c1a21b32ea97a237e214b22e5f9e6 SHA256 f52bc6f42eb07e693bfbe578747cf126b242b04273cbcd78a8ee4879eae8b514
DIST blender-2.60a.tar.gz 25679123 RMD160 74434c4e748872322386971cf6021255b0bfa1c8 SHA1 f23551e6ed661626c61de4a758d9ff67e0f27529 SHA256 7d788599ab46dac37f630dec026d06f7e3d73508f243eeb4ade8bcdcb661f124
@@ -45,5 +46,6 @@ EBUILD blender-2.61-r4.ebuild 13144 RMD160 19376c7c8b54d9ee5a23a3c8d01f3e0c3a73e
EBUILD blender-2.61-r5.ebuild 13430 RMD160 f86e57eca5297488fb84dfe9ba2c080bbf742f43 SHA1 f1f01d472d7ff0620e8108f4bfea476ef4267728 SHA256 efe60bbfdb3b8a91ad4cc3c4515cdcbdc33cf635b2fd60200eb849f2ea64ef6c
EBUILD blender-2.61.ebuild 13765 RMD160 da7073339b97bcea808cd152e0a871f9c2bc0b4e SHA1 01d4b4b9476471ad02ab33b1a06024929041e85f SHA256 46c08fa0d152ee4b491bf8c139de5d32c8335004a13f031f58c38cbba93d756d
EBUILD blender-2.62-r1.ebuild 13511 RMD160 90d14e7bf5988130a581e06a6ec2e473cd65d85e SHA1 44358eac15cbde82854e94ec4a234a0b13c05af6 SHA256 6e4b0741e9f913fed6568b5d561d9f90d37f4e17543f30dd3026341b925b0bc6
+EBUILD blender-2.62-r2.ebuild 13563 RMD160 d46b643f992a4dfe78cb4f65980227178d3731ee SHA1 484b54d61e9113544a1da9ceb55c0cf4e5662143 SHA256 111c44b64dafa130188d8c0745d0926cff9a4d4b7c49d359920c2ddb1e41c3b1
EBUILD blender-2.62.ebuild 13440 RMD160 a8980096fe813c142bca591cf79c79355ec5fdbb SHA1 673dd6d374a811c9d74d8e117fa19805687f90fc SHA256 00d8aedfd1e856059419e32b4bbedcb87cc58112ba9670db61a274b2be64a63e
MISC metadata.xml 2031 RMD160 7cef28cc97256936c8420d9399c5469dc917f7d1 SHA1 734027d18091dc859e24ec436f7ac992521223d7 SHA256 2aec9b99fcd11925094c06634d41af4cd3681cb81b404cc170b230dd4e337d13
diff --git a/media-gfx/blender/blender-2.62-r2.ebuild b/media-gfx/blender/blender-2.62-r2.ebuild
new file mode 100644
index 0000000..4e43dc5
--- /dev/null
+++ b/media-gfx/blender/blender-2.62-r2.ebuild
@@ -0,0 +1,450 @@
+# Copyright 1999-2011 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/media-gfx/blender/blender-2.60a.ebuild,v 1.4 2011/11/13 22:43:48 sping Exp $
+
+PYTHON_DEPEND="3:3.2"
+EAPI=4
+
+if [[ ${PV} == *9999 ]] ; then
+SCM="subversion"
+ESVN_REPO_URI="https://svn.blender.org/svnroot/bf-blender/trunk/blender"
+fi
+
+inherit multilib scons-utils eutils python versionator flag-o-matic toolchain-funcs pax-utils ${SCM}
+
+IUSE="cycles +game-engine player +elbeem +openexr ffmpeg jpeg2k openal openmp \
+ +dds doc fftw jack apidoc sndfile tweak-mode sdl sse \
+ redcode iconv contrib collada 3dmouse"
+
+LANGS="en ar bg ca cs de el es es_ES es_MX fa fi fr id it ja ne pl pt_BR ru sr sv uk zh_CN zh_TW"
+for X in ${LANGS} ; do
+ IUSE="${IUSE} linguas_${X}"
+done
+
+DESCRIPTION="3D Creation/Animation/Publishing System"
+HOMEPAGE="http://www.blender.org"
+if [[ ${PV} == *9999 ]] ; then
+ SRC_URI=""
+elif [[ ${PV%_p*} != ${PV} ]] ; then # Gentoo snapshot
+ SRC_URI="mirror://gentoo/${P}.tar.xz"
+else # Official release
+ SRC_URI="http://download.blender.org/source/${P}.tar.gz"
+fi
+
+#SLOT="$(get_version_component_range 1-2)"
+SLOT="2.60"
+LICENSE="|| ( GPL-2 BL )"
+KEYWORDS="~amd64 ~x86"
+
+RDEPEND="virtual/jpeg
+ media-libs/libpng:0
+ x11-libs/libXi
+ x11-libs/libX11
+ media-libs/tiff:0
+ media-libs/libsamplerate
+ virtual/opengl
+ >=media-libs/freetype-2.0
+ virtual/libintl
+ media-libs/glew
+ >=sci-physics/bullet-2.78[-double-precision]
+ dev-cpp/eigen:3
+ sci-libs/colamd
+ sys-libs/zlib
+ cycles? (
+ media-libs/openimageio
+ dev-libs/boost
+ )
+ iconv? ( virtual/libiconv )
+ sdl? ( media-libs/libsdl[audio,joystick] )
+ openexr? ( media-libs/openexr )
+ ffmpeg? (
+ >=virtual/ffmpeg-0.6.90[x264,mp3,encode,theora]
+ jpeg2k? ( >=virtual/ffmpeg-0.6.90[x264,mp3,encode,theora,jpeg2k] )
+ )
+ openal? ( >=media-libs/openal-1.6.372 )
+ fftw? ( sci-libs/fftw:3.0 )
+ jack? ( media-sound/jack-audio-connection-kit )
+ sndfile? ( media-libs/libsndfile )
+ collada? ( media-libs/opencollada )
+ 3dmouse? ( dev-libs/libspnav )"
+
+DEPEND="dev-util/scons
+ apidoc? (
+ dev-python/sphinx
+ app-doc/doxygen[-nodot]
+ game-engine? ( dev-python/epydoc )
+ )
+ ${RDEPEND}"
+
+# configure internationalization only if LINGUAS have more
+# languages than 'en', otherwise must be disabled
+if [[ ${LINGUAS} != "en" && -n ${LINGUAS} ]]; then
+ DEPEND="${DEPEND}
+ sys-devel/gettext"
+fi
+
+blend_with() {
+ local UWORD="$2"
+ [ -z "${UWORD}" ] && UWORD="$1"
+ if use $1; then
+ echo "WITH_BF_${UWORD}=1" | tr '[:lower:]' '[:upper:]' \
+ >> "${S}"/user-config.py
+ else
+ echo "WITH_BF_${UWORD}=0" | tr '[:lower:]' '[:upper:]' \
+ >> "${S}"/user-config.py
+ fi
+}
+
+src_unpack() {
+if [[ ${PV} == *9999 ]] ; then
+ subversion_fetch
+ if use contrib; then
+ S="${S}"/release/scripts/addons_contrib subversion_fetch \
+ "https://svn.blender.org/svnroot/bf-extensions/contrib/py/scripts/addons/"
+ fi
+else
+ unpack ${A}
+fi
+}
+
+pkg_setup() {
+ enable_openmp=0
+ if use openmp; then
+ if tc-has-openmp; then
+ enable_openmp=1
+ else
+ ewarn "You are using gcc built without 'openmp' USE."
+ ewarn "Switch CXX to an OpenMP capable compiler."
+ die "Need openmp"
+ fi
+ fi
+ python_set_active_version 3
+}
+
+src_prepare() {
+ epatch "${FILESDIR}"/${P}-desktop.patch
+ epatch "${FILESDIR}"/${P}-collada.patch
+ epatch "${FILESDIR}"/${P}-doxyfile.patch
+
+ # OpenJPEG
+ einfo "Removing bundled OpenJPEG ..."
+ rm -r extern/libopenjpeg
+ epatch "${FILESDIR}"/${PN}-${SLOT}-openjpeg.patch
+
+ # Glew
+ einfo "Removing bundled Glew ..."
+ rm -r extern/glew
+ epatch "${FILESDIR}"/${P}-glew.patch
+
+ # Eigen3
+ einfo "Removing bundled Eigen3 ..."
+ rm -r extern/Eigen3
+ epatch "${FILESDIR}"/${P}-eigen.patch
+
+ # Bullet2
+ einfo "Removing bundled Bullet2 ..."
+ rm -r extern/bullet2
+ epatch "${FILESDIR}"/${PN}-${SLOT}-bullet.patch
+
+ # Colamd
+ einfo "Removing bundled Colamd ..."
+ rm -r extern/colamd
+ epatch "${FILESDIR}"/${P}-colamd.patch
+
+ ewarn "$(echo "Remaining bundled dependencies:";
+ find extern -mindepth 1 -maxdepth 1 -type d | sed 's|^|- |')"
+
+ # Linux 3.x (bug #381099)
+ epatch "${FILESDIR}"/${PN}-${SLOT}-linux-3.patch
+
+ epatch "${FILESDIR}"/${PN}-${SLOT}-libav-0.7.patch
+ epatch "${FILESDIR}"/${P}-CVE-2009-3850-v4.patch
+ epatch "${FILESDIR}"/${P}-enable_site_module.patch
+ epatch "${FILESDIR}"/${P}-opencollada-debug.patch
+
+ # fix undeclared false in jp2.c
+ epatch "${FILESDIR}"/${P}-jp2.patch
+}
+
+src_configure() {
+ # add system openjpeg into Scons build options.
+ cat <<- EOF >> "${S}"/user-config.py
+ BF_OPENJPEG="/usr"
+ BF_OPENJPEG_INC="/usr/include"
+ BF_OPENJPEG_LIB="openjpeg"
+ EOF
+
+ # add system sci-physic/bullet into Scons build options.
+ cat <<- EOF >> "${S}"/user-config.py
+ WITH_BF_BULLET=1
+ BF_BULLET="/usr/include"
+ BF_BULLET_INC="/usr/include/bullet /usr/include/bullet/BulletCollision /usr/include/bullet/BulletDynamics /usr/include/bullet/LinearMath /usr/include/bullet/BulletSoftBody"
+ BF_BULLET_LIB="BulletSoftBody BulletDynamics BulletCollision LinearMath"
+ EOF
+
+ # add system sci-libs/colamd into Scons build options.
+ cat <<- EOF >> "${S}"/user-config.py
+ WITH_BF_COLAMD=1
+ BF_COLAMD="/usr"
+ BF_COLAMD_INC="/usr/include"
+ BF_COLAMD_LIB="colamd"
+ EOF
+
+ #add iconv into Scons build options.
+ if use !elibc_glibc && use !elibc_uclibc && use iconv; then
+ cat <<- EOF >> "${S}"/user-config.py
+ WITH_BF_ICONV=1
+ BF_ICONV="/usr"
+ EOF
+ fi
+
+ # configure internationalization only if LINGUAS have more
+ # languages than 'en', otherwise must be disabled
+ [[ -z ${LINGUAS} ]] || [[ ${LINGUAS} == "en" ]] && echo "WITH_BF_INTERNATIONAL=0" >> "${S}"/user-config.py
+
+ # Ocean sim system needs fftw
+ use fftw || echo "WITH_BF_OCEANSIM=0" >> "${S}"/user-config.py
+
+ # configure Tweak Mode
+ use tweak-mode && echo "BF_TWEAK_MODE=1" >> "${S}"/user-config.py
+
+ # FIX: Game Engine module needs to be active to build the Blender Player
+ if ! use game-engine && use player; then
+ elog "Forcing Game Engine [+game-engine] as required by Blender Player [+player]"
+ echo "WITH_BF_GAMEENGINE=1" >> "${S}"/user-config.py
+ else
+ blend_with game-engine gameengine
+ fi
+
+ # set CFLAGS used in /etc/make.conf correctly
+ echo "CFLAGS=[`for i in ${CFLAGS[@]}; do printf "%s \'$i"\',; done`] " \
+ | sed -e "s:,]: ]:" >> "${S}"/user-config.py
+
+ # set CXXFLAGS used in /etc/make.conf correctly
+ local FILTERED_CXXFLAGS="`for i in ${CXXFLAGS[@]}; do printf "%s \'$i"\',; done`"
+ echo "CXXFLAGS=[${FILTERED_CXXFLAGS}]" | sed -e "s:,]: ]:" >> "${S}"/user-config.py
+ echo "BGE_CXXFLAGS=[${FILTERED_CXXFLAGS}]" | sed -e "s:,]: ]:" >> "${S}"/user-config.py
+
+ # reset general options passed to the C/C++ compilers (useless hardcoded flags)
+ # FIX: forcing '-funsigned-char' fixes an anti-aliasing issue with menu
+ # shadows, see bug #276338 for reference
+ echo "CCFLAGS= ['-funsigned-char', '-D_LARGEFILE_SOURCE', '-D_FILE_OFFSET_BITS=64']" >> "${S}"/user-config.py
+
+ # set LDFLAGS used in /etc/make.conf correctly
+ local FILTERED_LDFLAGS="`for i in ${LDFLAGS[@]}; do printf "%s \'$i"\',; done`"
+ echo "LINKFLAGS=[${FILTERED_LDFLAGS}]" | sed -e "s:,]: ]:" >> "${S}"/user-config.py
+ echo "PLATFORM_LINKFLAGS=[${FILTERED_LDFLAGS}]" | sed -e "s:,]: ]:" >> "${S}"/user-config.py
+
+ # reset REL_* variables (useless hardcoded flags)
+ cat <<- EOF >> "${S}"/user-config.py
+ REL_CFLAGS=[]
+ REL_CXXFLAGS=[]
+ REL_CCFLAGS=[]
+ EOF
+
+ # reset warning flags (useless for NON blender developers)
+ cat <<- EOF >> "${S}"/user-config.py
+ C_WARN =[ '-w', '-g0' ]
+ CC_WARN =[ '-w', '-g0' ]
+ CXX_WARN=[ '-w', '-g0' ]
+ EOF
+
+ # detecting -j value from MAKEOPTS
+ local NUMJOBS="$( echo "${MAKEOPTS}" | sed -ne 's,.*-j\([[:digit:]]\+\).*,\1,p' )"
+ [[ -z "${NUMJOBS}" ]] && NUMJOBS=1 # resetting to -j1 for empty MAKEOPTS
+
+ # generic settings which differ from the defaults from linux2-config.py
+ cat <<- EOF >> "${S}"/user-config.py
+ BF_OPENGL_LIB='GL GLU X11 Xi GLEW'
+ BF_INSTALLDIR="../install"
+ WITH_PYTHON_SECURITY=1
+ WITHOUT_BF_PYTHON_INSTALL=1
+ BF_PYTHON="/usr"
+ BF_PYTHON_VERSION="3.2"
+ BF_PYTHON_ABI_FLAGS=""
+ BF_BUILDINFO=0
+ BF_QUIET=1
+ BF_NUMJOBS=${NUMJOBS}
+ BF_LINE_OVERWRITE=0
+ WITH_BF_FHS=1
+ WITH_BF_BINRELOC=0
+ WITH_BF_STATICOPENGL=0
+ WITH_BF_OPENMP=${enable_openmp}
+ EOF
+
+ # configure WITH_BF* Scons build options
+ for arg in \
+ 'elbeem fluid' \
+ 'sdl' \
+ 'apidoc docs' \
+ 'jack' \
+ 'sndfile' \
+ 'openexr' \
+ 'dds' \
+ 'fftw fftw3' \
+ 'jpeg2k openjpeg' \
+ 'openal'\
+ 'ffmpeg' \
+ 'ffmpeg ogg' \
+ 'player' \
+ 'sse rayoptimization' \
+ 'redcode' \
+ 'collada' \
+ '3dmouse' ; do
+ blend_with ${arg}
+ done
+
+ # add system media-libs/opencollada into Scons build options.
+ echo 'BF_OPENCOLLADA_INC="/usr/include/opencollada/"' >> "${S}"/user-config.py
+ echo 'BF_OPENCOLLADA_LIBPATH="/usr/'$(get_libdir)'/opencollada/"' >> "${S}"/user-config.py
+
+ # enable debugging/testing support
+ is-flag "-g*" && echo "BF_DEBUG=1" >> "${S}"/user-config.py
+ #use test && echo "BF_UNIT_TEST=1" >> "${S}"/user-config.py
+
+ # enables Cycles render engine
+ if use cycles; then
+ cat <<- EOF >> "${S}"/user-config.py
+ WITH_BF_CYCLES=1
+ WITH_BF_OIIO=1
+ BF_OIIO="/usr"
+ BF_OIIO_INC="/usr/include"
+ BF_OIIO_LIB="OpenImageIO"
+ WITH_BF_BOOST=1
+ BF_BOOST="/usr"
+ BF_BOOST_INC="/usr/include/boost"
+ EOF
+ fi
+
+}
+
+src_compile() {
+ escons || die \
+ '!!! Please add "${S}/scons.config" when filing bugs reports \
+ to bugs.gentoo.org'
+}
+
+src_install() {
+ # creating binary wrapper
+ cat <<- EOF >> "${WORKDIR}/install/blender-${PV}"
+ #!/bin/sh
+
+ # stop this script if the local blender path is a symlink
+ if [ -L \${HOME}/.blender ]; then
+ echo "Detected a symbolic link for \${HOME}/.blender"
+ echo "Sorry, to avoid dangerous situations, the Blender binary can"
+ echo "not be started until you have removed the symbolic link:"
+ echo " # rm -i \${HOME}/.blender"
+ exit 1
+ fi
+
+ export BLENDER_SYSTEM_SCRIPTS="/usr/share/blender/${PV}/scripts"
+ export BLENDER_SYSTEM_DATAFILES="/usr/share/blender/${PV}/datafiles"
+ export BLENDER_SYSTEM_PLUGINS="/usr/lib/blender/${PV}/plugins"
+ exec /usr/bin/blender-bin-${PV} \$*
+ EOF
+
+ # Pax mark blender for hardened support.
+ pax-mark m "${WORKDIR}/install/blender"
+
+ # install binaries
+ exeinto /usr/bin/
+ cp "${WORKDIR}/install/blender" "${WORKDIR}/install/blender-bin-${PV}"
+ doexe "${WORKDIR}/install/blender-bin-${PV}"
+ doexe "${WORKDIR}/install/blender-${PV}"
+ if use player; then
+ cp "${WORKDIR}/install/blenderplayer" \
+ "${WORKDIR}/install/blenderplayer-${PV}"
+ doexe "${WORKDIR}/install/blenderplayer-${PV}"
+ fi
+
+ # install plugin headers
+ insinto /usr/include/${PN}/${PV}
+ doins "${WORKDIR}"/${P}/source/blender/blenpluginapi/*.h
+
+ # install contrib scripts addons
+ insinto /usr/share/${PN}/${PV}/scripts
+ use contrib && doins -r "${WORKDIR}"/${P}/release/scripts/addons_contrib
+
+ # install desktop file
+ insinto /usr/share/pixmaps
+ cp release/freedesktop/icons/scalable/apps/blender.svg \
+ release/freedesktop/icons/scalable/apps/blender-${PV}.svg
+ doins release/freedesktop/icons/scalable/apps/blender-${PV}.svg
+ insinto /usr/share/applications
+ cp release/freedesktop/blender.desktop \
+ release/freedesktop/blender-${PV}.desktop
+ doins release/freedesktop/blender-${PV}.desktop
+ newins "${FILESDIR}"/${P}-insecure.desktop ${P}-insecure.desktop
+
+ # install docs
+ doman "${WORKDIR}"/${P}/doc/manpage/blender.1
+ use doc && dodoc -r "${WORKDIR}"/${P}/doc/guides/*
+ if use apidoc; then
+
+ einfo "Generating (BGE) Blender Game Engine API docs ..."
+ epydoc source/gameengine/PyDoc/*.py -v \
+ -o doc/BGE_API \
+ --quiet --quiet --quiet \
+ --simple-term \
+ --url "http://www.blender.org" \
+ --top API_intro \
+ --name "Blender GameEngine" \
+ --no-private --no-sourcecode \
+ --inheritance=included \
+ --graph=all \
+ --dotpath /usr/bin/dot \
+ || die "epydoc failed."
+ docinto "API/gameengine"
+ dohtml -r "${WORKDIR}"/${P}/doc/BGE_API/*
+
+ #einfo "Generating (BPY) Blender Python API docs ..."
+ "${D}"/usr/bin/blender-bin-${PV} --background --python doc/python_api/sphinx_doc_gen.py --noaudio || die "blender failed."
+ pushd doc/python_api > /dev/null
+ sphinx-build sphinx-in BPY_API || die "sphinx failed."
+ popd > /dev/null
+ docinto "API/python"
+ dohtml -r doc/python_api/BPY_API/*
+
+ einfo "Generating Blender C/C++ API docs ..."
+ pushd "${WORKDIR}"/${P}/doc/doxygen > /dev/null
+ doxygen -u Doxyfile
+ doxygen || die "doxygen failed to build API docs."
+ docinto "API/blender"
+ dohtml -r html/*
+ popd > /dev/null
+ fi
+
+ # final cleanup
+ rm -r "${WORKDIR}"/install/{Python-license.txt,icons,GPL-license.txt,copyright.txt}
+ if [[ -z ${LINGUAS} || ${LINGUAS} == "en" ]]; then
+ rm -r "${WORKDIR}/install/${PV}/datafiles/locale"
+ else
+ for x in "${WORKDIR}"/install/${PV}/datafiles/locale/* ; do
+ mylang=${x##*/}
+ has ${mylang} ${LINGUAS} || rm -r ${x}
+ done
+ fi
+
+ # installing blender
+ insinto /usr/share/${PN}/${PV}
+ doins -r "${WORKDIR}"/install/${PV}/*
+
+ # FIX: making all python scripts readable only by group 'users',
+ # so nobody can modify scripts apart root user, but python
+ # cache (*.pyc) can be written and shared across the users.
+# chown root:users -R "${D}/usr/share/${PN}/${SLOT}/scripts" || die
+# chmod 755 -R "${D}/usr/share/${PN}/${SLOT}/scripts" || die
+}
+
+pkg_postinst() {
+ echo
+ elog "Blender uses python integration. As such, may have some"
+ elog "inherit risks with running unknown python scripting."
+ elog
+ elog "It is recommended to change your blender temp directory"
+ elog "from /tmp to /home/user/tmp or another tmp file under your"
+ elog "home directory. This can be done by starting blender, then"
+ elog "dragging the main menu down do display all paths."
+ elog
+}
diff --git a/media-gfx/blender/files/blender-2.62-doxyfile.patch b/media-gfx/blender/files/blender-2.62-doxyfile.patch
new file mode 100644
index 0000000..c52c234
--- /dev/null
+++ b/media-gfx/blender/files/blender-2.62-doxyfile.patch
@@ -0,0 +1,11 @@
+--- blender-2.60a.orig/work/blender-2.60a/doc/doxygen/Doxyfile 2012-02-12 23:05:35.390883778 +0100
++++ blender-2.60a/work/blender-2.60a/doc/doxygen/Doxyfile 2012-02-12 23:07:22.539860341 +0100
+@@ -952,7 +952,7 @@
+ # the HTML help compiler (hhc.exe). If non-empty doxygen will try to run
+ # the HTML help compiler on the generated index.hhp.
+
+-HHC_LOCATION = "C:/Program Files (x86)/HTML Help Workshop/hhc.exe"
++HHC_LOCATION =
+
+ # If the GENERATE_HTMLHELP tag is set to YES, the GENERATE_CHI flag
+ # controls if a separate .chi index file is generated (YES) or that
diff --git a/media-gfx/blender/files/blender-2.62-jp2.patch b/media-gfx/blender/files/blender-2.62-jp2.patch
index da8c58b..bc4e04f 100644
--- a/media-gfx/blender/files/blender-2.62-jp2.patch
+++ b/media-gfx/blender/files/blender-2.62-jp2.patch
@@ -1,11 +1,13 @@
---- blender-2.62/source/blender/imbuf/intern/jp2.c.orig 2012-03-22 15:36:22.717232295 +0100
-+++ blender-2.62/source/blender/imbuf/intern/jp2.c 2012-03-22 15:36:37.555232983 +0100
-@@ -38,6 +38,8 @@
+=== modified file 'source/blender/imbuf/intern/jp2.c'
+--- source/blender/imbuf/intern/jp2.c 2012-03-31 13:59:45 +0000
++++ source/blender/imbuf/intern/jp2.c 2012-03-31 13:59:55 +0000
+@@ -329,7 +329,7 @@
- #include "openjpeg.h"
-
-+#include <stdbool.h>
-+
- #define JP2_FILEHEADER_SIZE 14
-
- static char JP2_HEAD[]= {0x0, 0x0, 0x0, 0x0C, 0x6A, 0x50, 0x20, 0x20, 0x0D, 0x0A, 0x87, 0x0A};
+ static void cinema_parameters(opj_cparameters_t *parameters)
+ {
+- parameters->tile_size_on = false;
++ parameters->tile_size_on = FALSE;
+ parameters->cp_tdx=1;
+ parameters->cp_tdy=1;
+
+