diff options
author | Luca Barbato <lu_zero@gentoo.org> | 2011-11-13 12:04:30 +0000 |
---|---|---|
committer | Luca Barbato <lu_zero@gentoo.org> | 2011-11-13 12:04:30 +0000 |
commit | 0d8980b43822ea4e9ea2266f002e7fba70aacaed (patch) | |
tree | 76432562b62206e668ddd3e8685a4a09fd2cd639 /media-gfx/blender | |
parent | Corrected Slotting of media-libs/tiff (diff) | |
download | historical-0d8980b43822ea4e9ea2266f002e7fba70aacaed.tar.gz historical-0d8980b43822ea4e9ea2266f002e7fba70aacaed.tar.bz2 historical-0d8980b43822ea4e9ea2266f002e7fba70aacaed.zip |
New version, thanks to Anthoine Bourgeois <anthoine.bourgeois@gmail.com> and everybody who helped on bug #369599
Package-Manager: portage-2.1.10.34/cvs/Linux x86_64
Diffstat (limited to 'media-gfx/blender')
-rw-r--r-- | media-gfx/blender/ChangeLog | 15 | ||||
-rw-r--r-- | media-gfx/blender/Manifest | 17 | ||||
-rw-r--r-- | media-gfx/blender/blender-2.57-r1.ebuild | 5 | ||||
-rw-r--r-- | media-gfx/blender/blender-2.60a.ebuild | 439 | ||||
-rw-r--r-- | media-gfx/blender/files/blender-2.60-bmake.patch | 114 | ||||
-rw-r--r-- | media-gfx/blender/files/blender-2.60-doxyfile.patch | 11 | ||||
-rw-r--r-- | media-gfx/blender/files/blender-2.60-eigen.patch | 293 | ||||
-rw-r--r-- | media-gfx/blender/files/blender-2.60-glew.patch | 48 | ||||
-rw-r--r-- | media-gfx/blender/files/blender-2.60-openjpeg.patch | 37 | ||||
-rw-r--r-- | media-gfx/blender/files/blender-2.60a-CVE-2009-3850-v3.patch | 149 | ||||
-rw-r--r-- | media-gfx/blender/files/blender-2.60a-enable_site_module.patch | 32 | ||||
-rw-r--r-- | media-gfx/blender/files/blender-2.60a-insecure.desktop | 15 | ||||
-rw-r--r-- | media-gfx/blender/files/blender-2.60a-libav-0.7.patch | 28 | ||||
-rw-r--r-- | media-gfx/blender/files/blender-2.60a-linux-3.patch | 12 | ||||
-rw-r--r-- | media-gfx/blender/files/blender-desktop.patch | 20 |
15 files changed, 1229 insertions, 6 deletions
diff --git a/media-gfx/blender/ChangeLog b/media-gfx/blender/ChangeLog index 8cd577bddecd..a5def01cf9d5 100644 --- a/media-gfx/blender/ChangeLog +++ b/media-gfx/blender/ChangeLog @@ -1,6 +1,19 @@ # ChangeLog for media-gfx/blender # Copyright 1999-2011 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/media-gfx/blender/ChangeLog,v 1.209 2011/11/13 07:19:54 lu_zero Exp $ +# $Header: /var/cvsroot/gentoo-x86/media-gfx/blender/ChangeLog,v 1.210 2011/11/13 12:04:30 lu_zero Exp $ + +*blender-2.60a (13 Nov 2011) + + 13 Nov 2011; Luca Barbato <lu_zero@gentoo.org> blender-2.57-r1.ebuild, + +files/blender-2.60-bmake.patch, +files/blender-2.60-doxyfile.patch, + +files/blender-2.60-eigen.patch, +files/blender-2.60-glew.patch, + +files/blender-2.60-openjpeg.patch, +blender-2.60a.ebuild, + +files/blender-2.60a-CVE-2009-3850-v3.patch, + +files/blender-2.60a-enable_site_module.patch, + +files/blender-2.60a-insecure.desktop, +files/blender-2.60a-libav-0.7.patch, + +files/blender-2.60a-linux-3.patch, +files/blender-desktop.patch: + New version, thanks to Anthoine Bourgeois <anthoine.bourgeois@gmail.com> and + everybody who helped on bug #369599 13 Nov 2011; Luca Barbato <lu_zero@gentoo.org> blender-2.49b-r2.ebuild, +files/blender-2.49b-libav-0.7.patch: diff --git a/media-gfx/blender/Manifest b/media-gfx/blender/Manifest index 0f78746acb6d..cf9cbfaab6d6 100644 --- a/media-gfx/blender/Manifest +++ b/media-gfx/blender/Manifest @@ -22,15 +22,28 @@ AUX blender-2.57-glew.patch 443 RMD160 bc2606d216bd9231a96fc7bd891deaf13f710c93 AUX blender-2.57-insecure.desktop 498 RMD160 f6649a7aafa6c08dae5422360d6dacaede35ec23 SHA1 e955ef75b5e86c55269ee0ed0550bd729ebc22ef SHA256 584916335a55683013cc6548016238874c26cf3ce152dea30464db221d306a1d AUX blender-2.57-libav-0.7.patch 10964 RMD160 c3b5629b1ae2832dde8748028f51473070ed4796 SHA1 42c125050f1a374ee646f6951fca3de14ab7ccb0 SHA256 5b8da8d015d8e3ca63e1842ff5e1326b4d6788dfb9d024dfa9ab3f15898925df AUX blender-2.57-linux-3.patch 414 RMD160 cb1cfc00e363e00c67a3c6d3567768418be78f39 SHA1 71f4701aa2e88de35843661cf5eecfe411ccd99b SHA256 4f1f8960e1b5706b426e272c17b70682b1eaa5903fa325e4d4db21efd540d732 +AUX blender-2.60-bmake.patch 3429 RMD160 585fe2729d0756fbb80d62b35da96d7c7d07b78d SHA1 7832d676e4625ec139bfc9fe113604f4c810a614 SHA256 3432df1f780503ad34a96c83d3faea9fabe2fa58f1bcdf6a52a2d7ae33874f16 +AUX blender-2.60-doxyfile.patch 595 RMD160 f4890f0ead6943f323bc61e7f6766c2133e8591b SHA1 0fd7c202f044224cf9944596cf36cfcd56b39067 SHA256 d267e0fab4ecb9be78b9238a9c2af60ac9d5ddb7b42f73f479b9266704605883 +AUX blender-2.60-eigen.patch 13804 RMD160 67b2d444f35ac5b9f2e2fc1ee93a105feadc83db SHA1 943ba7ebd2f37102b62d790d7ad4795695fba268 SHA256 b973b07db667ab84eebae24c47805772f6f2694bb77cb8846431d502c56b54d8 +AUX blender-2.60-glew.patch 1128 RMD160 392907190c8c970a1b2f0b20067d9f1bf108edbc SHA1 e9890bc4c420b16ce4f9c9c6cfc71c13852e4de3 SHA256 a43f0a0ac2a0cc5096e8488c926e7a32933a5910300440590a1cac5e1bb73f20 +AUX blender-2.60-openjpeg.patch 1731 RMD160 898318cfdc0c5daafd39d1f0f116531c6a2fd69f SHA1 5870c4f7b50f9edc4d12b68a684b8bb32548ad20 SHA256 3a684711e40ba365152593a6c90bbf38b190c84132e288c3dd3c7409dc6f9a62 +AUX blender-2.60a-CVE-2009-3850-v3.patch 7787 RMD160 02afc6ef3bcdf314c693c44be0cfc649ffd4ebf3 SHA1 031b42d09021b027dde631f08bc8e973299edab9 SHA256 1aebbdd475ccdb1d4e77c4c1ae4c3205e76a1a06f7dcd5e70624c141f42d204b +AUX blender-2.60a-enable_site_module.patch 974 RMD160 e93ddcd1372751951b6e56f72c764e2043747574 SHA1 84aed7ab30f5de1989ee63b4584db7acd6747b54 SHA256 dfafc00a08504c0c3259083d01e535e00f9a952db4a551dbacf0a62ad1a5c768 +AUX blender-2.60a-insecure.desktop 495 RMD160 b1c0610f828df44355dad5c0aab13d662a56006f SHA1 d22db462c2909ccd8af0c705f069b08167a06fb2 SHA256 b5bc477c6849f063ce1ad8ae4caa4a93b79d055fbb46c2ad174a3c5dbbb69eb1 +AUX blender-2.60a-libav-0.7.patch 1069 RMD160 4cd584ce35a2846aec25536f26faa1ccb5fce0d0 SHA1 034488267f494c35198528736e9106755a9a7d4f SHA256 6f341d8b8e8f35fcecd1a0a394f40d3b17685d810e2adc7e818de4c2b6864a2e +AUX blender-2.60a-linux-3.patch 414 RMD160 cb1cfc00e363e00c67a3c6d3567768418be78f39 SHA1 71f4701aa2e88de35843661cf5eecfe411ccd99b SHA256 4f1f8960e1b5706b426e272c17b70682b1eaa5903fa325e4d4db21efd540d732 +AUX blender-desktop.patch 641 RMD160 5be612d2836005e51e1bcfed10959e75315f201f SHA1 b0f99cdefc6c1a21b32ea97a237e214b22e5f9e6 SHA256 f52bc6f42eb07e693bfbe578747cf126b242b04273cbcd78a8ee4879eae8b514 AUX blender.desktop 199 RMD160 a55286923d1422f620dff35226a42fcbaf8c60a9 SHA1 c5ad8c540571a254756ac541c64933e80406aa16 SHA256 3fbab5be3f52ce56f285e422c856aecd15627cffeadcb07af313e0d64c4803ad AUX blender.png 2119 RMD160 e06574002001f41198dc9408ef1bba45493fcc27 SHA1 9a0d713235ce99f8e4fde4f062209ab989e48c0f SHA256 bef633319c81323bb82db274004d89082ca05cab6650eb4c4bf43f830ccb5cad DIST blender-2.48a.tar.gz 21502247 RMD160 5ef94d6019302bfea86d5657af738d1d86a8bcd5 SHA1 9fb2dbf5d6cfcba8ae2d6d9b93ca9e3e66aae6c7 SHA256 781d4d9e2332f4f3887af1d66fb70c4c6dd0b89166391403ee4853108abf4e46 DIST blender-2.49a.tar.gz 23039535 RMD160 f37100c7a02c75b622b8e055f32f06e064a62de2 SHA1 59f5be96eda874bb901390f55a70d58cf8e0b979 SHA256 b206b878a6f96d1e8561ee62a58fba1af4141579c27f51ec795f08f4129eb1fc DIST blender-2.49b.tar.gz 22918377 RMD160 5b641de7b41af5e4186c9721b66eddc6870f9fbc SHA1 43f71e7de4efe79c518d45f4b5a04e03c28d5fc5 SHA256 23554db4aa10b00e0e760a8bf9c4a9f749670d815c8bc874a04746adc4752488 DIST blender-2.57.tar.gz 16806453 RMD160 d2f4d14cb08067a3d1fb3c1661772cf8f3a9bfaa SHA1 c539e2640dfa2a17e044d0f296219b866242112a SHA256 8bd1812166f2dd96e158c1898a666adc1f9f109765d5cd7ff3a8adeae60794b8 +DIST blender-2.60a.tar.gz 25679123 RMD160 74434c4e748872322386971cf6021255b0bfa1c8 SHA1 f23551e6ed661626c61de4a758d9ff67e0f27529 SHA256 7d788599ab46dac37f630dec026d06f7e3d73508f243eeb4ade8bcdcb661f124 EBUILD blender-2.48a-r3.ebuild 4044 RMD160 831a9636988fb1a5ca9a406e45e6bf204511b609 SHA1 9b7b45cd51aa2057a1043d40223dd6a742282919 SHA256 5b677a561cb8c02ebb9527e78f9a11385d1e902602d0caa3d932e135f20af335 EBUILD blender-2.49a.ebuild 4819 RMD160 109229feaf551d5c4829ecad0f4eb7c9cfea8c1e SHA1 3537ea47e3ccb11df14c321580559e04452bb7ee SHA256 67af33393f99caee9c451feb548d98836d2a0d75c714c253ec01416281339ed4 EBUILD blender-2.49b-r2.ebuild 5050 RMD160 87bba6723e7f083f395666581f568848154c3233 SHA1 105297aa72047f8501775933f1d4b51bf992d60e SHA256 39dec297a537d22f07576adc90211ec8806f8d63c6c30906f58f6e51dc2cc764 -EBUILD blender-2.57-r1.ebuild 13957 RMD160 c1a41c1936954b9d2c2116ed128b84e338c06920 SHA1 72509eba4cddc3b92243cbf5b567bcaaae11bfb6 SHA256 84becdf04815fdecb50f7b32ba7df920eed3ad54700ba9312efb4c54a88e0933 -MISC ChangeLog 31880 RMD160 739d594984272b16dd4405777384ba5dd294e928 SHA1 9e2dc938bc06d836ca6ada1f451daafd0ef416ac SHA256 5e361d25958fd48c6aa878b8a1e9223d730d196b3f4d3823d732bb5551ebe69d +EBUILD blender-2.57-r1.ebuild 13935 RMD160 e379b03c655891ed9bfc0c0542ab5a955cc3710b SHA1 2d988031adfed101d7c6bec64ae36b7bfefba460 SHA256 98934feed8e0cc661dac38746f1a8322088269c470fb32c84d1af2c494f8f834 +EBUILD blender-2.60a.ebuild 13687 RMD160 9d134c0802f237e32cb15021bc24f679a3207462 SHA1 700d1604bc61e5ddad2a19d3e2e0ce02c16b6b01 SHA256 4c137e28b5937e3a9f985831fb693774e3622b9005b02d29bcddc606499f1141 +MISC ChangeLog 32543 RMD160 14c63caa6d17460e19dcf978b1ced18afb2bd547 SHA1 4943c137ed5eee37cb14f443375cd04a1b28088d SHA256 bf93f1220d5205e58093edde6dfff7dff2d18f1b9099ce4e43cf25a2840e79c2 MISC metadata.xml 1799 RMD160 7330ec5ccf7f7a86f31abf0b5f45bf84025c505a SHA1 a8bc4c5db954f24ea50e879b1bdbd5753430b3ee SHA256 f4bc849a0cc6a805fe6624699c5c1b9248336f7b879484f777f31b7c755759ea diff --git a/media-gfx/blender/blender-2.57-r1.ebuild b/media-gfx/blender/blender-2.57-r1.ebuild index 395b8fbbb8a0..77fa55fccf32 100644 --- a/media-gfx/blender/blender-2.57-r1.ebuild +++ b/media-gfx/blender/blender-2.57-r1.ebuild @@ -1,6 +1,6 @@ # 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.57-r1.ebuild,v 1.8 2011/11/07 21:51:39 lu_zero Exp $ +# $Header: /var/cvsroot/gentoo-x86/media-gfx/blender/blender-2.57-r1.ebuild,v 1.9 2011/11/13 12:04:30 lu_zero Exp $ PYTHON_DEPEND="3:3.2" @@ -15,7 +15,7 @@ inherit scons-utils eutils python versionator flag-o-matic toolchain-funcs ${SCM IUSE="+game-engine player +elbeem +openexr ffmpeg jpeg2k openal openmp \ +dds debug fftw jack apidoc sndfile lcms tweak-mode sdl sse \ - redcode +zlib iconv contrib collada verse" + redcode +zlib iconv contrib verse" # not complete/working features #IUSE="verse collada test" @@ -279,7 +279,6 @@ src_configure() { 'ffmpeg' \ 'ffmpeg ogg' \ 'player' \ - 'collada' \ 'sse rayoptimization' \ 'redcode' \ 'zlib' \ diff --git a/media-gfx/blender/blender-2.60a.ebuild b/media-gfx/blender/blender-2.60a.ebuild new file mode 100644 index 000000000000..1f5a972554a1 --- /dev/null +++ b/media-gfx/blender/blender-2.60a.ebuild @@ -0,0 +1,439 @@ +# 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.1 2011/11/13 12:04:30 lu_zero 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 scons-utils eutils python versionator flag-o-matic toolchain-funcs ${SCM} + +IUSE="+game-engine player +elbeem +openexr ffmpeg jpeg2k openal openmp \ + +dds debug doc fftw jack apidoc sndfile lcms tweak-mode sdl sse \ + redcode +zlib iconv contrib verse" + +LANGS="en ar bg ca cs de el es fi fr hr it ja ko nl pl pt_BR ro ru sr sv uk zh_CN" +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 + x11-libs/libXi + x11-libs/libX11 + media-libs/tiff + media-libs/libsamplerate + virtual/opengl + >=media-libs/freetype-2.0 + virtual/libintl + media-libs/glew + dev-cpp/eigen:2 + >=sci-physics/bullet-2.76 + iconv? ( virtual/libiconv ) + zlib? ( sys-libs/zlib ) + 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 ) + lcms? ( media-libs/lcms )" + +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}"/${PN}-desktop.patch + epatch "${FILESDIR}"/${PN}-${SLOT}-doxyfile.patch + + # TODO: write a proper Makefile to replace the borked bmake script + epatch "${FILESDIR}"/${PN}-${SLOT}-bmake.patch + chmod 755 "${WORKDIR}"/${P}/release/plugins/bmake + + # 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}"/${PN}-${SLOT}-glew.patch + + # Eigen2 + einfo "Removing bundled Eigen2 ..." + rm -r extern/Eigen2 + epatch "${FILESDIR}"/${PN}-${SLOT}-eigen.patch + + # Linux 3.x (bug #381099) + epatch "${FILESDIR}"/${P}-linux-3.patch + + epatch "${FILESDIR}"/${P}-libav-0.7.patch + epatch "${FILESDIR}"/${P}-CVE-2009-3850-v3.patch + epatch "${FILESDIR}"/${P}-enable_site_module.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 + + # FIX: littlecms includes path aren't specified + if use lcms; then + cat <<- EOF >> "${S}"/user-config.py + BF_LCMS_INC="/usr/include/" + BF_LCMS_LIB="lcms" + BF_LCMS_LIBPATH="/usr/lib/" + EOF + fi + + # 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 /usr/include/BulletCollision /usr/include/BulletDynamics /usr/include/LinearMath /usr/include/BulletSoftBody" +# BF_BULLET_LIB="BulletSoftBody BulletDynamics BulletCollision LinearMath" +# 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 + + # configure Elbeem fluid system + use elbeem || echo "BF_NO_ELBEEM=1" >> "${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 \ + 'sdl' \ + 'apidoc docs' \ + 'lcms' \ + 'jack' \ + 'sndfile' \ + 'openexr' \ + 'dds' \ + 'fftw fftw3' \ + 'jpeg2k openjpeg' \ + 'openal'\ + 'ffmpeg' \ + 'ffmpeg ogg' \ + 'player' \ + 'sse rayoptimization' \ + 'redcode' \ + 'zlib' \ + 'verse' ; do + blend_with ${arg} + done + + # enable debugging/testing support + use debug && echo "BF_DEBUG=1" >> "${S}"/user-config.py + use test && echo "BF_UNIT_TEST=1" >> "${S}"/user-config.py +} + +src_compile() { + escons || die \ + '!!! Please add "${S}/scons.config" when filing bugs reports \ + to bugs.gentoo.org' + + einfo "Building plugins ..." + # FIX: plugins are built without respecting user's LDFLAGS + emake \ + CFLAGS="${CFLAGS} -fPIC" \ + LDFLAGS="$(raw-ldflags) -Bshareable" \ + -C release/plugins +} + +src_install() { + # creating binary wrapper + cat <<- EOF >> "${WORKDIR}/install/blender-${SLOT}" + #!/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/${SLOT}/scripts" + export BLENDER_SYSTEM_DATAFILES="/usr/share/blender/${SLOT}/datafiles" + export BLENDER_SYSTEM_PLUGINS="/usr/lib/blender/${SLOT}/plugins" + exec /usr/bin/blender-bin-${SLOT} \$* + EOF + + # install binaries + exeinto /usr/bin/ + cp "${WORKDIR}/install/blender" "${WORKDIR}/install/blender-bin-${SLOT}" + doexe "${WORKDIR}/install/blender-bin-${SLOT}" + doexe "${WORKDIR}/install/blender-${SLOT}" + if use player; then + cp "${WORKDIR}/install/blenderplayer" \ + "${WORKDIR}/install/blenderplayer-${SLOT}" + doexe "${WORKDIR}/install/blenderplayer-${SLOT}" + fi +# if use verse; then +# cp "${WORKDIR}"/install/bin/verse_server \ +# "${WORKDIR}/install/bin/verse_server-${SLOT}" +# doexe "${WORKDIR}"/install/bin/verse_server-${SLOT} +# fi + + # install plugins + exeinto /usr/lib/${PN}/${SLOT}/plugins/texture + doexe "${WORKDIR}"/${P}/release/plugins/texture/*.so + exeinto /usr/lib/${PN}/${SLOT}/plugins/sequences + doexe "${WORKDIR}"/${P}/release/plugins/sequence/*.so + insinto /usr/include/${PN}/${SLOT} + doins "${WORKDIR}"/${P}/source/blender/blenpluginapi/*.h +# rm -r "${WORKDIR}"/${P}/release/plugins +# insinto /usr/share/${PN}/${SLOT} +# doins "${WORKDIR}"/${P}/release/datafiles +# doins "${WORKDIR}"/${P}/release/scripts + + # install desktop file + insinto /usr/share/pixmaps + cp release/freedesktop/icons/scalable/apps/blender.svg \ + release/freedesktop/icons/scalable/apps/blender-${SLOT}.svg + doins release/freedesktop/icons/scalable/apps/blender-${SLOT}.svg + insinto /usr/share/applications + cp release/freedesktop/blender.desktop \ + release/freedesktop/blender-${SLOT}.desktop + doins release/freedesktop/blender-${SLOT}.desktop + newins "${FILESDIR}"/${P}-insecure.desktop ${PN}-${SLOT}-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-2.60 --background --python doc/python_api/sphinx_doc_gen.py || 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} + + # installing blender + insinto /usr/share/${PN}/${SLOT} + doins -r "${WORKDIR}"/install/${SLOT}/* + + # 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_preinst() { +# if [ -h "${ROOT}/usr/$(get_libdir)/blender/plugins/include" ]; +# then +# rm -r "${ROOT}"/usr/$(get_libdir)/blender/plugins/include +# fi +#} + +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 + elog "Blender has its own internal rendering engine but you" + elog "can export to external renderers for image computation" + elog "like: YafRay[1], sunflow[2], PovRay[3] and luxrender[4]" + elog + elog "If you need one of them just emerge it:" + elog " [1] emerge -av media-gfx/yafray" + elog " [2] emerge -av media-gfx/sunflow" + elog " [3] emerge -av media-gfx/povray" + elog " [4] emerge -av media-gfx/luxrender" + elog + elog "When setting the Blender paths with the User Preferences" + elog "dialog box, remember to NOT declare your home's paths as:" + elog "~/.blender, but as: /home/user/.blender; in other words," + elog "DO NOT USE the tilde inside the paths, as Blender is not" + elog "able to handle it, ignoring your customizations." +} diff --git a/media-gfx/blender/files/blender-2.60-bmake.patch b/media-gfx/blender/files/blender-2.60-bmake.patch new file mode 100644 index 000000000000..0ce8fa72323c --- /dev/null +++ b/media-gfx/blender/files/blender-2.60-bmake.patch @@ -0,0 +1,114 @@ +diff -Npur release/plugins.orig/bmake release/plugins/bmake +--- release/plugins.orig/bmake 2011-11-11 15:00:26.339924887 +0100 ++++ release/plugins/bmake 2011-11-11 15:01:40.637923565 +0100 +@@ -57,10 +57,10 @@ + LDFLAGS="-Bshareable"; + elif ( test $UNAME = "Linux" ) then + CC="gcc"; +- CFLAGS="-fPIC -funsigned-char -O2"; ++# CFLAGS="-fPIC -funsigned-char -O2"; + + LD="ld"; +- LDFLAGS="-Bshareable"; ++# LDFLAGS="-Bshareable"; + elif ( test $UNAME = "SunOS" ) then + CC="cc"; + CFLAGS="-O"; +@@ -109,22 +109,20 @@ elif ( test -f "../plugin.h" ) then + INCLUDES=-I..; + elif ( test -f "../include/plugin.h" ) then + INCLUDES=-I../include ++elif ( test -f "../../../source/blender/blenpluginapi/plugin.h" ) then ++ INCLUDES=-I../../../source/blender/blenpluginapi + else + echo "Couldn't find plugin.h"; + exit; + fi + + LIBM=`fgrep "#include <math.h>" $CFILE` +-LIBC=`fgrep "#include <std" $CFILE` + +-LIBS= ++LIBS="-lc" + + if ( test -n "$LIBM" ) then + LIBS="$LIBS -lm"; + fi +-if ( test -n "$LIBC" ) then +- LIBS="$LIBS -lc"; +-fi + + echo "$CC $CFLAGS -c $CFILE $INCLUDES" + $CC $CFLAGS -c $CFILE $INCLUDES +diff -Npur release/plugins.orig/sequence/color-correction-hsv.c release/plugins/sequence/color-correction-hsv.c +--- release/plugins.orig/sequence/color-correction-hsv.c 2011-11-11 15:00:26.339924887 +0100 ++++ release/plugins/sequence/color-correction-hsv.c 2011-11-11 15:03:47.233921332 +0100 +@@ -15,7 +15,7 @@ + * + */ + +-#include "math.h" ++#include <math.h> + #include "plugin.h" + #include <stdio.h> + +diff -Npur release/plugins.orig/sequence/color-correction-yuv.c release/plugins/sequence/color-correction-yuv.c +--- release/plugins.orig/sequence/color-correction-yuv.c 2011-11-11 15:00:26.339924887 +0100 ++++ release/plugins/sequence/color-correction-yuv.c 2011-11-11 15:02:10.446923031 +0100 +@@ -15,7 +15,7 @@ + * + */ + +-#include "math.h" ++#include <math.h> + #include "plugin.h" + #include <stdio.h> + +diff -Npur release/plugins.orig/sequence/dnr.c release/plugins/sequence/dnr.c +--- release/plugins.orig/sequence/dnr.c 2011-11-11 15:00:26.339924887 +0100 ++++ release/plugins/sequence/dnr.c 2011-11-11 15:03:30.049921648 +0100 +@@ -15,7 +15,7 @@ + * + */ + +-#include "math.h" ++#include <math.h> + #include "plugin.h" + #include <stdio.h> + +diff -Npur release/plugins.orig/sequence/gamma.c release/plugins/sequence/gamma.c +--- release/plugins.orig/sequence/gamma.c 2011-11-11 15:00:26.339924887 +0100 ++++ release/plugins/sequence/gamma.c 2011-11-11 15:01:58.982923268 +0100 +@@ -15,7 +15,7 @@ + * + */ + +-#include "math.h" ++#include <math.h> + #include "plugin.h" + #include "util.h" + #include <stdio.h> +diff -Npur release/plugins.orig/texture/clouds2.c release/plugins/texture/clouds2.c +--- release/plugins.orig/texture/clouds2.c 2011-11-11 15:00:26.339924887 +0100 ++++ release/plugins/texture/clouds2.c 2011-11-11 15:02:23.104922789 +0100 +@@ -27,7 +27,7 @@ + * ***** END GPL LICENSE BLOCK ***** + */ + +-#include "math.h" ++#include <math.h> + #include "plugin.h" + + /* ******************** GLOBAL VARIABLES ***************** */ +diff -Npur release/plugins.orig/texture/tiles.c release/plugins/texture/tiles.c +--- release/plugins.orig/texture/tiles.c 2011-11-11 15:00:26.339924887 +0100 ++++ release/plugins/texture/tiles.c 2011-11-11 15:04:05.749921038 +0100 +@@ -27,7 +27,7 @@ + * ***** END GPL LICENSE BLOCK ***** + */ + +-#include "math.h" ++#include <math.h> + #include "plugin.h" + + /* ******************** GLOBAL VARIABLES ***************** */ diff --git a/media-gfx/blender/files/blender-2.60-doxyfile.patch b/media-gfx/blender/files/blender-2.60-doxyfile.patch new file mode 100644 index 000000000000..aa61c55986cb --- /dev/null +++ b/media-gfx/blender/files/blender-2.60-doxyfile.patch @@ -0,0 +1,11 @@ +--- blender-2.58a/doc/doxygen/Doxyfile 2011-07-11 23:27:33.975642545 -0300 ++++ blender-2.58a/doc/doxygen/Doxyfile 2011-07-11 23:28:54.913642574 -0300 +@@ -42,7 +42,7 @@ + # exceed 55 pixels and the maximum width should not exceed 200 pixels. + # Doxygen will copy the logo to the output directory. + +-PROJECT_LOGO = ../../release/freedesktop/icons/48x48/blender.png ++PROJECT_LOGO = ../../release/freedesktop/icons/48x48/apps/blender.png + + # The OUTPUT_DIRECTORY tag is used to specify the (relative or absolute) + # base path where the generated documentation will be put. diff --git a/media-gfx/blender/files/blender-2.60-eigen.patch b/media-gfx/blender/files/blender-2.60-eigen.patch new file mode 100644 index 000000000000..6955ee11c8c8 --- /dev/null +++ b/media-gfx/blender/files/blender-2.60-eigen.patch @@ -0,0 +1,293 @@ +--- intern/itasc/SConscript 2009-09-26 09:14:02.000000000 +0200 ++++ intern/itasc/SConscript 2009-09-26 09:14:54.000000000 +0200 +@@ -5,7 +5,8 @@ + sources += env.Glob('kdl/*.cpp') + sources += env.Glob('kdl/utilities/*.cpp') + +-incs = '. ../../extern/Eigen2' ++#incs = '. ../../extern/Eigen2' ++incs = '. /usr/include/eigen2' + + env.BlenderLib ('bf_intern_itasc', sources, Split(incs), [], libtype=['intern','player'], priority=[20,100] ) + +--- source/blender/ikplugin/SConscript ++++ source/blender/ikplugin/SConscript +@@ -4,6 +4,6 @@ + sources = env.Glob('intern/*.c') + env.Glob('intern/*.cpp') + + incs = '#/intern/guardedalloc #/intern/iksolver/extern ../makesdna ../blenlib' +-incs += ' ../blenkernel ../include ../ikplugin #/intern/itasc #/extern/Eigen2' ++incs += ' ../blenkernel ../include ../ikplugin #/intern/itasc /usr/include/eigen2' + + env.BlenderLib ( 'bf_ikplugin', sources, Split(incs), [], libtype=['core','player'], priority=[180, 190] ) +--- source/gameengine/Converter/SConscript 2009-09-26 09:14:02.000000000 +0200 ++++ source/gameengine/Converter/SConscript 2009-09-26 09:14:54.000000000 +0200 +@@ -21,7 +21,8 @@ + incs += ' #source/blender/makesrna' + incs += ' #source/blender/ikplugin' + incs += ' #extern/recastnavigation/Detour/Include' +-incs += ' #extern/Eigen2' ++#incs += ' #extern/Eigen2' ++incs += ' /usr/include/eigen2' + + incs += ' ' + env['BF_BULLET_INC'] + +--- intern/itasc/CMakeLists.txt 2011-11-10 23:34:31.391907001 +0100 ++++ intern/itasc/CMakeLists.txt 2011-11-10 23:35:17.588906231 +0100 +@@ -25,11 +25,11 @@ + # ***** END GPL LICENSE BLOCK ***** + + set(INC +- ../../extern/Eigen2 ++ /usr/include/eigen2 + ) + + set(INC_SYS +- ++ /usr/include/eigen2 + ) + + set(SRC +@@ -117,113 +117,113 @@ set(SRC + ublas_types.hpp + + # until we have another user... +- ../../extern/Eigen2/Eigen/src/Array/BooleanRedux.h +- ../../extern/Eigen2/Eigen/src/Array/CwiseOperators.h +- ../../extern/Eigen2/Eigen/src/Array/Functors.h +- ../../extern/Eigen2/Eigen/src/Array/Norms.h +- ../../extern/Eigen2/Eigen/src/Array/PartialRedux.h +- ../../extern/Eigen2/Eigen/src/Array/Random.h +- ../../extern/Eigen2/Eigen/src/Array/Select.h +- ../../extern/Eigen2/Eigen/src/Cholesky/LDLT.h +- ../../extern/Eigen2/Eigen/src/Cholesky/LLT.h +- ../../extern/Eigen2/Eigen/src/Core/Assign.h +- ../../extern/Eigen2/Eigen/src/Core/Block.h +- ../../extern/Eigen2/Eigen/src/Core/CacheFriendlyProduct.h +- ../../extern/Eigen2/Eigen/src/Core/Coeffs.h +- ../../extern/Eigen2/Eigen/src/Core/CommaInitializer.h +- ../../extern/Eigen2/Eigen/src/Core/Cwise.h +- ../../extern/Eigen2/Eigen/src/Core/CwiseBinaryOp.h +- ../../extern/Eigen2/Eigen/src/Core/CwiseNullaryOp.h +- ../../extern/Eigen2/Eigen/src/Core/CwiseUnaryOp.h +- ../../extern/Eigen2/Eigen/src/Core/DiagonalCoeffs.h +- ../../extern/Eigen2/Eigen/src/Core/DiagonalMatrix.h +- ../../extern/Eigen2/Eigen/src/Core/DiagonalProduct.h +- ../../extern/Eigen2/Eigen/src/Core/Dot.h +- ../../extern/Eigen2/Eigen/src/Core/Flagged.h +- ../../extern/Eigen2/Eigen/src/Core/Functors.h +- ../../extern/Eigen2/Eigen/src/Core/Fuzzy.h +- ../../extern/Eigen2/Eigen/src/Core/GenericPacketMath.h +- ../../extern/Eigen2/Eigen/src/Core/IO.h +- ../../extern/Eigen2/Eigen/src/Core/Map.h +- ../../extern/Eigen2/Eigen/src/Core/MapBase.h +- ../../extern/Eigen2/Eigen/src/Core/MathFunctions.h +- ../../extern/Eigen2/Eigen/src/Core/Matrix.h +- ../../extern/Eigen2/Eigen/src/Core/MatrixBase.h +- ../../extern/Eigen2/Eigen/src/Core/MatrixStorage.h +- ../../extern/Eigen2/Eigen/src/Core/Minor.h +- ../../extern/Eigen2/Eigen/src/Core/NestByValue.h +- ../../extern/Eigen2/Eigen/src/Core/NumTraits.h +- ../../extern/Eigen2/Eigen/src/Core/Part.h +- ../../extern/Eigen2/Eigen/src/Core/Product.h +- ../../extern/Eigen2/Eigen/src/Core/Redux.h +- ../../extern/Eigen2/Eigen/src/Core/SolveTriangular.h +- ../../extern/Eigen2/Eigen/src/Core/Sum.h +- ../../extern/Eigen2/Eigen/src/Core/Swap.h +- ../../extern/Eigen2/Eigen/src/Core/Transpose.h +- ../../extern/Eigen2/Eigen/src/Core/Visitor.h +- ../../extern/Eigen2/Eigen/src/Core/arch/AltiVec/PacketMath.h +- ../../extern/Eigen2/Eigen/src/Core/arch/SSE/PacketMath.h +- ../../extern/Eigen2/Eigen/src/Core/util/Constants.h +- ../../extern/Eigen2/Eigen/src/Core/util/DisableMSVCWarnings.h +- ../../extern/Eigen2/Eigen/src/Core/util/EnableMSVCWarnings.h +- ../../extern/Eigen2/Eigen/src/Core/util/ForwardDeclarations.h +- ../../extern/Eigen2/Eigen/src/Core/util/Macros.h +- ../../extern/Eigen2/Eigen/src/Core/util/Memory.h +- ../../extern/Eigen2/Eigen/src/Core/util/Meta.h +- ../../extern/Eigen2/Eigen/src/Core/util/StaticAssert.h +- ../../extern/Eigen2/Eigen/src/Core/util/XprHelper.h +- ../../extern/Eigen2/Eigen/src/Geometry/AlignedBox.h +- ../../extern/Eigen2/Eigen/src/Geometry/AngleAxis.h +- ../../extern/Eigen2/Eigen/src/Geometry/EulerAngles.h +- ../../extern/Eigen2/Eigen/src/Geometry/Hyperplane.h +- ../../extern/Eigen2/Eigen/src/Geometry/OrthoMethods.h +- ../../extern/Eigen2/Eigen/src/Geometry/ParametrizedLine.h +- ../../extern/Eigen2/Eigen/src/Geometry/Quaternion.h +- ../../extern/Eigen2/Eigen/src/Geometry/Rotation2D.h +- ../../extern/Eigen2/Eigen/src/Geometry/RotationBase.h +- ../../extern/Eigen2/Eigen/src/Geometry/Scaling.h +- ../../extern/Eigen2/Eigen/src/Geometry/Transform.h +- ../../extern/Eigen2/Eigen/src/Geometry/Translation.h +- ../../extern/Eigen2/Eigen/src/LU/Determinant.h +- ../../extern/Eigen2/Eigen/src/LU/Inverse.h +- ../../extern/Eigen2/Eigen/src/LU/LU.h +- ../../extern/Eigen2/Eigen/src/LeastSquares/LeastSquares.h +- ../../extern/Eigen2/Eigen/src/QR/EigenSolver.h +- ../../extern/Eigen2/Eigen/src/QR/HessenbergDecomposition.h +- ../../extern/Eigen2/Eigen/src/QR/QR.h +- ../../extern/Eigen2/Eigen/src/QR/SelfAdjointEigenSolver.h +- ../../extern/Eigen2/Eigen/src/QR/Tridiagonalization.h +- ../../extern/Eigen2/Eigen/src/SVD/SVD.h +- ../../extern/Eigen2/Eigen/src/Sparse/AmbiVector.h +- ../../extern/Eigen2/Eigen/src/Sparse/CholmodSupport.h +- ../../extern/Eigen2/Eigen/src/Sparse/CompressedStorage.h +- ../../extern/Eigen2/Eigen/src/Sparse/CoreIterators.h +- ../../extern/Eigen2/Eigen/src/Sparse/DynamicSparseMatrix.h +- ../../extern/Eigen2/Eigen/src/Sparse/MappedSparseMatrix.h +- ../../extern/Eigen2/Eigen/src/Sparse/RandomSetter.h +- ../../extern/Eigen2/Eigen/src/Sparse/SparseAssign.h +- ../../extern/Eigen2/Eigen/src/Sparse/SparseBlock.h +- ../../extern/Eigen2/Eigen/src/Sparse/SparseCwise.h +- ../../extern/Eigen2/Eigen/src/Sparse/SparseCwiseBinaryOp.h +- ../../extern/Eigen2/Eigen/src/Sparse/SparseCwiseUnaryOp.h +- ../../extern/Eigen2/Eigen/src/Sparse/SparseDiagonalProduct.h +- ../../extern/Eigen2/Eigen/src/Sparse/SparseDot.h +- ../../extern/Eigen2/Eigen/src/Sparse/SparseFlagged.h +- ../../extern/Eigen2/Eigen/src/Sparse/SparseFuzzy.h +- ../../extern/Eigen2/Eigen/src/Sparse/SparseLDLT.h +- ../../extern/Eigen2/Eigen/src/Sparse/SparseLLT.h +- ../../extern/Eigen2/Eigen/src/Sparse/SparseLU.h +- ../../extern/Eigen2/Eigen/src/Sparse/SparseMatrix.h +- ../../extern/Eigen2/Eigen/src/Sparse/SparseMatrixBase.h +- ../../extern/Eigen2/Eigen/src/Sparse/SparseProduct.h +- ../../extern/Eigen2/Eigen/src/Sparse/SparseRedux.h +- ../../extern/Eigen2/Eigen/src/Sparse/SparseTranspose.h +- ../../extern/Eigen2/Eigen/src/Sparse/SparseUtil.h +- ../../extern/Eigen2/Eigen/src/Sparse/SparseVector.h +- ../../extern/Eigen2/Eigen/src/Sparse/SuperLUSupport.h +- ../../extern/Eigen2/Eigen/src/Sparse/TaucsSupport.h +- ../../extern/Eigen2/Eigen/src/Sparse/TriangularSolver.h +- ../../extern/Eigen2/Eigen/src/Sparse/UmfPackSupport.h ++ /usr/include/eigen2/Eigen/src/Array/BooleanRedux.h ++ /usr/include/eigen2/Eigen/src/Array/CwiseOperators.h ++ /usr/include/eigen2/Eigen/src/Array/Functors.h ++ /usr/include/eigen2/Eigen/src/Array/Norms.h ++ /usr/include/eigen2/Eigen/src/Array/PartialRedux.h ++ /usr/include/eigen2/Eigen/src/Array/Random.h ++ /usr/include/eigen2/Eigen/src/Array/Select.h ++ /usr/include/eigen2/Eigen/src/Cholesky/LDLT.h ++ /usr/include/eigen2/Eigen/src/Cholesky/LLT.h ++ /usr/include/eigen2/Eigen/src/Core/Assign.h ++ /usr/include/eigen2/Eigen/src/Core/Block.h ++ /usr/include/eigen2/Eigen/src/Core/CacheFriendlyProduct.h ++ /usr/include/eigen2/Eigen/src/Core/Coeffs.h ++ /usr/include/eigen2/Eigen/src/Core/CommaInitializer.h ++ /usr/include/eigen2/Eigen/src/Core/Cwise.h ++ /usr/include/eigen2/Eigen/src/Core/CwiseBinaryOp.h ++ /usr/include/eigen2/Eigen/src/Core/CwiseNullaryOp.h ++ /usr/include/eigen2/Eigen/src/Core/CwiseUnaryOp.h ++ /usr/include/eigen2/Eigen/src/Core/DiagonalCoeffs.h ++ /usr/include/eigen2/Eigen/src/Core/DiagonalMatrix.h ++ /usr/include/eigen2/Eigen/src/Core/DiagonalProduct.h ++ /usr/include/eigen2/Eigen/src/Core/Dot.h ++ /usr/include/eigen2/Eigen/src/Core/Flagged.h ++ /usr/include/eigen2/Eigen/src/Core/Functors.h ++ /usr/include/eigen2/Eigen/src/Core/Fuzzy.h ++ /usr/include/eigen2/Eigen/src/Core/GenericPacketMath.h ++ /usr/include/eigen2/Eigen/src/Core/IO.h ++ /usr/include/eigen2/Eigen/src/Core/Map.h ++ /usr/include/eigen2/Eigen/src/Core/MapBase.h ++ /usr/include/eigen2/Eigen/src/Core/MathFunctions.h ++ /usr/include/eigen2/Eigen/src/Core/Matrix.h ++ /usr/include/eigen2/Eigen/src/Core/MatrixBase.h ++ /usr/include/eigen2/Eigen/src/Core/MatrixStorage.h ++ /usr/include/eigen2/Eigen/src/Core/Minor.h ++ /usr/include/eigen2/Eigen/src/Core/NestByValue.h ++ /usr/include/eigen2/Eigen/src/Core/NumTraits.h ++ /usr/include/eigen2/Eigen/src/Core/Part.h ++ /usr/include/eigen2/Eigen/src/Core/Product.h ++ /usr/include/eigen2/Eigen/src/Core/Redux.h ++ /usr/include/eigen2/Eigen/src/Core/SolveTriangular.h ++ /usr/include/eigen2/Eigen/src/Core/Sum.h ++ /usr/include/eigen2/Eigen/src/Core/Swap.h ++ /usr/include/eigen2/Eigen/src/Core/Transpose.h ++ /usr/include/eigen2/Eigen/src/Core/Visitor.h ++ /usr/include/eigen2/Eigen/src/Core/arch/AltiVec/PacketMath.h ++ /usr/include/eigen2/Eigen/src/Core/arch/SSE/PacketMath.h ++ /usr/include/eigen2/Eigen/src/Core/util/Constants.h ++ /usr/include/eigen2/Eigen/src/Core/util/DisableMSVCWarnings.h ++ /usr/include/eigen2/Eigen/src/Core/util/EnableMSVCWarnings.h ++ /usr/include/eigen2/Eigen/src/Core/util/ForwardDeclarations.h ++ /usr/include/eigen2/Eigen/src/Core/util/Macros.h ++ /usr/include/eigen2/Eigen/src/Core/util/Memory.h ++ /usr/include/eigen2/Eigen/src/Core/util/Meta.h ++ /usr/include/eigen2/Eigen/src/Core/util/StaticAssert.h ++ /usr/include/eigen2/Eigen/src/Core/util/XprHelper.h ++ /usr/include/eigen2/Eigen/src/Geometry/AlignedBox.h ++ /usr/include/eigen2/Eigen/src/Geometry/AngleAxis.h ++ /usr/include/eigen2/Eigen/src/Geometry/EulerAngles.h ++ /usr/include/eigen2/Eigen/src/Geometry/Hyperplane.h ++ /usr/include/eigen2/Eigen/src/Geometry/OrthoMethods.h ++ /usr/include/eigen2/Eigen/src/Geometry/ParametrizedLine.h ++ /usr/include/eigen2/Eigen/src/Geometry/Quaternion.h ++ /usr/include/eigen2/Eigen/src/Geometry/Rotation2D.h ++ /usr/include/eigen2/Eigen/src/Geometry/RotationBase.h ++ /usr/include/eigen2/Eigen/src/Geometry/Scaling.h ++ /usr/include/eigen2/Eigen/src/Geometry/Transform.h ++ /usr/include/eigen2/Eigen/src/Geometry/Translation.h ++ /usr/include/eigen2/Eigen/src/LU/Determinant.h ++ /usr/include/eigen2/Eigen/src/LU/Inverse.h ++ /usr/include/eigen2/Eigen/src/LU/LU.h ++ /usr/include/eigen2/Eigen/src/LeastSquares/LeastSquares.h ++ /usr/include/eigen2/Eigen/src/QR/EigenSolver.h ++ /usr/include/eigen2/Eigen/src/QR/HessenbergDecomposition.h ++ /usr/include/eigen2/Eigen/src/QR/QR.h ++ /usr/include/eigen2/Eigen/src/QR/SelfAdjointEigenSolver.h ++ /usr/include/eigen2/Eigen/src/QR/Tridiagonalization.h ++ /usr/include/eigen2/Eigen/src/SVD/SVD.h ++ /usr/include/eigen2/Eigen/src/Sparse/AmbiVector.h ++ /usr/include/eigen2/Eigen/src/Sparse/CholmodSupport.h ++ /usr/include/eigen2/Eigen/src/Sparse/CompressedStorage.h ++ /usr/include/eigen2/Eigen/src/Sparse/CoreIterators.h ++ /usr/include/eigen2/Eigen/src/Sparse/DynamicSparseMatrix.h ++ /usr/include/eigen2/Eigen/src/Sparse/MappedSparseMatrix.h ++ /usr/include/eigen2/Eigen/src/Sparse/RandomSetter.h ++ /usr/include/eigen2/Eigen/src/Sparse/SparseAssign.h ++ /usr/include/eigen2/Eigen/src/Sparse/SparseBlock.h ++ /usr/include/eigen2/Eigen/src/Sparse/SparseCwise.h ++ /usr/include/eigen2/Eigen/src/Sparse/SparseCwiseBinaryOp.h ++ /usr/include/eigen2/Eigen/src/Sparse/SparseCwiseUnaryOp.h ++ /usr/include/eigen2/Eigen/src/Sparse/SparseDiagonalProduct.h ++ /usr/include/eigen2/Eigen/src/Sparse/SparseDot.h ++ /usr/include/eigen2/Eigen/src/Sparse/SparseFlagged.h ++ /usr/include/eigen2/Eigen/src/Sparse/SparseFuzzy.h ++ /usr/include/eigen2/Eigen/src/Sparse/SparseLDLT.h ++ /usr/include/eigen2/Eigen/src/Sparse/SparseLLT.h ++ /usr/include/eigen2/Eigen/src/Sparse/SparseLU.h ++ /usr/include/eigen2/Eigen/src/Sparse/SparseMatrix.h ++ /usr/include/eigen2/Eigen/src/Sparse/SparseMatrixBase.h ++ /usr/include/eigen2/Eigen/src/Sparse/SparseProduct.h ++ /usr/include/eigen2/Eigen/src/Sparse/SparseRedux.h ++ /usr/include/eigen2/Eigen/src/Sparse/SparseTranspose.h ++ /usr/include/eigen2/Eigen/src/Sparse/SparseUtil.h ++ /usr/include/eigen2/Eigen/src/Sparse/SparseVector.h ++ /usr/include/eigen2/Eigen/src/Sparse/SuperLUSupport.h ++ /usr/include/eigen2/Eigen/src/Sparse/TaucsSupport.h ++ /usr/include/eigen2/Eigen/src/Sparse/TriangularSolver.h ++ /usr/include/eigen2/Eigen/src/Sparse/UmfPackSupport.h + ) + + blender_add_lib(bf_intern_itasc "${SRC}" "${INC}" "${INC_SYS}") +--- source/blender/ikplugin/CMakeLists.txt 2011-11-10 23:34:31.391907001 +0100 ++++ source/blender/ikplugin/CMakeLists.txt 2011-11-10 23:35:17.588906231 +0100 +@@ -50,7 +50,7 @@ + if(WITH_IK_ITASC) + add_definitions(-DWITH_IK_ITASC) + list(APPEND INC +- ../../../extern/Eigen2 ++ /usr/include/eigen2 + ../../../intern/itasc + ) + list(APPEND SRC +--- source/gameengine/Converter/CMakeLists.txt 2011-11-10 23:34:31.391907001 +0100 ++++ source/gameengine/Converter/CMakeLists.txt 2011-11-10 23:35:17.588906231 +0100 +@@ -51,7 +51,7 @@ + ../../blender/makesrna + ../../blender/windowmanager + ../../../extern/bullet2/src +- ../../../extern/Eigen2 ++ /usr/include/eigen2 + ../../../intern/container + ../../../intern/guardedalloc + ../../../intern/moto/include diff --git a/media-gfx/blender/files/blender-2.60-glew.patch b/media-gfx/blender/files/blender-2.60-glew.patch new file mode 100644 index 000000000000..edc0c9b62427 --- /dev/null +++ b/media-gfx/blender/files/blender-2.60-glew.patch @@ -0,0 +1,48 @@ +--- extern/SConscript ++++ extern/SConscript +@@ -2,8 +2,6 @@ + + Import('env') + +-SConscript(['glew/SConscript']) +- + if env['WITH_BF_GAMEENGINE']: + SConscript(['recastnavigation/SConscript']) + + if env['WITH_BF_ELTOPO']: + SConscript(['eltopo/SConscript']) + +--- source/blender/editors/include/BIF_gl.h ++++ source/blender/editors/include/BIF_gl.h +@@ -35,7 +35,7 @@ + #ifndef BIF_GL_H + #define BIF_GL_H + +-#include "GL/glew.h" ++#include <GL/glew.h> + + /* + * these should be phased out. cpack should be replaced in +--- extern/CMakeLists.txt ++++ extern/CMakeLists.txt +@@ -39,9 +39,6 @@ + add_subdirectory(binreloc) + endif() + +-if(WITH_BUILTIN_GLEW) +- add_subdirectory(glew) +-endif() + + if(WITH_GAMEENGINE) + add_subdirectory(recastnavigation) +--- CMakeLists.txt ++++ CMakeLists.txt +@@ -150,7 +150,7 @@ + + if(UNIX AND NOT APPLE) + option(WITH_X11_XINPUT "Enable X11 Xinput (tablet support)" ON) +- option(WITH_BUILTIN_GLEW "Use GLEW OpenGL wrapper library bundled with blender" ON) ++ option(WITH_BUILTIN_GLEW "Use GLEW OpenGL wrapper library bundled with blender" OFF) + else() + # not an option for other OS's + set(WITH_BUILTIN_GLEW ON) diff --git a/media-gfx/blender/files/blender-2.60-openjpeg.patch b/media-gfx/blender/files/blender-2.60-openjpeg.patch new file mode 100644 index 000000000000..74f6441bdfd2 --- /dev/null +++ b/media-gfx/blender/files/blender-2.60-openjpeg.patch @@ -0,0 +1,37 @@ +diff -Npur blender-2.60a.orig/extern/libredcode/SConscript blender-2.60a/extern/libredcode/SConscript +--- blender-2.60a.orig/extern/libredcode/SConscript 2011-11-09 23:05:16.241465491 +0100 ++++ blender-2.60a/extern/libredcode/SConscript 2011-11-09 23:06:24.188464236 +0100 +@@ -7,7 +7,8 @@ + Import('env') + + sources = env.Glob('*.c') +-incs = '. ../libopenjpeg' ++#incs = '. ../libopenjpeg' ++incs = '. /usr/include' + + env.BlenderLib ( libname='extern_redcode', + sources=sources, includes=Split(incs), +diff -Npur blender-2.60a.orig/extern/SConscript blender-2.60a/extern/SConscript +--- blender-2.60a.orig/extern/SConscript 2011-11-09 23:05:16.241465491 +0100 ++++ blender-2.60a/extern/SConscript 2011-11-09 23:06:24.188464236 +0100 +@@ -11,8 +11,5 @@ + if env['WITH_BF_BULLET']: + SConscript(['bullet2/src/SConscript']) + +-if env['WITH_BF_OPENJPEG'] and env['BF_OPENJPEG_LIB'] == '': +- SConscript(['libopenjpeg/SConscript']) +- + if env['WITH_BF_REDCODE'] and env['BF_REDCODE_LIB'] == '': + SConscript(['libredcode/SConscript']) +diff -Npur blender-2.60a.orig/build_files/scons/tools/Blender.py blender-2.60a/build_files/scons/tools/Blender.py +--- blender-2.60a.orig/build_files/scons/tools/Blender.py 2011-11-09 23:05:16.241465491 +0100 ++++ blender-2.60a/build_files/scons/tools/Blender.py 2011-11-09 23:06:24.188464236 +0100 +@@ -246,6 +246,8 @@ + syslibs += Split(lenv['BF_FFMPEG_LIB']) + if lenv['WITH_BF_OGG']: + syslibs += Split(lenv['BF_OGG_LIB']) ++ if lenv['WITH_BF_OPENJPEG']: ++ syslibs += Split(lenv['BF_OPENJPEG_LIB']) + if lenv['WITH_BF_JACK']: + syslibs += Split(lenv['BF_JACK_LIB']) + if lenv['WITH_BF_SNDFILE'] and not lenv['WITH_BF_STATICSNDFILE']: diff --git a/media-gfx/blender/files/blender-2.60a-CVE-2009-3850-v3.patch b/media-gfx/blender/files/blender-2.60a-CVE-2009-3850-v3.patch new file mode 100644 index 000000000000..fc0278d77d8d --- /dev/null +++ b/media-gfx/blender/files/blender-2.60a-CVE-2009-3850-v3.patch @@ -0,0 +1,149 @@ +diff -Npur blender-2.60a.orig/source/blender/blenkernel/intern/blender.c blender-2.60a/source/blender/blenkernel/intern/blender.c +--- blender-2.60a.orig/source/blender/blenkernel/intern/blender.c 2011-11-09 20:56:11.905602401 +0100 ++++ blender-2.60a/source/blender/blenkernel/intern/blender.c 2011-11-09 20:56:42.827601857 +0100 +@@ -145,6 +145,7 @@ void initglobals(void) + G.f |= G_SCRIPT_AUTOEXEC; + #else + G.f &= ~G_SCRIPT_AUTOEXEC; ++ G.f |= G_SCRIPT_OVERRIDE_PREF; /* Disables turning G_SCRIPT_AUTOEXEC on from user prefs */ + #endif + } + +diff -Npur blender-2.60a.orig/source/blender/makesrna/intern/rna_userdef.c blender-2.60a/source/blender/makesrna/intern/rna_userdef.c +--- blender-2.60a.orig/source/blender/makesrna/intern/rna_userdef.c 2011-11-09 20:56:12.003602399 +0100 ++++ blender-2.60a/source/blender/makesrna/intern/rna_userdef.c 2011-11-09 21:02:43.204595484 +0100 +@@ -116,9 +116,17 @@ static void rna_userdef_show_manipulator + + static void rna_userdef_script_autoexec_update(Main *UNUSED(bmain), Scene *UNUSED(scene), PointerRNA *ptr) + { +- UserDef *userdef = (UserDef*)ptr->data; +- if (userdef->flag & USER_SCRIPT_AUTOEXEC_DISABLE) G.f &= ~G_SCRIPT_AUTOEXEC; +- else G.f |= G_SCRIPT_AUTOEXEC; ++ if ((G.f & G_SCRIPT_OVERRIDE_PREF) == 0) { ++ /* Blender run with --enable-autoexec */ ++ UserDef *userdef = (UserDef*)ptr->data; ++ if (userdef->flag & USER_SCRIPT_AUTOEXEC_DISABLE) G.f &= ~G_SCRIPT_AUTOEXEC; ++ else G.f |= G_SCRIPT_AUTOEXEC; ++ } ++} ++ ++static int rna_userdef_script_autoexec_editable(Main *bmain, Scene *scene, PointerRNA *ptr) { ++ /* Disable "Auto Run Python Scripts" checkbox unless Blender run with --enable-autoexec */ ++ return !(G.f & G_SCRIPT_OVERRIDE_PREF); + } + + static void rna_userdef_mipmap_update(Main *bmain, Scene *scene, PointerRNA *ptr) +@@ -2630,6 +2638,8 @@ static void rna_def_userdef_system(Blend + "Allow any .blend file to run scripts automatically " + "(unsafe with blend files from an untrusted source)"); + RNA_def_property_update(prop, 0, "rna_userdef_script_autoexec_update"); ++ /* Disable "Auto Run Python Scripts" checkbox unless Blender run with --enable-autoexec */ ++ RNA_def_property_editable_func(prop, "rna_userdef_script_autoexec_editable"); + + prop= RNA_def_property(srna, "use_tabs_as_spaces", PROP_BOOLEAN, PROP_NONE); + RNA_def_property_boolean_negative_sdna(prop, NULL, "flag", USER_TXT_TABSTOSPACES_DISABLE); +diff -Npur blender-2.60a.orig/source/blender/windowmanager/intern/wm_files.c blender-2.60a/source/blender/windowmanager/intern/wm_files.c +--- blender-2.60a.orig/source/blender/windowmanager/intern/wm_files.c 2011-11-09 20:56:12.458602413 +0100 ++++ blender-2.60a/source/blender/windowmanager/intern/wm_files.c 2011-11-09 21:05:16.768592770 +0100 +@@ -285,12 +285,17 @@ static void wm_init_userdef(bContext *C) + + /* set the python auto-execute setting from user prefs */ + /* enabled by default, unless explicitly enabled in the command line which overrides */ +- if((G.f & G_SCRIPT_OVERRIDE_PREF) == 0) { ++ if (! G.background && ((G.f & G_SCRIPT_OVERRIDE_PREF) == 0)) { ++ /* Blender run with --enable-autoexec */ + if ((U.flag & USER_SCRIPT_AUTOEXEC_DISABLE) == 0) G.f |= G_SCRIPT_AUTOEXEC; + else G.f &= ~G_SCRIPT_AUTOEXEC; + } + /* update tempdir from user preferences */ + BLI_where_is_temp(btempdir, FILE_MAX, 1); ++ ++ /* Workaround to fix default of "Auto Run Python Scripts" checkbox */ ++ if ((G.f & G_SCRIPT_OVERRIDE_PREF) && !(G.f & G_SCRIPT_AUTOEXEC)) ++ U.flag |= USER_SCRIPT_AUTOEXEC_DISABLE; + } + + +diff -Npur blender-2.60a.orig/source/blender/windowmanager/intern/wm_operators.c blender-2.60a/source/blender/windowmanager/intern/wm_operators.c +--- blender-2.60a.orig/source/blender/windowmanager/intern/wm_operators.c 2011-11-09 20:56:12.458602413 +0100 ++++ blender-2.60a/source/blender/windowmanager/intern/wm_operators.c 2011-11-09 21:07:09.746590772 +0100 +@@ -1583,12 +1583,13 @@ static int wm_open_mainfile_exec(bContex + G.fileflags &= ~G_FILE_NO_UI; + else + G.fileflags |= G_FILE_NO_UI; +- +- if(RNA_boolean_get(op->ptr, "use_scripts")) ++ ++ /* Restrict "Trusted Source" mode to Blender in --enable-autoexec mode */ ++ if(RNA_boolean_get(op->ptr, "use_scripts") && (!(G.f & G_SCRIPT_OVERRIDE_PREF))) + G.f |= G_SCRIPT_AUTOEXEC; + else + G.f &= ~G_SCRIPT_AUTOEXEC; +- ++ + // XXX wm in context is not set correctly after WM_read_file -> crash + // do it before for now, but is this correct with multiple windows? + WM_event_add_notifier(C, NC_WINDOW, NULL); +@@ -1600,6 +1601,8 @@ static int wm_open_mainfile_exec(bContex + + static void WM_OT_open_mainfile(wmOperatorType *ot) + { ++ PropertyRNA * use_scripts_checkbox = NULL; ++ + ot->name= "Open Blender File"; + ot->idname= "WM_OT_open_mainfile"; + ot->description="Open a Blender file"; +@@ -1611,7 +1614,12 @@ static void WM_OT_open_mainfile(wmOperat + WM_operator_properties_filesel(ot, FOLDERFILE|BLENDERFILE, FILE_BLENDER, FILE_OPENFILE, WM_FILESEL_FILEPATH); + + RNA_def_boolean(ot->srna, "load_ui", 1, "Load UI", "Load user interface setup in the .blend file"); +- RNA_def_boolean(ot->srna, "use_scripts", 1, "Trusted Source", "Allow blend file execute scripts automatically, default available from system preferences"); ++ use_scripts_checkbox = RNA_def_boolean(ot->srna, "use_scripts", ++ !!(G.f & G_SCRIPT_AUTOEXEC), "Trusted Source", ++ "Allow blend file execute scripts automatically, default available from system preferences"); ++ /* Disable "Trusted Source" checkbox unless Blender run with --enable-autoexec */ ++ if (use_scripts_checkbox && (G.f & G_SCRIPT_OVERRIDE_PREF)) ++ RNA_def_property_clear_flag(use_scripts_checkbox, PROP_EDITABLE); + } + + /* **************** link/append *************** */ +diff -Npur blender-2.60a.orig/source/creator/creator.c blender-2.60a/source/creator/creator.c +--- blender-2.60a.orig/source/creator/creator.c 2011-11-09 20:56:11.899602401 +0100 ++++ blender-2.60a/source/creator/creator.c 2011-11-09 21:17:22.278579932 +0100 +@@ -258,6 +258,7 @@ static int print_help(int UNUSED(argc), + + printf("\n"); + ++ BLI_argsPrintArgDoc(ba, "-666"); + BLI_argsPrintArgDoc(ba, "--enable-autoexec"); + BLI_argsPrintArgDoc(ba, "--disable-autoexec"); + +@@ -326,14 +327,14 @@ static int end_arguments(int UNUSED(argc + static int enable_python(int UNUSED(argc), const char **UNUSED(argv), void *UNUSED(data)) + { + G.f |= G_SCRIPT_AUTOEXEC; +- G.f |= G_SCRIPT_OVERRIDE_PREF; ++ G.f &= ~G_SCRIPT_OVERRIDE_PREF; /* Enables turning G_SCRIPT_AUTOEXEC off from user prefs */ + return 0; + } + + static int disable_python(int UNUSED(argc), const char **UNUSED(argv), void *UNUSED(data)) + { + G.f &= ~G_SCRIPT_AUTOEXEC; +- G.f |= G_SCRIPT_OVERRIDE_PREF; ++ G.f |= G_SCRIPT_OVERRIDE_PREF; /* Disables turning G_SCRIPT_AUTOEXEC on from user prefs */ + return 0; + } + +@@ -1055,8 +1056,9 @@ static void setupArguments(bContext *C, + # define PY_DISABLE_AUTO ", (compiled as non-standard default)" + #endif + +- BLI_argsAdd(ba, 1, "-y", "--enable-autoexec", "\n\tEnable automatic python script execution" PY_ENABLE_AUTO, enable_python, NULL); +- BLI_argsAdd(ba, 1, "-Y", "--disable-autoexec", "\n\tDisable automatic python script execution (pydrivers, pyconstraints, pynodes)" PY_DISABLE_AUTO, disable_python, NULL); ++ BLI_argsAdd(ba, 1, NULL, "-666", "\n\tEnable automatic python script execution (port from CVE-2009-3850 patch to Blender 2.60a)" PY_ENABLE_AUTO, enable_python, NULL); ++ BLI_argsAdd(ba, 1, "-y", "--enable-autoexec", "\n\tEnable automatic python script execution" PY_ENABLE_AUTO, enable_python, NULL); ++ BLI_argsAdd(ba, 1, "-Y", "--disable-autoexec", "\n\tDisable automatic python script execution (pydrivers, pyconstraints, pynodes)" PY_DISABLE_AUTO, disable_python, NULL); + + #undef PY_ENABLE_AUTO + #undef PY_DISABLE_AUTO diff --git a/media-gfx/blender/files/blender-2.60a-enable_site_module.patch b/media-gfx/blender/files/blender-2.60a-enable_site_module.patch new file mode 100644 index 000000000000..8a44c36014f0 --- /dev/null +++ b/media-gfx/blender/files/blender-2.60a-enable_site_module.patch @@ -0,0 +1,32 @@ +--- source/blender/python/intern/bpy_interface.c ++++ source/blender/python/intern/bpy_interface.c +@@ -203,11 +203,6 @@ + /* allow to use our own included python */ + PyC_SetHomePath(BLI_get_folder(BLENDER_SYSTEM_PYTHON, NULL)); + +- /* Python 3.2 now looks for '2.58/python/include/python3.2d/pyconfig.h' to parse +- * from the 'sysconfig' module which is used by 'site', so for now disable site. +- * alternatively we could copy the file. */ +- Py_NoSiteFlag= 1; +- + Py_Initialize(); + + // PySys_SetArgv(argc, argv); // broken in py3, not a huge deal +--- source/gameengine/Ketsji/KX_PythonInit.cpp ++++ source/gameengine/Ketsji/KX_PythonInit.cpp +@@ -1825,7 +1825,6 @@ + STR_String pname = progname; + Py_SetProgramName(pname.Ptr()); + #endif +- Py_NoSiteFlag=1; + Py_FrozenFlag=1; + + /* must run before python initializes */ +@@ -1898,7 +1897,6 @@ + STR_String pname = progname; + Py_SetProgramName(pname.Ptr()); + #endif +- Py_NoSiteFlag=1; + Py_FrozenFlag=1; + + initPyTypes(); diff --git a/media-gfx/blender/files/blender-2.60a-insecure.desktop b/media-gfx/blender/files/blender-2.60a-insecure.desktop new file mode 100644 index 000000000000..184c2ae4d6d2 --- /dev/null +++ b/media-gfx/blender/files/blender-2.60a-insecure.desktop @@ -0,0 +1,15 @@ +[Desktop Entry] +Name=Blender-2.6 (reduced security) +GenericName=3D modeller +GenericName[es]=modelador 3D +GenericName[de]=3D Modellierer +GenericName[fr]=modeleur 3D +GenericName[ru]=Редактор 3D-моделей +Comment=3D modeling, animation, rendering and post-production +Comment[es]=modelado 3D, animación, renderizado y post-producción +Exec=blender-2.60 --enable-autoexec +Icon=blender-2.60 +Terminal=false +Type=Application +Categories=Graphics;3DGraphics; +MimeType=application/x-blender; diff --git a/media-gfx/blender/files/blender-2.60a-libav-0.7.patch b/media-gfx/blender/files/blender-2.60a-libav-0.7.patch new file mode 100644 index 000000000000..9bf321649036 --- /dev/null +++ b/media-gfx/blender/files/blender-2.60a-libav-0.7.patch @@ -0,0 +1,28 @@ +--- blender-2.60a.orig/intern/audaspace/ffmpeg/AUD_FFMPEGWriter.cpp 2011-10-24 20:09:01.000000000 +0200 ++++ blender-2.60a/intern/audaspace/ffmpeg/AUD_FFMPEGWriter.cpp 2011-11-13 12:34:01.000000000 +0100 +@@ -40,6 +40,7 @@ + #include <libavcodec/avcodec.h> + #include <libavformat/avformat.h> + #include <libavformat/avio.h> ++#include <libavutil/mathematics.h> + #include "ffmpeg_compat.h" + } + +@@ -57,10 +58,14 @@ + { + static const char* formats[] = { NULL, "ac3", "flac", "matroska", "mp2", "mp3", "ogg", "wav" }; + +- if(avformat_alloc_output_context2(&m_formatCtx, NULL, formats[format], filename.c_str())) +- AUD_THROW(AUD_ERROR_FFMPEG, context_error); ++ m_formatCtx = avformat_alloc_context(); ++ if (!m_formatCtx) AUD_THROW(AUD_ERROR_FFMPEG, context_error); + +- m_outputFmt = m_formatCtx->oformat; ++ m_outputFmt = m_formatCtx->oformat = av_guess_format(formats[format], filename.c_str(), NULL); ++ if (!m_outputFmt) { ++ avformat_free_context(m_formatCtx); ++ AUD_THROW(AUD_ERROR_FFMPEG, context_error); ++ } + + switch(codec) + { diff --git a/media-gfx/blender/files/blender-2.60a-linux-3.patch b/media-gfx/blender/files/blender-2.60a-linux-3.patch new file mode 100644 index 000000000000..6a96b49d12ca --- /dev/null +++ b/media-gfx/blender/files/blender-2.60a-linux-3.patch @@ -0,0 +1,12 @@ +--- SConstruct 2011-10-29 05:18:43.149564401 +0200 ++++ SConstruct 2011-10-29 05:19:37.332887017 +0200 +@@ -165,6 +165,9 @@ + if crossbuild and platform not in ('win32-vc', 'win64-vc'): + platform = 'linuxcross' + ++if platform == 'linux3': ++ platform = 'linux2' # Workaround for Linux 3.x ++ + env['OURPLATFORM'] = platform + + configfile = os.path.join("build_files", "scons", "config", platform + "-config.py") diff --git a/media-gfx/blender/files/blender-desktop.patch b/media-gfx/blender/files/blender-desktop.patch new file mode 100644 index 000000000000..515a79d35138 --- /dev/null +++ b/media-gfx/blender/files/blender-desktop.patch @@ -0,0 +1,20 @@ +--- release/freedesktop/blender.desktop 2010-09-12 00:05:51.000000000 -0700 ++++ release/freedesktop/blender.desktop 2010-09-12 00:07:32.000000000 -0700 +@@ -1,5 +1,5 @@ + [Desktop Entry] +-Name=Blender ++Name=Blender-2.6 + GenericName=3D modeller + GenericName[es]=modelador 3D + GenericName[de]=3D Modellierer +@@ -7,8 +7,8 @@ + GenericName[ru]=Редактор 3D-моделей + Comment=3D modeling, animation, rendering and post-production + Comment[es]=modelado 3D, animación, renderizado y post-producción +-Exec=blender +-Icon=blender ++Exec=blender-2.60 ++Icon=blender-2.60 + Terminal=false + Type=Application + Categories=Graphics;3DGraphics; |