summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'media-gfx/blender')
-rw-r--r--media-gfx/blender/Manifest50
-rw-r--r--media-gfx/blender/blender-2.60a.ebuild441
-rw-r--r--media-gfx/blender/blender-2.61-r1.ebuild425
-rw-r--r--media-gfx/blender/blender-2.61-r2.ebuild410
-rw-r--r--media-gfx/blender/blender-2.61-r3.ebuild437
-rw-r--r--media-gfx/blender/blender-2.61-r4.ebuild438
-rw-r--r--media-gfx/blender/blender-2.61.ebuild145
-rw-r--r--media-gfx/blender/files/blender-2.60-bullet.patch192
-rw-r--r--media-gfx/blender/files/blender-2.60-colamd.patch204
-rw-r--r--media-gfx/blender/files/blender-2.60-libav-0.7.patch30
-rw-r--r--media-gfx/blender/files/blender-2.60-linux-3.patch12
-rw-r--r--media-gfx/blender/files/blender-2.60a-cmake.patch67
-rw-r--r--media-gfx/blender/files/blender-2.61-CVE-2009-3850-v3.patch146
-rw-r--r--media-gfx/blender/files/blender-2.61-CVE-2009-3850-v4.patch164
-rw-r--r--media-gfx/blender/files/blender-2.61-collada.patch11
-rw-r--r--media-gfx/blender/files/blender-2.61-desktop.patch20
-rw-r--r--media-gfx/blender/files/blender-2.61-eigen.patch543
-rw-r--r--media-gfx/blender/files/blender-2.61-enable_site_module.patch31
-rw-r--r--media-gfx/blender/files/blender-2.61-glew.patch44
-rw-r--r--media-gfx/blender/files/blender-2.61-insecure.desktop15
-rw-r--r--media-gfx/blender/files/blender-desktop.patch20
-rw-r--r--media-gfx/blender/metadata.xml67
22 files changed, 3812 insertions, 100 deletions
diff --git a/media-gfx/blender/Manifest b/media-gfx/blender/Manifest
index 70770e6..f2904dd 100644
--- a/media-gfx/blender/Manifest
+++ b/media-gfx/blender/Manifest
@@ -1,40 +1,34 @@
-AUX blender-2.37-dirs.patch 727 RMD160 ddf5c951182f809374c43f1a1cce47f4397a868c SHA1 9b3cb06a8bd23b1a5041bd3193018c2e5e28dcfd SHA256 beb5e5835cde71a00712ddf600278ca0bbdb6020123faeb6ea7a53e8f6812e5e
-AUX blender-2.44-scriptsdir.patch 2586 RMD160 8e80859edf1fae2f401b326be4cb939108879999 SHA1 50143946828d3f2b2568e71fae5ed28f6adf7449 SHA256 a7afac10ce2431cd94d10dc3f4cae33423b5a59d0c6918199006f623cd6d68e4
-AUX blender-2.46-cve-2008-1103-1.patch 636 RMD160 11d0b7dbff6e186334a80b7f6932ace4a1bd6628 SHA1 979fa1c2f0836b46dfd26c197798625a72e0a28b SHA256 a0dd64fb749a9577d84e22896872dc2956a8530700308d0aadad588191356b96
-AUX blender-2.46-ffmpeg.patch 3823 RMD160 33f41651b1a6bc6d497ba01ab710ca3d7a1559c0 SHA1 82ce585db15a3c88625b0c04e649bd08b3c35b41 SHA256 ad75babcc08ae41f2a7c71bc457bd56a0ef39b5ae1e92ede2cdb0a34d7cbcc85
-AUX blender-2.48-ffmpeg-20081014.patch 839 RMD160 b1fbad04a890dcc1698d02f5351d6d79cae42d91 SHA1 e931f1a85c5c01918b960936d4da5888eacfd64c SHA256 d6114d2647758e39608fcfdb05da00811f062ea3fc4c41cef3a6e2977bc5b0c4
-AUX blender-2.48a-CVE-2008-4863.patch 696 RMD160 b61dc085d0154be3850fa4b53985f670cd177adf SHA1 805f18290965c2e74778628c4e2a1888ea77d8ab SHA256 fee1896c791a623181ebf681f4ad67c610677e82575a95a46e896b747f980418
-AUX blender-2.49a-bake.patch 669 RMD160 19e167e2d3c8fcd573f9755dee8c6cb59984829e SHA1 5ae418e697c90418cf65652134b08ba6da3f93c1 SHA256 dcaaaba19ad57b6d054df830dfa303c4656303622e1e7ef15817d304958d8f3c
-AUX blender-2.49a-sys-openjpeg.patch 452 RMD160 7029b3d257839d4ca8ce58a9f8e46503651b1765 SHA1 85551623c4293d9dff4dc8d26584a753b3ccd581 SHA256 437f016b9f7c48281015838a22203c4db9ef6b62dac01aa86faa1c9793bff182
-AUX blender-2.49b-CVE-2009-3850-v3.patch 3891 RMD160 9a51681f426f1f87cc418b6316ce678025a93bbb SHA1 dc7baef8f0434e067f863e0a2c6ef0d8d9acc70b SHA256 5dc289f00ab59b13b7f1d3e8b4a77b8c9930460f8ee575b38a60da3577e2b1ba
-AUX blender-2.49b-CVE-2009-3850-v4.patch 5222 RMD160 1757323e4aa0ffa0e1b3ab14dcaa78188a39ae36 SHA1 5d432fbe575b1869a7e68e753e593edcc3478b35 SHA256 0707904cd3b627cfeac19d4d775ee4a019ba395251c9318dbb356e3b8de19124
-AUX blender-2.49b-insecure.desktop 223 RMD160 70719305e80334e805c73ccbd831243202ac65b6 SHA1 1633779552c5409f20f161e21b60a59417dad3cf SHA256 dfd0a438ebf792071fc9f12036f07b0f14277b2bf34050bf4d57ffceeff55555
-AUX blender-2.49b-libav-0.7.patch 15251 RMD160 c04ec7fc4fff2665c9b55f793e8995c0c0d64932 SHA1 9924e51d1ffee6af3ffe7aed5131f98f298e7b32 SHA256 636244001abc882887b7c72f665c751a86a96f355ec196a49390b8d13180cec5
-AUX blender-2.49b-subversion-1.7.patch 477 RMD160 0528267fd3f2d92f000855023b0fc8ed1e1e4ef7 SHA1 a02f988c8aaee76fc7586ca82c8f9d8329cdbb77 SHA256 744c7af5f0fdc24c84262748991c397b171c33246bb319ba5d3a54a4eda5da2a
-AUX blender-2.57-CVE-2009-3850-v1.patch 4894 RMD160 6680a3e54d8d65c050886d1601bfb8e022633425 SHA1 91ecd5bdfa69bb46b6688e1200aae0f90bc04b52 SHA256 d64afd9ddef2fc3796c0e0398bf8fecc96a18176945642b2ae3445da2de69a26
-AUX blender-2.57-CVE-2009-3850-v2.patch 8435 RMD160 07cbf22a258a31e6a1d050a6d13763f52ba50d66 SHA1 a1f969ba2ae85d1461f991043b66c372fc4d44c2 SHA256 a3d6d884d487604bdf9fc3ee78c8cf1fb10921ac0ec12ebd9d6e590093d9e98c
-AUX blender-2.57-bmake.patch 422 RMD160 b0270fbc11d9afce5989fcdb21234ec734ef946a SHA1 094d739127960386013677ea638397485422121f SHA256 a9282a6746062824ccdc12f5a6055aa4c71feba269fafebb8e83916fc2e61245
-AUX blender-2.57-desktop.patch 640 RMD160 86091d314085d31c4c00bab3996e1b313f4e6cf6 SHA1 7306596987f0c6ad2ac4aef9556adc31b2596c0f SHA256 0ddb29736fae671c5ce2b6ab719fb7c15d39f0f2ba2bf513674c6ea9711497fb
-AUX blender-2.57-doxygen.patch 1316 RMD160 6e9538481aa0aa4225ace5cc272fe37214499f39 SHA1 f40661daba59ee6efa449c644dba9da634f8eaf1 SHA256 6c5ad9e44bfe768efe69e208fdfd22a4ac87af8b1bdce816ac07a81eb4df6848
-AUX blender-2.57-eigen.patch 940 RMD160 9acf7cd0fadb1fac515a16535d82569d2adb110b SHA1 8f2ba202d10abb32bda7c220465f7db0d616b8c5 SHA256 a5bb17c7bd2f68dd44d439c0a72302654b204a8d3da9a4a6365a85396c4bc3ea
-AUX blender-2.57-enable_site_module.patch 939 RMD160 66b521662bdde9ae520348d970e66b7750c6ea99 SHA1 a2cf1a535e3c3165c19bff770a259295498a8747 SHA256 9e74736321ef56ee23432cb47a0f85bd2c4891c5682ed0858a2d2e776ee36b40
-AUX blender-2.57-glew.patch 443 RMD160 bc2606d216bd9231a96fc7bd891deaf13f710c93 SHA1 3cb12219dcfa6045b96325dcbc4192a4c065c5bf SHA256 002e144e516d7532f450565a176af736146d74d7de1ab18b1ad4796c12f26a0f
-AUX blender-2.57-insecure.desktop 595 RMD160 e0040e5f3d0048361cf2d203ff2e6b551d077f86 SHA1 45a2ad8542840fa4f773ec51134c29638dd456d2 SHA256 2b09e8898d4b2280967224a3c3592dbc74170726f56d269a6df0b0985a3691be
-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-bullet.patch 7975 RMD160 3309d8ff9b5784963c85b0ec6fa5be29dab70015 SHA1 978d53a49fe76f107899432a4a88975cead1dddc SHA256 5b76da258eb6ce5533afa400838ee87819aece386911993de69a7864d0290467
+AUX blender-2.60-colamd.patch 8814 RMD160 e9b43b6a17c5328c5ca90cfec2bc2abcb53b2554 SHA1 eab44bd70212e4d029e0484b09cd7779e1ef751c SHA256 39432e50395c70f19f599cc35a35426fccc3b6675eec6a0696955e18d4f05f8d
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-libav-0.7.patch 1181 RMD160 66dc84d6ca37a97bb43886ed86b72499383636b6 SHA1 be60d7fd39821fb28b3e23a659df8f7eb51d1f60 SHA256 d8e7a08b042ce8311bd71e2edec7457ddf8fe8b64243f30f179d391ea170ab50
+AUX blender-2.60-linux-3.patch 414 RMD160 cb1cfc00e363e00c67a3c6d3567768418be78f39 SHA1 71f4701aa2e88de35843661cf5eecfe411ccd99b SHA256 4f1f8960e1b5706b426e272c17b70682b1eaa5903fa325e4d4db21efd540d732
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-collada.patch 1402 RMD160 89c91ad636614f06ab8b007c5064c06171943ebf SHA1 a2e444d6c25f07d07a9b77eee2a364015a57c28d SHA256 0b5d31b31e113053a998a8c16244b2d5801a8dac0f63fbd5905a51308981b4af
+AUX blender-2.60a-cmake.patch 1878 RMD160 c8e2c5f77fad86475b10b4634ba6efdf1f8f3ac4 SHA1 8e0c38ed3fe1bdfeb74ac6313d4aaae661fd742c SHA256 540602705f85971378fe86e28c2ac888a21085c49a6fe1cca762b30b922e77e8
AUX blender-2.60a-desktop.patch 643 RMD160 43b8eaaef300fac4ebf463eb024356f65f76b7f5 SHA1 1b77d5a0c5ffe791117cfe140a7b3626bd3ba21b SHA256 8f2a7619d82a7ea64ade59aa067f2e6469129fe682b88f7c3ac6975650947ec1
AUX blender-2.60a-enable_site_module.patch 974 RMD160 e93ddcd1372751951b6e56f72c764e2043747574 SHA1 84aed7ab30f5de1989ee63b4584db7acd6747b54 SHA256 dfafc00a08504c0c3259083d01e535e00f9a952db4a551dbacf0a62ad1a5c768
AUX blender-2.60a-insecure.desktop 594 RMD160 48d7b683f4ae057a1766dabb267e5048e92114f6 SHA1 1d6d2c61a0c79b6c78842ad354746ffe5a2d7ffa SHA256 2b7920c517c93d4f1430dc7ee70a414d32c1b17648a0e8395bbd900d1be8dd84
AUX blender-2.60a-libav-0.7.patch 1181 RMD160 66dc84d6ca37a97bb43886ed86b72499383636b6 SHA1 be60d7fd39821fb28b3e23a659df8f7eb51d1f60 SHA256 d8e7a08b042ce8311bd71e2edec7457ddf8fe8b64243f30f179d391ea170ab50
AUX blender-2.60a-linux-3.patch 414 RMD160 cb1cfc00e363e00c67a3c6d3567768418be78f39 SHA1 71f4701aa2e88de35843661cf5eecfe411ccd99b SHA256 4f1f8960e1b5706b426e272c17b70682b1eaa5903fa325e4d4db21efd540d732
-AUX blender.desktop 199 RMD160 a55286923d1422f620dff35226a42fcbaf8c60a9 SHA1 c5ad8c540571a254756ac541c64933e80406aa16 SHA256 3fbab5be3f52ce56f285e422c856aecd15627cffeadcb07af313e0d64c4803ad
-AUX blender.png 2119 RMD160 e06574002001f41198dc9408ef1bba45493fcc27 SHA1 9a0d713235ce99f8e4fde4f062209ab989e48c0f SHA256 bef633319c81323bb82db274004d89082ca05cab6650eb4c4bf43f830ccb5cad
+AUX blender-2.61-CVE-2009-3850-v3.patch 7515 RMD160 0faf4de3a330fd2920bdf2b688d3bc5cb530d86f SHA1 77c637a4e6be816534887dab06614bb3dddad3af SHA256 f9d2eb3e09d30c21a3f51de34bc978d25c598a2fc420e809ea49293c55178139
+AUX blender-2.61-CVE-2009-3850-v4.patch 9194 RMD160 cf5519882821c318f32ac3ff16f0a73998941228 SHA1 91e029b6bcdad6adec3034dc313604cae9f9d4dd SHA256 bcf6155d39ee3a31422ddfd21e729bce542a181ebdcfd9c4a6e40c37e06b9485
+AUX blender-2.61-collada.patch 1402 RMD160 89c91ad636614f06ab8b007c5064c06171943ebf SHA1 a2e444d6c25f07d07a9b77eee2a364015a57c28d SHA256 0b5d31b31e113053a998a8c16244b2d5801a8dac0f63fbd5905a51308981b4af
+AUX blender-2.61-desktop.patch 645 RMD160 ecba28ff2be0a72da11adf4f5b6a0dcdcb5af881 SHA1 d128fad9689e07758958915a74ba647b9a919bfd SHA256 e5936f45e1c0a1e0fa723609a66d8818c045cd56d3927ffbbd941d09cdbe4878
+AUX blender-2.61-eigen.patch 27106 RMD160 3042ba69913c98531ad60bd3a7fadf7817c5b062 SHA1 cde414399438b7d9ea7e756ef86aa08b5c9983e2 SHA256 e1e465f158a49287795d0f1a046d59b8d7ff8459c3ea8d57ee4b40518897d903
+AUX blender-2.61-enable_site_module.patch 1061 RMD160 60ba42b15c490776200fa0eea38ae7c856a1f567 SHA1 a9e5bf42d9b6ade5fb595009c6fde7412b002a8f SHA256 3d7b7c0814d97ed5db76828e243120782a0fb0a5304b90d978c3a20e1fb37a83
+AUX blender-2.61-glew.patch 1495 RMD160 86060b81c7649f9a47c44ce1f7393b5bc3becab1 SHA1 9612b2c580b640f8fd1509c70509b9816f05d176 SHA256 2c65e2bdf281672e2e25ca9d31afb66b3e34492dda7a5c613cd235ca78b0e45e
+AUX blender-2.61-insecure.desktop 596 RMD160 7fa4487d101479c5efcc83eddc23efe6dacfdb39 SHA1 28258b7bec5a07a025bb9b41a0ce63a11754b5a0 SHA256 65f98a4bdcaed85204bf83c26e65f16df05f5167b1703ae25b1e231c4845d91e
+AUX blender-desktop.patch 641 RMD160 5be612d2836005e51e1bcfed10959e75315f201f SHA1 b0f99cdefc6c1a21b32ea97a237e214b22e5f9e6 SHA256 f52bc6f42eb07e693bfbe578747cf126b242b04273cbcd78a8ee4879eae8b514
+DIST blender-2.60a.tar.gz 25679123 RMD160 74434c4e748872322386971cf6021255b0bfa1c8 SHA1 f23551e6ed661626c61de4a758d9ff67e0f27529 SHA256 7d788599ab46dac37f630dec026d06f7e3d73508f243eeb4ade8bcdcb661f124
DIST blender-2.61.tar.gz 25087312 RMD160 fb3b368144d31cd850a0602b7b5e746fca17d7fc SHA1 1b0d008e8022cb29efc9b4a337379eeb93bdcbb7 SHA256 58563583c8775fa0f746a7f4899b1619fec3df69accfa536544fdcbf372685f1
-EBUILD blender-2.61.ebuild 14089 RMD160 6d4fc28b664a454eb8b9f3940881c16f70a71c0b SHA1 b676b31bf9263087938e773dc5b469de5edb47e8 SHA256 0fad2e263cbd85fc3a4b346f7aa43762da4415a4565319b3436a8651794aa721
+EBUILD blender-2.60a.ebuild 13758 RMD160 1d9cb5abdcc1759472279364dcc013d496cad75f SHA1 3c1103e7212dc61169411a46f5b74377b744f352 SHA256 8046fa06274b9299711717cc936ede7bf9209e532cad1a969a89888a1a9c85d5
+EBUILD blender-2.61-r1.ebuild 12980 RMD160 7091e4afa22d95a9b987d4bc71553a1476727117 SHA1 d6bc4a0f3621dd23a490df389ce97652cc5719e2 SHA256 f5f53b533913fa391b393d51b2b27d073c51abf8ef7c5e700a9a4a7fe50a07be
+EBUILD blender-2.61-r2.ebuild 12241 RMD160 2a144de5c5f8d8d932ad557e60011779124e9d8c SHA1 bbc7e9a3ae37c3f433ae036806469a95b47154cc SHA256 09c29d5f6058b98735068c00e9e9f1d8285b7f4d40cddcbae1cf67e1fdf8311c
+EBUILD blender-2.61-r3.ebuild 13125 RMD160 533c391781524dd3969ac49cab7b905810a866f1 SHA1 46326c1d1e43d568a51ac3ed19563ecfe2560800 SHA256 7fcdacc128aa3619f84c37b23d747cc72f797f94c416a7000f64137b56ed55ba
+EBUILD blender-2.61-r4.ebuild 13144 RMD160 19376c7c8b54d9ee5a23a3c8d01f3e0c3a73e9fd SHA1 a38dd22149ba3ea6205133fc0640906bf9f7cce9 SHA256 72e87ed43c6ce49c4db213afb1e12845bb7a5d434d570ee0c51075169583c9f7
+EBUILD blender-2.61.ebuild 13765 RMD160 da7073339b97bcea808cd152e0a871f9c2bc0b4e SHA1 01d4b4b9476471ad02ab33b1a06024929041e85f SHA256 46c08fa0d152ee4b491bf8c139de5d32c8335004a13f031f58c38cbba93d756d
+MISC metadata.xml 2031 RMD160 7cef28cc97256936c8420d9399c5469dc917f7d1 SHA1 734027d18091dc859e24ec436f7ac992521223d7 SHA256 2aec9b99fcd11925094c06634d41af4cd3681cb81b404cc170b230dd4e337d13
diff --git a/media-gfx/blender/blender-2.60a.ebuild b/media-gfx/blender/blender-2.60a.ebuild
new file mode 100644
index 0000000..1817991
--- /dev/null
+++ b/media-gfx/blender/blender-2.60a.ebuild
@@ -0,0 +1,441 @@
+# 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 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 3dmouse"
+
+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 )
+ 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}"/${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' \
+ '3dmouse' ; 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/$(get_libdir)/${PN}/${SLOT}/plugins/texture
+ doexe "${WORKDIR}"/${P}/release/plugins/texture/*.so
+ exeinto /usr/$(get_libdir)/${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/blender-2.61-r1.ebuild b/media-gfx/blender/blender-2.61-r1.ebuild
new file mode 100644
index 0000000..7faa404
--- /dev/null
+++ b/media-gfx/blender/blender-2.61-r1.ebuild
@@ -0,0 +1,425 @@
+# 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 scons-utils eutils python versionator flag-o-matic toolchain-funcs ${SCM}
+
+IUSE="cycles +game-engine player +elbeem +openexr ffmpeg jpeg2k openal openmp \
+ +dds debug doc fftw jack apidoc sndfile tweak-mode sdl sse \
+ redcode +zlib iconv contrib 3dmouse"
+
+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
+ >=sci-physics/bullet-2.76
+ dev-cpp/eigen:3
+ cycles? (
+ media-libs/openimageio
+ dev-libs/boost
+ )
+ 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 )
+ 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
+
+ # 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
+
+ # 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
+}
+
+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 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' \
+ 'jack' \
+ 'sndfile' \
+ 'openexr' \
+ 'dds' \
+ 'fftw fftw3' \
+ 'jpeg2k openjpeg' \
+ 'openal'\
+ 'ffmpeg' \
+ 'ffmpeg ogg' \
+ 'player' \
+ 'sse rayoptimization' \
+ 'redcode' \
+ 'zlib' \
+ '3dmouse' ; 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
+
+ # 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
+
+ # 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 || 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}/${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
+ 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/blender-2.61-r2.ebuild b/media-gfx/blender/blender-2.61-r2.ebuild
new file mode 100644
index 0000000..afd0805
--- /dev/null
+++ b/media-gfx/blender/blender-2.61-r2.ebuild
@@ -0,0 +1,410 @@
+# 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 scons-utils eutils python versionator flag-o-matic toolchain-funcs ${SCM}
+
+IUSE="cycles +game-engine player +elbeem +openexr ffmpeg jpeg2k openal openmp \
+ +dds debug doc fftw jack apidoc sndfile tweak-mode sdl sse \
+ redcode +zlib iconv contrib 3dmouse"
+
+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
+ >=sci-physics/bullet-2.78
+ dev-cpp/eigen:3
+ cycles? (
+ media-libs/openimageio
+ dev-libs/boost
+ )
+ 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 )
+ 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
+
+ # 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
+
+ # 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
+}
+
+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 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' \
+ 'jack' \
+ 'sndfile' \
+ 'openexr' \
+ 'dds' \
+ 'fftw fftw3' \
+ 'jpeg2k openjpeg' \
+ 'openal'\
+ 'ffmpeg' \
+ 'ffmpeg ogg' \
+ 'player' \
+ 'sse rayoptimization' \
+ 'redcode' \
+ 'zlib' \
+ '3dmouse' ; 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
+
+ # 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
+
+ # 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 || 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}/${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/blender-2.61-r3.ebuild b/media-gfx/blender/blender-2.61-r3.ebuild
new file mode 100644
index 0000000..8342d9a
--- /dev/null
+++ b/media-gfx/blender/blender-2.61-r3.ebuild
@@ -0,0 +1,437 @@
+# 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 debug doc fftw jack apidoc sndfile tweak-mode sdl sse \
+ redcode +zlib iconv contrib collada 3dmouse"
+
+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
+ >=sci-physics/bullet-2.78
+ dev-cpp/eigen:3
+ sci-libs/colamd
+ cycles? (
+ media-libs/openimageio
+ dev-libs/boost
+ )
+ 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 )
+ 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
+
+ # 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}"/${PN}-${SLOT}-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
+}
+
+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
+
+ # 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' \
+ 'jack' \
+ 'sndfile' \
+ 'openexr' \
+ 'dds' \
+ 'fftw fftw3' \
+ 'jpeg2k openjpeg' \
+ 'openal'\
+ 'ffmpeg' \
+ 'ffmpeg ogg' \
+ 'player' \
+ 'sse rayoptimization' \
+ 'redcode' \
+ 'zlib' \
+ '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
+ use debug && 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 || 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}/${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/blender-2.61-r4.ebuild b/media-gfx/blender/blender-2.61-r4.ebuild
new file mode 100644
index 0000000..e677736
--- /dev/null
+++ b/media-gfx/blender/blender-2.61-r4.ebuild
@@ -0,0 +1,438 @@
+# 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 debug doc fftw jack apidoc sndfile tweak-mode sdl sse \
+ redcode +zlib iconv contrib collada 3dmouse"
+
+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
+ >=sci-physics/bullet-2.78
+ dev-cpp/eigen:3
+ sci-libs/colamd
+ cycles? (
+ media-libs/openimageio
+ dev-libs/boost
+ )
+ 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 )
+ 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
+
+ # 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}"/${PN}-${SLOT}-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
+}
+
+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' \
+ 'zlib' \
+ '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
+ use debug && 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 || 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}/${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/blender-2.61.ebuild b/media-gfx/blender/blender-2.61.ebuild
index 7bc9899..f24e5c2 100644
--- a/media-gfx/blender/blender-2.61.ebuild
+++ b/media-gfx/blender/blender-2.61.ebuild
@@ -1,6 +1,6 @@
-# Copyright 1999-2012 Gentoo Foundation
+# 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.6 2012/01/23 18:34:59 ssuominen Exp $
+# $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
@@ -10,11 +10,11 @@ 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 ${SCM}
+inherit scons-utils eutils python versionator flag-o-matic toolchain-funcs ${SCM}
-IUSE="+game-engine player +elbeem +openexr ffmpeg jpeg2k openal openmp \
+IUSE="cycles +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 collada verse"
+ redcode +zlib iconv contrib 3dmouse"
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
@@ -32,22 +32,26 @@ else # Official release
fi
#SLOT="$(get_version_component_range 1-2)"
-SLOT="2.61"
+SLOT="2.60"
LICENSE="|| ( GPL-2 BL )"
-KEYWORDS="amd64 x86"
+KEYWORDS="~amd64 ~x86"
RDEPEND="virtual/jpeg
- media-libs/libpng:0
+ media-libs/libpng
x11-libs/libXi
x11-libs/libX11
- media-libs/tiff:0
+ 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
+ dev-cpp/eigen:3
+ cycles? (
+ media-libs/openimageio
+ dev-libs/boost
+ )
iconv? ( virtual/libiconv )
zlib? ( sys-libs/zlib )
sdl? ( media-libs/libsdl[audio,joystick] )
@@ -60,8 +64,8 @@ RDEPEND="virtual/jpeg
fftw? ( sci-libs/fftw:3.0 )
jack? ( media-sound/jack-audio-connection-kit )
sndfile? ( media-libs/libsndfile )
- lcms? ( media-libs/lcms:0 )
- collada? ( media-libs/opencollada )"
+ lcms? ( media-libs/lcms )
+ 3dmouse? ( dev-libs/libspnav )"
DEPEND="dev-util/scons
apidoc? (
@@ -118,8 +122,6 @@ pkg_setup() {
src_prepare() {
epatch "${FILESDIR}"/${P}-desktop.patch
- epatch "${FILESDIR}"/${P}-collada.patch
- epatch "${FILESDIR}"/${PN}-${SLOT}-doxyfile.patch
# TODO: write a proper Makefile to replace the borked bmake script
epatch "${FILESDIR}"/${PN}-${SLOT}-bmake.patch
@@ -133,17 +135,22 @@ src_prepare() {
# Glew
einfo "Removing bundled Glew ..."
rm -r extern/glew
- epatch "${FILESDIR}"/${PN}-${SLOT}-glew.patch
+ epatch "${FILESDIR}"/${P}-glew.patch
+
+ # Eigen3
+ einfo "Removing bundled Eigen3 ..."
+ rm -r extern/Eigen3
+ epatch "${FILESDIR}"/${P}-eigen.patch
- # Eigen2
- einfo "Removing bundled Eigen2 ..."
- rm -r extern/Eigen2
- epatch "${FILESDIR}"/${PN}-${SLOT}-eigen.patch
+ # Bullet2
+ einfo "Removing bundled Bullet2 ..."
+ rm -r extern/bullet2
+ epatch "${FILESDIR}"/${PN}-${SLOT}-bullet.patch
# Linux 3.x (bug #381099)
- epatch "${FILESDIR}"/${P}-linux-3.patch
+ epatch "${FILESDIR}"/${PN}-${SLOT}-linux-3.patch
- epatch "${FILESDIR}"/${P}-libav-0.7.patch
+ epatch "${FILESDIR}"/${PN}-${SLOT}-libav-0.7.patch
epatch "${FILESDIR}"/${P}-CVE-2009-3850-v3.patch
epatch "${FILESDIR}"/${P}-enable_site_module.patch
}
@@ -166,12 +173,12 @@ src_configure() {
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
+ 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 iconv into Scons build options.
if use !elibc_glibc && use !elibc_uclibc && use iconv; then
@@ -273,20 +280,28 @@ src_configure() {
'sse rayoptimization' \
'redcode' \
'zlib' \
- 'collada' \
- 'verse' ; do
+ '3dmouse' ; do
blend_with ${arg}
done
- echo 'BF_OPENCOLLADA_INC="/usr/include/opencollada/"' >> "${S}"/user-config.py
- echo 'BF_OPENCOLLADA_LIBPATH="/usr/'$(get_libdir)'/opencollada/"' >> "${S}"/user-config.py
-
- # libspnav not yet packaged (bug #390427)
- echo 'WITH_BF_3DMOUSE=0' >> "${S}"/user-config.py
-
# 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
+
+ # 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() {
@@ -304,7 +319,7 @@ src_compile() {
src_install() {
# creating binary wrapper
- cat <<- EOF >> "${WORKDIR}/install/blender-${SLOT}"
+ cat <<- EOF >> "${WORKDIR}/install/blender-${PV}"
#!/bin/sh
# stop this script if the local blender path is a symlink
@@ -316,50 +331,43 @@ src_install() {
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} \$*
+ 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
# 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}"
+ 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-${SLOT}"
- doexe "${WORKDIR}/install/blenderplayer-${SLOT}"
+ "${WORKDIR}/install/blenderplayer-${PV}"
+ doexe "${WORKDIR}/install/blenderplayer-${PV}"
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/$(get_libdir)/${PN}/${SLOT}/plugins/texture
+ exeinto /usr/$(get_libdir)/${PN}/${PV}/plugins/texture
doexe "${WORKDIR}"/${P}/release/plugins/texture/*.so
- exeinto /usr/$(get_libdir)/${PN}/${SLOT}/plugins/sequences
+ exeinto /usr/$(get_libdir)/${PN}/${PV}/plugins/sequences
doexe "${WORKDIR}"/${P}/release/plugins/sequence/*.so
- insinto /usr/include/${PN}/${SLOT}
+ insinto /usr/include/${PN}/${PV}
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
+ 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-${SLOT}.svg
- doins release/freedesktop/icons/scalable/apps/blender-${SLOT}.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-${SLOT}.desktop
- doins release/freedesktop/blender-${SLOT}.desktop
- newins "${FILESDIR}"/${P}-insecure.desktop ${PN}-${SLOT}-insecure.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
@@ -383,7 +391,7 @@ src_install() {
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."
+ "${D}"/usr/bin/blender-bin-${PV} --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
@@ -403,8 +411,8 @@ src_install() {
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}/*
+ 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
@@ -413,13 +421,6 @@ src_install() {
# 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"
diff --git a/media-gfx/blender/files/blender-2.60-bullet.patch b/media-gfx/blender/files/blender-2.60-bullet.patch
new file mode 100644
index 0000000..05e47fb
--- /dev/null
+++ b/media-gfx/blender/files/blender-2.60-bullet.patch
@@ -0,0 +1,192 @@
+diff -Npur blender-2.61.orig/build_files/scons/tools/Blender.py blender-2.61/build_files/scons/tools/Blender.py
+--- blender-2.61.orig/build_files/scons/tools/Blender.py 2011-12-20 22:36:19.299620183 +0100
++++ blender-2.61/build_files/scons/tools/Blender.py 2011-12-20 22:36:50.517619833 +0100
+@@ -270,6 +270,8 @@ def setup_syslibs(lenv):
+ syslibs += Split(lenv['BF_SDL_LIB'])
+ if not lenv['WITH_BF_STATICOPENGL']:
+ syslibs += Split(lenv['BF_OPENGL_LIB'])
++ if lenv['WITH_BF_BULLET']:
++ syslibs += Split(lenv['BF_BULLET_LIB'])
+ if lenv['OURPLATFORM'] in ('win32-vc', 'win32-mingw','linuxcross', 'win64-vc'):
+ syslibs += Split(lenv['BF_PTHREADS_LIB'])
+ if lenv['WITH_BF_COLLADA']:
+diff -Npur blender-2.61.orig/doc/doxygen/Doxyfile blender-2.61/doc/doxygen/Doxyfile
+--- blender-2.61.orig/doc/doxygen/Doxyfile 2011-12-20 22:36:19.254620184 +0100
++++ blender-2.61/doc/doxygen/Doxyfile 2011-12-20 22:36:50.544619631 +0100
+@@ -617,8 +617,7 @@ INPUT = doxygen.main \
+ doxygen.intern \
+ doxygen.extern \
+ ../../source \
+- ../../intern \
+- ../../extern/bullet2
++ ../../intern
+
+ # This tag can be used to specify the character encoding of the source files
+ # that doxygen parses. Internally doxygen uses the UTF-8 encoding, which is
+diff -Npur blender-2.61.orig/extern/CMakeLists.txt blender-2.61/extern/CMakeLists.txt
+--- blender-2.61.orig/extern/CMakeLists.txt 2011-12-20 22:36:19.296620183 +0100
++++ blender-2.61/extern/CMakeLists.txt 2011-12-20 22:36:50.544619631 +0100
+@@ -28,10 +28,6 @@ remove_strict_flags()
+
+ add_subdirectory(colamd)
+
+-if(WITH_BULLET)
+- add_subdirectory(bullet2)
+-endif()
+-
+ if(WITH_MOD_CLOTH_ELTOPO)
+ add_subdirectory(eltopo)
+ endif()
+diff -Npur blender-2.61.orig/extern/SConscript blender-2.61/extern/SConscript
+--- blender-2.61.orig/extern/SConscript 2011-12-20 22:36:19.295620183 +0100
++++ blender-2.61/extern/SConscript 2011-12-20 22:36:50.544619631 +0100
+@@ -10,9 +10,6 @@ if env['WITH_BF_GAMEENGINE']:
+ if env['WITH_BF_ELTOPO']:
+ SConscript(['eltopo/SConscript'])
+
+-if env['WITH_BF_BULLET']:
+- SConscript(['bullet2/src/SConscript'])
+-
+ if env['WITH_BF_REDCODE'] and env['BF_REDCODE_LIB'] == '':
+ SConscript(['libredcode/SConscript'])
+
+diff -Npur blender-2.61.orig/intern/smoke/CMakeLists.txt blender-2.61/intern/smoke/CMakeLists.txt
+--- blender-2.61.orig/intern/smoke/CMakeLists.txt 2011-12-20 22:36:19.501620180 +0100
++++ blender-2.61/intern/smoke/CMakeLists.txt 2011-12-20 22:36:50.544619631 +0100
+@@ -26,10 +26,10 @@
+ set(INC
+ intern
+ ../memutil
+- ../../extern/bullet2/src
+ )
+
+ set(INC_SYS
++ /usr/include/bullet2
+ ${PNG_INCLUDE_DIR}
+ ${ZLIB_INCLUDE_DIRS}
+ )
+diff -Npur blender-2.61.orig/intern/smoke/SConscript blender-2.61/intern/smoke/SConscript
+--- blender-2.61.orig/intern/smoke/SConscript 2011-12-20 22:36:19.501620180 +0100
++++ blender-2.61/intern/smoke/SConscript 2011-12-20 22:36:50.545619631 +0100
+@@ -13,7 +13,7 @@ if env['WITH_BF_OPENMP']:
+ defs += ' PARALLEL=1'
+
+ incs += ' ' + env['BF_PNG_INC'] + ' ' + env['BF_ZLIB_INC']
+-incs += ' intern ../../extern/bullet2/src ../memutil ../guardealloc '
++incs += ' intern /usr/include/bullet ../memutil ../guardealloc '
+
+ if env['WITH_BF_FFTW3']:
+ defs += ' WITH_FFTW3'
+diff -Npur blender-2.61.orig/source/blender/blenkernel/CMakeLists.txt blender-2.61/source/blender/blenkernel/CMakeLists.txt
+--- blender-2.61.orig/source/blender/blenkernel/CMakeLists.txt 2011-12-20 22:36:19.325620183 +0100
++++ blender-2.61/source/blender/blenkernel/CMakeLists.txt 2011-12-20 22:36:50.545619631 +0100
+@@ -253,8 +253,8 @@ if(WITH_AUDASPACE)
+ endif()
+
+ if(WITH_BULLET)
+- list(APPEND INC
+- ../../../extern/bullet2/src
++ list(APPEND INC_SYS
++ /usr/include/bullet
+ )
+ add_definitions(-DUSE_BULLET)
+ endif()
+diff -Npur blender-2.61.orig/source/blender/blenkernel/SConscript blender-2.61/source/blender/blenkernel/SConscript
+--- blender-2.61.orig/source/blender/blenkernel/SConscript 2011-12-20 22:36:19.325620183 +0100
++++ blender-2.61/source/blender/blenkernel/SConscript 2011-12-20 22:36:50.545619631 +0100
+@@ -9,7 +9,7 @@ incs += ' ../blenlib ../blenfont ../make
+ incs += ' ../render/extern/include #/intern/decimation/extern ../makesrna'
+ incs += ' ../imbuf ../ikplugin ../avi #/intern/elbeem/extern ../nodes ../modifiers'
+ incs += ' #/intern/iksolver/extern ../blenloader'
+-incs += ' #/extern/bullet2/src'
++incs += ' /usr/include/bullet'
+ incs += ' #/intern/opennl/extern #/intern/bsp/extern'
+ incs += ' ../gpu #/extern/glew/include'
+ incs += ' #/intern/smoke/extern'
+diff -Npur blender-2.61.orig/source/gameengine/BlenderRoutines/CMakeLists.txt blender-2.61/source/gameengine/BlenderRoutines/CMakeLists.txt
+--- blender-2.61.orig/source/gameengine/BlenderRoutines/CMakeLists.txt 2011-12-20 22:36:19.307620183 +0100
++++ blender-2.61/source/gameengine/BlenderRoutines/CMakeLists.txt 2011-12-20 22:36:50.545619631 +0100
+@@ -23,7 +23,6 @@ set(INC
+ ../../blender/makesdna
+ ../../blender/makesrna
+ ../../blender/windowmanager
+- ../../../extern/bullet2/src
+ ../../../intern/container
+ ../../../intern/guardedalloc
+ ../../../intern/moto/include
+@@ -32,7 +31,7 @@ set(INC
+ )
+
+ set(INC_SYS
+-
++ /usr/include/bullet
+ )
+
+ set(SRC
+diff -Npur blender-2.61.orig/source/gameengine/Converter/CMakeLists.txt blender-2.61/source/gameengine/Converter/CMakeLists.txt
+--- blender-2.61.orig/source/gameengine/Converter/CMakeLists.txt 2011-12-20 22:36:19.311620183 +0100
++++ blender-2.61/source/gameengine/Converter/CMakeLists.txt 2011-12-20 22:36:50.545619631 +0100
+@@ -49,7 +49,6 @@ set(INC
+ ../../blender/makesdna
+ ../../blender/makesrna
+ ../../blender/windowmanager
+- ../../../extern/bullet2/src
+ ../../../intern/container
+ ../../../intern/guardedalloc
+ ../../../intern/moto/include
+@@ -59,6 +58,7 @@ set(INC
+
+ set(INC_SYS
+ /usr/include/eigen3
++ /usr/include/bullet
+ )
+
+ set(SRC
+diff -Npur blender-2.61.orig/source/gameengine/Ketsji/CMakeLists.txt blender-2.61/source/gameengine/Ketsji/CMakeLists.txt
+--- blender-2.61.orig/source/gameengine/Ketsji/CMakeLists.txt 2011-12-20 22:36:19.317620183 +0100
++++ blender-2.61/source/gameengine/Ketsji/CMakeLists.txt 2011-12-20 22:36:50.545619631 +0100
+@@ -241,9 +241,11 @@ endif()
+
+ if(WITH_BULLET)
+ list(APPEND INC
+- ../../../extern/bullet2/src
+ ../Physics/Bullet
+ )
++ list(APPEND INC_SYS
++ /usr/include/bullet
++ )
+ add_definitions(-DUSE_BULLET)
+ endif()
+
+diff -Npur blender-2.61.orig/source/gameengine/Physics/Bullet/CcdPhysicsEnvironment.cpp blender-2.61/source/gameengine/Physics/Bullet/CcdPhysicsEnvironment.cpp
+--- blender-2.61.orig/source/gameengine/Physics/Bullet/CcdPhysicsEnvironment.cpp 2011-12-20 22:36:19.306620183 +0100
++++ blender-2.61/source/gameengine/Physics/Bullet/CcdPhysicsEnvironment.cpp 2011-12-20 22:37:37.479618806 +0100
+@@ -2804,7 +2804,8 @@ float CcdPhysicsEnvironment::getApplied
+
+ void CcdPhysicsEnvironment::exportFile(const char* filename)
+ {
+- btDefaultSerializer* serializer = new btDefaultSerializer();
++ // Workaround bullet-2.77 api change.
++ btDefaultSerializer* serializer = new btDefaultSerializer(0);
+
+
+ for (int i=0;i<m_dynamicsWorld->getNumCollisionObjects();i++)
+diff -Npur blender-2.61.orig/source/gameengine/Physics/Bullet/CMakeLists.txt blender-2.61/source/gameengine/Physics/Bullet/CMakeLists.txt
+--- blender-2.61.orig/source/gameengine/Physics/Bullet/CMakeLists.txt 2011-12-20 22:36:19.306620183 +0100
++++ blender-2.61/source/gameengine/Physics/Bullet/CMakeLists.txt 2011-12-20 22:36:50.545619631 +0100
+@@ -37,7 +37,6 @@ set(INC
+ ../../../blender/blenkernel
+ ../../../blender/blenlib
+ ../../../blender/makesdna
+- ../../../../extern/bullet2/src
+ ../../../../intern/container
+ ../../../../intern/guardedalloc
+ ../../../../intern/moto/include
+@@ -45,6 +44,7 @@ set(INC
+ )
+
+ set(INC_SYS
++ /usr/include/bullet
+ ${GLEW_INCLUDE_PATH}
+ ${PYTHON_INCLUDE_DIRS}
+ )
diff --git a/media-gfx/blender/files/blender-2.60-colamd.patch b/media-gfx/blender/files/blender-2.60-colamd.patch
new file mode 100644
index 0000000..8afb5cb
--- /dev/null
+++ b/media-gfx/blender/files/blender-2.60-colamd.patch
@@ -0,0 +1,204 @@
+diff -Npur blender-2.61.orig/build_files/scons/config/linux-config.py blender-2.61/build_files/scons/config/linux-config.py
+--- blender-2.61.orig/build_files/scons/config/linux-config.py 2012-01-22 00:59:55.201475928 +0100
++++ blender-2.61/build_files/scons/config/linux-config.py 2012-01-22 01:00:24.211475415 +0100
+@@ -189,6 +189,11 @@ BF_EXPAT = '/usr'
+ BF_EXPAT_LIB = 'expat'
+ BF_EXPAT_LIBPATH = '/usr/lib'
+
++WITH_BF_COLAMD = True
++BF_COLAMD = '#extern/colamd'
++BF_COLAMD_INC = '${BF_COLAMD}/include'
++BF_COLAMD_LIB = 'extern_colamd'
++
+ WITH_BF_JEMALLOC = False
+ WITH_BF_STATICJEMALLOC = False
+ BF_JEMALLOC = '/usr'
+diff -Npur blender-2.61.orig/build_files/scons/tools/Blender.py blender-2.61/build_files/scons/tools/Blender.py
+--- blender-2.61.orig/build_files/scons/tools/Blender.py 2012-01-22 00:59:55.201475928 +0100
++++ blender-2.61/build_files/scons/tools/Blender.py 2012-01-22 01:00:24.193475419 +0100
+@@ -1,4 +1,4 @@
+-#!/usr/bin/env python
++
+
+ """
+ tools.BlenderEnvironment
+@@ -281,6 +281,8 @@ def setup_syslibs(lenv):
+ else:
+ syslibs += Split(lenv['BF_OPENCOLLADA_LIB'])
+ syslibs.append(lenv['BF_EXPAT_LIB'])
++ if lenv['WITH_BF_COLAMD']:
++ syslibs += Split(lenv['BF_COLAMD_LIB'])
+
+ if lenv['WITH_BF_JEMALLOC']:
+ if not lenv['WITH_BF_STATICJEMALLOC']:
+diff -Npur blender-2.61.orig/build_files/scons/tools/btools.py blender-2.61/build_files/scons/tools/btools.py
+--- blender-2.61.orig/build_files/scons/tools/btools.py 2012-01-22 00:59:55.201475928 +0100
++++ blender-2.61/build_files/scons/tools/btools.py 2012-01-22 01:01:11.974474571 +0100
+@@ -125,6 +125,7 @@ def validate_arguments(args, bc):
+ 'WITH_BF_FFTW3', 'BF_FFTW3', 'BF_FFTW3_INC', 'BF_FFTW3_LIB', 'BF_FFTW3_LIBPATH', 'WITH_BF_STATICFFTW3', 'BF_FFTW3_LIB_STATIC',
+ 'WITH_BF_STATICOPENGL', 'BF_OPENGL', 'BF_OPENGL_INC', 'BF_OPENGL_LIB', 'BF_OPENGL_LIBPATH', 'BF_OPENGL_LIB_STATIC',
+ 'WITH_BF_COLLADA', 'BF_COLLADA', 'BF_COLLADA_INC', 'BF_COLLADA_LIB', 'BF_OPENCOLLADA', 'BF_OPENCOLLADA_INC', 'BF_OPENCOLLADA_LIB', 'BF_OPENCOLLADA_LIBPATH', 'BF_PCRE', 'BF_PCRE_LIB', 'BF_PCRE_LIBPATH', 'BF_EXPAT', 'BF_EXPAT_LIB', 'BF_EXPAT_LIBPATH',
++ 'WITH_BF_COLAMD', 'BF_COLAMD', 'BF_COLAMD_INC', 'BF_COLAMD_LIB',
+ 'WITH_BF_PLAYER',
+ 'WITH_BF_NOBLENDER',
+ 'WITH_BF_BINRELOC',
+@@ -447,6 +448,11 @@ def read_opts(env, cfg, args):
+ ('BF_EXPAT_LIB', 'Expat library', ''),
+ ('BF_EXPAT_LIBPATH', 'Expat library path', ''),
+
++ (BoolVariable('WITH_BF_COLAMD', 'Use Colamd if true', True)),
++ ('BF_COLAMD', 'Colamd base dir', ''),
++ ('BF_COLAMD_INC', 'Colamd include path', ''),
++ ('BF_COLAMD_LIB', 'Colamd library', ''),
++
+ (BoolVariable('WITH_BF_JEMALLOC', 'Use jemalloc if true', False)),
+ (BoolVariable('WITH_BF_STATICJEMALLOC', 'Staticly link to jemalloc', False)),
+ ('BF_JEMALLOC', 'jemalloc base path', ''),
+diff -Npur blender-2.61.orig/extern/CMakeLists.txt blender-2.61/extern/CMakeLists.txt
+--- blender-2.61.orig/extern/CMakeLists.txt 2012-01-22 00:59:55.198475928 +0100
++++ blender-2.61/extern/CMakeLists.txt 2012-01-22 01:00:24.193475419 +0100
+@@ -26,8 +26,6 @@
+ # Otherwise we get warnings here that we cant fix in external projects
+ remove_strict_flags()
+
+-add_subdirectory(colamd)
+-
+ if(WITH_MOD_CLOTH_ELTOPO)
+ add_subdirectory(eltopo)
+ endif()
+diff -Npur blender-2.61.orig/extern/libmv/bundle.sh blender-2.61/extern/libmv/bundle.sh
+--- blender-2.61.orig/extern/libmv/bundle.sh 2012-01-22 00:59:55.194475928 +0100
++++ blender-2.61/extern/libmv/bundle.sh 2012-01-22 01:00:24.194475416 +0100
+@@ -118,13 +118,13 @@ set(INC
+ .
+ ./third_party/ssba
+ ./third_party/ldl/Include
+- ../colamd/Include
+ )
+
+ set(INC_SYS
+ /usr/include/eigen3
+ ${PNG_INCLUDE_DIR}
+ ${ZLIB_INCLUDE_DIRS}
++ ${COLAMD_INCULDE_DIRS}
+ )
+
+ set(SRC
+@@ -227,6 +227,7 @@ $src
+ incs = '. /usr/include/eigen3'
+ incs += ' ' + env['BF_PNG_INC']
+ incs += ' ' + env['BF_ZLIB_INC']
++incs += ' ' + env['BF_COLAMD_INC']
+
+ if env['OURPLATFORM'] in ('win32-vc', 'win32-mingw', 'linuxcross', 'win64-vc'):
+ incs += ' ./third_party/glog/src/windows ./third_party/glog/src/windows/glog'
+@@ -257,7 +258,7 @@ else:
+ ccflags_libmv = Split(env['REL_CCFLAGS'])
+ cxxflags_libmv = Split(env['REL_CXXFLAGS'])
+
+-incs += ' ./third_party/ssba ./third_party/ldl/Include ../colamd/Include'
++incs += ' ./third_party/ssba ./third_party/ldl/Include'
+
+ env.BlenderLib ( libname = 'extern_libmv', sources=src, includes=Split(incs), defines=defs, libtype=['extern', 'player'], priority=[20,137], compileflags=cflags_libmv, cc_compileflags=ccflags_libmv, cxx_compileflags=cxxflags_libmv )
+ EOF
+diff -Npur blender-2.61.orig/extern/libmv/CMakeLists.txt blender-2.61/extern/libmv/CMakeLists.txt
+--- blender-2.61.orig/extern/libmv/CMakeLists.txt 2012-01-22 00:59:55.190475928 +0100
++++ blender-2.61/extern/libmv/CMakeLists.txt 2012-01-22 01:00:24.209475415 +0100
+@@ -26,13 +26,13 @@ set(INC
+ .
+ third_party/ssba
+ third_party/ldl/Include
+- ../colamd/Include
+ )
+
+ set(INC_SYS
+ /usr/include/eigen3
+ ${PNG_INCLUDE_DIR}
+ ${ZLIB_INCLUDE_DIRS}
++ ${COLAMD_INCLUDE_DIRS}
+ )
+
+ set(SRC
+diff -Npur blender-2.61.orig/extern/libmv/SConscript blender-2.61/extern/libmv/SConscript
+--- blender-2.61.orig/extern/libmv/SConscript 2012-01-22 00:59:55.190475928 +0100
++++ blender-2.61/extern/libmv/SConscript 2012-01-22 01:00:24.210475415 +0100
+@@ -28,6 +28,7 @@ src += env.Glob('third_party/ssba/Math/*
+ incs = '. /usr/include/eigen3'
+ incs += ' ' + env['BF_PNG_INC']
+ incs += ' ' + env['BF_ZLIB_INC']
++incs += ' ' + env['BF_COLAMD_INC']
+
+ if env['OURPLATFORM'] in ('win32-vc', 'win32-mingw', 'linuxcross', 'win64-vc'):
+ incs += ' ./third_party/glog/src/windows ./third_party/glog/src/windows/glog'
+@@ -57,6 +58,6 @@ else:
+ ccflags_libmv += Split(env['REL_CCFLAGS'])
+ cxxflags_libmv += Split(env['REL_CXXFLAGS'])
+
+-incs += ' ./third_party/ssba ./third_party/ldl/Include ../colamd/Include'
++incs += ' ./third_party/ssba ./third_party/ldl/Include'
+
+ env.BlenderLib ( libname = 'extern_libmv', sources=src, includes=Split(incs), defines=defs, libtype=['extern', 'player'], priority=[20,137], compileflags=cflags_libmv, cc_compileflags=ccflags_libmv, cxx_compileflags=cxxflags_libmv )
+diff -Npur blender-2.61.orig/extern/libmv/third_party/ssba/Math/v3d_optimization.cpp blender-2.61/extern/libmv/third_party/ssba/Math/v3d_optimization.cpp
+--- blender-2.61.orig/extern/libmv/third_party/ssba/Math/v3d_optimization.cpp 2012-01-22 00:59:55.191475928 +0100
++++ blender-2.61/extern/libmv/third_party/ssba/Math/v3d_optimization.cpp 2012-01-22 01:00:24.210475415 +0100
+@@ -21,7 +21,7 @@ with SSBA. If not, see <http://www.gnu.o
+
+ #if defined(V3DLIB_ENABLE_SUITESPARSE)
+ //# include "COLAMD/Include/colamd.h"
+-# include "colamd.h"
++# include <colamd.h>
+ extern "C"
+ {
+ //# include "LDL/Include/ldl.h"
+diff -Npur blender-2.61.orig/extern/SConscript blender-2.61/extern/SConscript
+--- blender-2.61.orig/extern/SConscript 2012-01-22 00:59:55.197475928 +0100
++++ blender-2.61/extern/SConscript 2012-01-22 01:00:24.210475415 +0100
+@@ -2,8 +2,6 @@
+
+ Import('env')
+
+-SConscript(['colamd/SConscript'])
+-
+ if env['WITH_BF_GAMEENGINE']:
+ SConscript(['recastnavigation/SConscript'])
+
+diff -Npur blender-2.61.orig/intern/opennl/CMakeLists.txt blender-2.61/intern/opennl/CMakeLists.txt
+--- blender-2.61.orig/intern/opennl/CMakeLists.txt 2012-01-22 00:59:55.482475922 +0100
++++ blender-2.61/intern/opennl/CMakeLists.txt 2012-01-22 01:00:24.210475415 +0100
+@@ -40,11 +40,10 @@ add_definitions(
+ set(INC
+ extern
+ superlu
+- ../../extern/colamd/Include
+ )
+
+ set(INC_SYS
+-
++ /usr/include
+ )
+
+ set(SRC
+diff -Npur blender-2.61.orig/intern/opennl/SConscript blender-2.61/intern/opennl/SConscript
+--- blender-2.61.orig/intern/opennl/SConscript 2012-01-22 00:59:55.482475922 +0100
++++ blender-2.61/intern/opennl/SConscript 2012-01-22 01:00:24.210475415 +0100
+@@ -3,7 +3,7 @@ Import ('env')
+
+ sources = env.Glob('intern/*.c') + env.Glob('superlu/*.c')
+
+-incs = 'extern superlu ../../extern/colamd/Include'
++incs = 'extern superlu /usr/include'
+
+ if (env['OURPLATFORM'] == 'win32-mingw'):
+ env.BlenderLib ('bf_intern_opennl', sources, Split(incs), [], libtype=['core','intern'], priority=[1,80] )
+diff -Npur blender-2.61.orig/intern/opennl/superlu/get_perm_c.c blender-2.61/intern/opennl/superlu/get_perm_c.c
+--- blender-2.61.orig/intern/opennl/superlu/get_perm_c.c 2012-01-22 00:59:55.482475922 +0100
++++ blender-2.61/intern/opennl/superlu/get_perm_c.c 2012-01-22 01:00:24.210475415 +0100
+@@ -10,7 +10,7 @@
+ */
+
+ #include "ssp_defs.h"
+-#include "colamd.h"
++#include <colamd.h>
+
+ extern int genmmd_(int *, int *, int *, int *, int *, int *, int *,
+ int *, int *, int *, int *, int *);
diff --git a/media-gfx/blender/files/blender-2.60-libav-0.7.patch b/media-gfx/blender/files/blender-2.60-libav-0.7.patch
new file mode 100644
index 0000000..3bae020
--- /dev/null
+++ b/media-gfx/blender/files/blender-2.60-libav-0.7.patch
@@ -0,0 +1,30 @@
+--- 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,8 @@
+ #include <libavcodec/avcodec.h>
+ #include <libavformat/avformat.h>
+ #include <libavformat/avio.h>
++#include <libavutil/mathematics.h>
++#include <libavutil/avstring.h>
+ #include "ffmpeg_compat.h"
+ }
+
+@@ -57,10 +58,15 @@
+ {
+ 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;
++ av_strlcpy(m_formatCtx->filename, filename.c_str(), sizeof(m_formatCtx->filename));
++ 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.60-linux-3.patch b/media-gfx/blender/files/blender-2.60-linux-3.patch
new file mode 100644
index 0000000..6a96b49
--- /dev/null
+++ b/media-gfx/blender/files/blender-2.60-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-2.60a-cmake.patch b/media-gfx/blender/files/blender-2.60a-cmake.patch
new file mode 100644
index 0000000..0355850
--- /dev/null
+++ b/media-gfx/blender/files/blender-2.60a-cmake.patch
@@ -0,0 +1,67 @@
+--- source/creator/CMakeLists.txt.orig 2011-11-11 01:19:03.166796150 +0100
++++ source/creator/CMakeLists.txt 2011-11-11 01:19:48.300795335 +0100
+@@ -745,6 +745,7 @@ set(BLENDER_LINK_LIBS
+ ${BLENDER_LINK_LIBS}
+ bf_windowmanager
+ bf_render
++ bf_render_raytrace
+ )
+
+ if(WITH_MOD_FLUID)
+@@ -795,6 +796,7 @@ endif()
+ bf_editor_datafiles
+
+ bf_render
++ bf_render_raytrace
+ bf_intern_opennl
+ bf_python
+ bf_python_ext
+--- source/blender/render/CMakeLists.txt.orig 2011-11-11 01:19:26.089795736 +0100
++++ source/blender/render/CMakeLists.txt 2011-11-11 01:21:56.243793090 +0100
+@@ -43,6 +43,27 @@ set(INC_SYS
+
+ )
+
++set(SRC_RAYTRACE
++ intern/raytrace/rayobject.cpp
++ intern/raytrace/rayobject_empty.cpp
++ intern/raytrace/rayobject_octree.cpp
++ intern/raytrace/rayobject_raycounter.cpp
++ intern/raytrace/rayobject_svbvh.cpp
++ intern/raytrace/rayobject_blibvh.cpp
++ intern/raytrace/rayobject_instance.cpp
++ intern/raytrace/rayobject_qbvh.cpp
++ intern/raytrace/rayobject_rtbuild.cpp
++ intern/raytrace/rayobject_vbvh.cpp
++
++ intern/raytrace/bvh.h
++ intern/raytrace/rayobject_hint.h
++ intern/raytrace/rayobject_internal.h
++ intern/raytrace/rayobject_rtbuild.h
++ intern/raytrace/reorganize.h
++ intern/raytrace/svbvh.h
++ intern/raytrace/vbvh.h
++)
++
+ set(SRC
+ intern/raytrace/rayobject.cpp
+ intern/raytrace/rayobject_empty.cpp
+@@ -107,13 +128,6 @@ set(SRC
+ intern/include/volumetric.h
+ intern/include/voxeldata.h
+ intern/include/zbuf.h
+- intern/raytrace/bvh.h
+- intern/raytrace/rayobject_hint.h
+- intern/raytrace/rayobject_internal.h
+- intern/raytrace/rayobject_rtbuild.h
+- intern/raytrace/reorganize.h
+- intern/raytrace/svbvh.h
+- intern/raytrace/vbvh.h
+ )
+
+ if(WITH_IMAGE_OPENEXR)
+@@ -142,3 +156,4 @@ if(APPLE)
+ endif()
+
+ blender_add_lib_nolist(bf_render "${SRC}" "${INC}" "${INC_SYS}")
++blender_add_lib_nolist(bf_render_raytrace "${SRC_RAYTRACE}" "${INC}" "${INC_SYS}")
diff --git a/media-gfx/blender/files/blender-2.61-CVE-2009-3850-v3.patch b/media-gfx/blender/files/blender-2.61-CVE-2009-3850-v3.patch
new file mode 100644
index 0000000..48895a8
--- /dev/null
+++ b/media-gfx/blender/files/blender-2.61-CVE-2009-3850-v3.patch
@@ -0,0 +1,146 @@
+diff -Npur blender-2.61.orig/source/blender/blenkernel/intern/blender.c blender-2.61/source/blender/blenkernel/intern/blender.c
+--- blender-2.61.orig/source/blender/blenkernel/intern/blender.c 2011-12-20 20:47:10.884735950 +0100
++++ blender-2.61/source/blender/blenkernel/intern/blender.c 2011-12-20 20:47:58.500735116 +0100
+@@ -144,6 +144,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.61.orig/source/blender/makesrna/intern/rna_userdef.c blender-2.61/source/blender/makesrna/intern/rna_userdef.c
+--- blender-2.61.orig/source/blender/makesrna/intern/rna_userdef.c 2011-12-20 20:47:10.891735952 +0100
++++ blender-2.61/source/blender/makesrna/intern/rna_userdef.c 2011-12-20 20:50:32.755732385 +0100
+@@ -114,9 +114,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)
+@@ -2729,6 +2737,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.61.orig/source/blender/windowmanager/intern/wm_files.c blender-2.61/source/blender/windowmanager/intern/wm_files.c
+--- blender-2.61.orig/source/blender/windowmanager/intern/wm_files.c 2011-12-20 20:47:10.943735949 +0100
++++ blender-2.61/source/blender/windowmanager/intern/wm_files.c 2011-12-20 20:52:16.097730555 +0100
+@@ -286,13 +286,18 @@ 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_init_temporary_dir(U.tempdir);
++
++ /* 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.61.orig/source/blender/windowmanager/intern/wm_operators.c blender-2.61/source/blender/windowmanager/intern/wm_operators.c
+--- blender-2.61.orig/source/blender/windowmanager/intern/wm_operators.c 2011-12-20 20:47:10.943735949 +0100
++++ blender-2.61/source/blender/windowmanager/intern/wm_operators.c 2011-12-20 20:57:09.176725378 +0100
+@@ -1601,12 +1601,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);
+@@ -1618,6 +1619,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";
+@@ -1629,7 +1632,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.61.orig/source/creator/creator.c blender-2.61/source/creator/creator.c
+--- blender-2.61.orig/source/creator/creator.c 2011-12-20 20:47:10.878735951 +0100
++++ blender-2.61/source/creator/creator.c 2011-12-20 20:59:23.778723050 +0100
+@@ -262,6 +262,7 @@ static int print_help(int UNUSED(argc),
+
+ printf("\n");
+
++ BLI_argsPrintArgDoc(ba, "-666");
+ BLI_argsPrintArgDoc(ba, "--enable-autoexec");
+ BLI_argsPrintArgDoc(ba, "--disable-autoexec");
+
+@@ -330,14 +331,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;
+ }
+
+@@ -1042,6 +1043,7 @@ static void setupArguments(bContext *C,
+ # define PY_DISABLE_AUTO ", (compiled as non-standard default)"
+ #endif
+
++ BLI_argsAdd(ba, 1, NULL, "-666", "\n\tEnable automatic python script execution (port from CVE-2009-3850 patch to Blender 2.61)" 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);
+
diff --git a/media-gfx/blender/files/blender-2.61-CVE-2009-3850-v4.patch b/media-gfx/blender/files/blender-2.61-CVE-2009-3850-v4.patch
new file mode 100644
index 0000000..956eb50
--- /dev/null
+++ b/media-gfx/blender/files/blender-2.61-CVE-2009-3850-v4.patch
@@ -0,0 +1,164 @@
+diff -Npur blender-2.61.orig/SConstruct blender-2.61/SConstruct
+--- blender-2.61.orig/SConstruct 2012-01-02 16:57:51.329355164 +0100
++++ blender-2.61/SConstruct 2012-01-02 17:04:36.232349086 +0100
+@@ -346,6 +346,10 @@ if 'blenderplayer' in B.targets:
+ if 'blendernogame' in B.targets:
+ env['WITH_BF_GAMEENGINE'] = False
+
++# build without python autoexec security?
++if env['WITH_PYTHON_SECURITY'] == True:
++ env.Append(CPPFLAGS=['-DWITH_PYTHON_SECURITY'])
++
+ # build without elbeem (fluidsim)?
+ if env['WITH_BF_FLUID'] == 1:
+ env['CPPFLAGS'].append('-DWITH_MOD_FLUID')
+diff -Npur blender-2.61.orig/build_files/scons/tools/btools.py blender-2.61/build_files/scons/tools/btools.py
+--- blender-2.61.orig/build_files/scons/tools/btools.py 2012-01-02 16:56:21.351357062 +0100
++++ blender-2.61/build_files/scons/tools/btools.py 2012-01-02 17:01:37.760350726 +0100
+@@ -96,7 +96,7 @@ def print_arguments(args, bc):
+
+ def validate_arguments(args, bc):
+ opts_list = [
+- 'WITH_BF_PYTHON', 'WITH_BF_PYTHON_SAFETY', 'BF_PYTHON', 'BF_PYTHON_VERSION', 'BF_PYTHON_INC', 'BF_PYTHON_BINARY', 'BF_PYTHON_LIB', 'BF_PYTHON_LIBPATH', 'WITH_BF_STATICPYTHON', 'WITH_OSX_STATICPYTHON', 'BF_PYTHON_LIB_STATIC', 'BF_PYTHON_DLL', 'BF_PYTHON_ABI_FLAGS',
++ 'WITH_BF_PYTHON', 'WITH_BF_PYTHON_SAFETY', 'BF_PYTHON', 'BF_PYTHON_VERSION', 'BF_PYTHON_INC', 'BF_PYTHON_BINARY', 'BF_PYTHON_LIB', 'BF_PYTHON_LIBPATH', 'WITH_BF_STATICPYTHON', 'WITH_OSX_STATICPYTHON', 'BF_PYTHON_LIB_STATIC', 'BF_PYTHON_DLL', 'BF_PYTHON_ABI_FLAGS', 'WITH_PYTHON_SECURITY',
+ 'WITH_BF_OPENAL', 'BF_OPENAL', 'BF_OPENAL_INC', 'BF_OPENAL_LIB', 'BF_OPENAL_LIBPATH', 'WITH_BF_STATICOPENAL', 'BF_OPENAL_LIB_STATIC',
+ 'WITH_BF_SDL', 'BF_SDL', 'BF_SDL_INC', 'BF_SDL_LIB', 'BF_SDL_LIBPATH',
+ 'WITH_BF_JACK', 'BF_JACK', 'BF_JACK_INC', 'BF_JACK_LIB', 'BF_JACK_LIBPATH',
+@@ -256,6 +256,7 @@ def read_opts(env, cfg, args):
+ (BoolVariable('WITH_BF_STATICPYTHON', 'Staticly link to python', False)),
+ (BoolVariable('WITH_OSX_STATICPYTHON', 'Staticly link to python', True)),
+ ('BF_PYTHON_ABI_FLAGS', 'Python ABI flags (suffix in library version: m, mu, etc)', ''),
++ (BoolVariable('WITH_PYTHON_SECURITY', 'Disables execution of scripts within blend files by default (recommend to leave off)', False)),
+
+ (BoolVariable('WITH_BF_FLUID', 'Build with Fluid simulation (Elbeem)', True)),
+ (BoolVariable('WITH_BF_DECIMATE', 'Build with decimate modifier', True)),
+diff -Npur blender-2.61.orig/source/blender/blenkernel/intern/blender.c blender-2.61/source/blender/blenkernel/intern/blender.c
+--- blender-2.61.orig/source/blender/blenkernel/intern/blender.c 2012-01-02 16:57:51.329355164 +0100
++++ blender-2.61/source/blender/blenkernel/intern/blender.c 2012-01-02 16:48:10.700365736 +0100
+@@ -144,6 +144,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.61.orig/source/blender/makesrna/intern/rna_userdef.c blender-2.61/source/blender/makesrna/intern/rna_userdef.c
+--- blender-2.61.orig/source/blender/makesrna/intern/rna_userdef.c 2012-01-02 16:57:51.330355184 +0100
++++ blender-2.61/source/blender/makesrna/intern/rna_userdef.c 2012-01-02 16:48:10.701365735 +0100
+@@ -114,9 +114,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)
+@@ -2729,6 +2737,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.61.orig/source/blender/windowmanager/intern/wm_files.c blender-2.61/source/blender/windowmanager/intern/wm_files.c
+--- blender-2.61.orig/source/blender/windowmanager/intern/wm_files.c 2012-01-02 16:57:51.330355184 +0100
++++ blender-2.61/source/blender/windowmanager/intern/wm_files.c 2012-01-02 16:48:10.702365735 +0100
+@@ -286,13 +286,18 @@ 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_init_temporary_dir(U.tempdir);
++
++ /* 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.61.orig/source/blender/windowmanager/intern/wm_operators.c blender-2.61/source/blender/windowmanager/intern/wm_operators.c
+--- blender-2.61.orig/source/blender/windowmanager/intern/wm_operators.c 2012-01-02 16:57:51.331355194 +0100
++++ blender-2.61/source/blender/windowmanager/intern/wm_operators.c 2012-01-02 16:48:10.703365736 +0100
+@@ -1601,12 +1601,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);
+@@ -1618,6 +1619,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";
+@@ -1629,7 +1632,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.61.orig/source/creator/creator.c blender-2.61/source/creator/creator.c
+--- blender-2.61.orig/source/creator/creator.c 2012-01-02 16:57:51.332355222 +0100
++++ blender-2.61/source/creator/creator.c 2012-01-02 16:48:10.704365737 +0100
+@@ -330,14 +330,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;
+ }
+
diff --git a/media-gfx/blender/files/blender-2.61-collada.patch b/media-gfx/blender/files/blender-2.61-collada.patch
new file mode 100644
index 0000000..980b640
--- /dev/null
+++ b/media-gfx/blender/files/blender-2.61-collada.patch
@@ -0,0 +1,11 @@
+--- source/blender/collada/SConscript 2012-01-16 19:04:02.438027832 +0100
++++ source/blender/collada/SConscript 2012-01-16 19:03:59.787060970 +0100
+@@ -35,7 +35,7 @@
+ if env['OURPLATFORM']=='darwin':
+ incs = '../blenlib ../blenkernel ../windowmanager ../blenloader ../makesdna ../makesrna ../editors/include ../../../intern/guardedalloc [OPENCOLLADA]/COLLADAStreamWriter [OPENCOLLADA]/COLLADABaseUtils [OPENCOLLADA]/COLLADAFramework [OPENCOLLADA]/COLLADASaxFrameworkLoader [OPENCOLLADA]/GeneratedSaxParser '.replace('[OPENCOLLADA]', env['BF_OPENCOLLADA_INC'])
+ else:
+- incs = '../blenlib ../blenkernel ../windowmanager ../makesdna ../blenloader ../makesrna ../editors/include ../../../intern/guardedalloc [OPENCOLLADA]/COLLADAStreamWriter/include [OPENCOLLADA]/COLLADABaseUtils/include [OPENCOLLADA]/COLLADAFramework/include [OPENCOLLADA]/COLLADASaxFrameworkLoader/include [OPENCOLLADA]/GeneratedSaxParser/include '.replace('[OPENCOLLADA]', env['BF_OPENCOLLADA_INC'])
++ incs = '../blenlib ../blenkernel ../windowmanager ../makesdna ../blenloader ../makesrna ../editors/include ../../../intern/guardedalloc [OPENCOLLADA]/COLLADAStreamWriter [OPENCOLLADA]/COLLADABaseUtils [OPENCOLLADA]/COLLADAFramework [OPENCOLLADA]/COLLADASaxFrameworkLoader [OPENCOLLADA]/GeneratedSaxParser '.replace('[OPENCOLLADA]', env['BF_OPENCOLLADA_INC'])
+
+ if env['BF_BUILDINFO']:
+ defs.append('WITH_BUILDINFO')
diff --git a/media-gfx/blender/files/blender-2.61-desktop.patch b/media-gfx/blender/files/blender-2.61-desktop.patch
new file mode 100644
index 0000000..557ba6e
--- /dev/null
+++ b/media-gfx/blender/files/blender-2.61-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.61
+ 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.61 %f
++Icon=blender-2.61
+ Terminal=false
+ Type=Application
+ Categories=Graphics;3DGraphics;
diff --git a/media-gfx/blender/files/blender-2.61-eigen.patch b/media-gfx/blender/files/blender-2.61-eigen.patch
new file mode 100644
index 0000000..bd40ceb
--- /dev/null
+++ b/media-gfx/blender/files/blender-2.61-eigen.patch
@@ -0,0 +1,543 @@
+diff -Npur blender-2.61.orig/extern/libmv/bundle.sh blender-2.61/extern/libmv/bundle.sh
+--- blender-2.61.orig/extern/libmv/bundle.sh 2011-12-20 20:22:31.563762104 +0100
++++ blender-2.61/extern/libmv/bundle.sh 2011-12-20 20:35:09.876748698 +0100
+@@ -116,13 +116,13 @@ cat > CMakeLists.txt << EOF
+
+ set(INC
+ .
+- ../Eigen3
+ ./third_party/ssba
+ ./third_party/ldl/Include
+ ../colamd/Include
+ )
+
+ set(INC_SYS
++ /usr/include/eigen3
+ ${PNG_INCLUDE_DIR}
+ ${ZLIB_INCLUDE_DIRS}
+ )
+@@ -224,7 +224,7 @@ defs.append('GOOGLE_GLOG_DLL_DECL=')
+ src = env.Glob("*.cpp")
+ $src
+
+-incs = '. ../Eigen3'
++incs = '. /usr/include/eigen3'
+ incs += ' ' + env['BF_PNG_INC']
+ incs += ' ' + env['BF_ZLIB_INC']
+
+diff -Npur blender-2.61.orig/extern/libmv/CMakeLists.txt blender-2.61/extern/libmv/CMakeLists.txt
+--- blender-2.61.orig/extern/libmv/CMakeLists.txt 2011-12-20 20:22:31.545762104 +0100
++++ blender-2.61/extern/libmv/CMakeLists.txt 2011-12-20 20:34:30.205749406 +0100
+@@ -24,13 +24,13 @@
+
+ set(INC
+ .
+- ../Eigen3
+ third_party/ssba
+ third_party/ldl/Include
+ ../colamd/Include
+ )
+
+ set(INC_SYS
++ /usr/include/eigen3
+ ${PNG_INCLUDE_DIR}
+ ${ZLIB_INCLUDE_DIRS}
+ )
+diff -Npur blender-2.61.orig/extern/libmv/SConscript blender-2.61/extern/libmv/SConscript
+--- blender-2.61.orig/extern/libmv/SConscript 2011-12-20 20:22:31.545762104 +0100
++++ blender-2.61/extern/libmv/SConscript 2011-12-20 20:31:51.516752243 +0100
+@@ -25,7 +25,7 @@ src += env.Glob('third_party/ldl/Source/
+ src += env.Glob('third_party/ssba/Geometry/*.cpp')
+ src += env.Glob('third_party/ssba/Math/*.cpp')
+
+-incs = '. ../Eigen3'
++incs = '. /usr/include/eigen3'
+ incs += ' ' + env['BF_PNG_INC']
+ incs += ' ' + env['BF_ZLIB_INC']
+
+diff -Npur blender-2.61.orig/intern/itasc/CMakeLists.txt blender-2.61/intern/itasc/CMakeLists.txt
+--- blender-2.61.orig/intern/itasc/CMakeLists.txt 2011-12-20 20:22:32.147762093 +0100
++++ blender-2.61/intern/itasc/CMakeLists.txt 2011-12-20 20:27:46.428756570 +0100
+@@ -24,11 +24,11 @@
+ # ***** END GPL LICENSE BLOCK *****
+
+ set(INC
+- ../../extern/Eigen3
++
+ )
+
+ set(INC_SYS
+-
++ /usr/include/eigen3
+ )
+
+ set(SRC
+@@ -121,201 +121,201 @@ set(SRC
+ kdl/framevel.inl
+
+ # until we have another user...
+- ../../extern/Eigen3/Eigen/src/plugins/MatrixCwiseUnaryOps.h
+- ../../extern/Eigen3/Eigen/src/plugins/CommonCwiseUnaryOps.h
+- ../../extern/Eigen3/Eigen/src/plugins/MatrixCwiseBinaryOps.h
+- ../../extern/Eigen3/Eigen/src/plugins/BlockMethods.h
+- ../../extern/Eigen3/Eigen/src/plugins/ArrayCwiseUnaryOps.h
+- ../../extern/Eigen3/Eigen/src/plugins/ArrayCwiseBinaryOps.h
+- ../../extern/Eigen3/Eigen/src/plugins/CommonCwiseBinaryOps.h
+- ../../extern/Eigen3/Eigen/src/misc/Kernel.h
+- ../../extern/Eigen3/Eigen/src/misc/Image.h
+- ../../extern/Eigen3/Eigen/src/misc/Solve.h
+- ../../extern/Eigen3/Eigen/src/QR/HouseholderQR.h
+- ../../extern/Eigen3/Eigen/src/QR/ColPivHouseholderQR.h
+- ../../extern/Eigen3/Eigen/src/QR/FullPivHouseholderQR.h
+- ../../extern/Eigen3/Eigen/src/StlSupport/details.h
+- ../../extern/Eigen3/Eigen/src/StlSupport/StdList.h
+- ../../extern/Eigen3/Eigen/src/StlSupport/StdDeque.h
+- ../../extern/Eigen3/Eigen/src/StlSupport/StdVector.h
+- ../../extern/Eigen3/Eigen/src/SVD/UpperBidiagonalization.h
+- ../../extern/Eigen3/Eigen/src/SVD/JacobiSVD.h
+- ../../extern/Eigen3/Eigen/src/Eigenvalues/ComplexEigenSolver.h
+- ../../extern/Eigen3/Eigen/src/Eigenvalues/ComplexSchur.h
+- ../../extern/Eigen3/Eigen/src/Eigenvalues/HessenbergDecomposition.h
+- ../../extern/Eigen3/Eigen/src/Eigenvalues/Tridiagonalization.h
+- ../../extern/Eigen3/Eigen/src/Eigenvalues/GeneralizedSelfAdjointEigenSolver.h
+- ../../extern/Eigen3/Eigen/src/Eigenvalues/SelfAdjointEigenSolver.h
+- ../../extern/Eigen3/Eigen/src/Eigenvalues/RealSchur.h
+- ../../extern/Eigen3/Eigen/src/Eigenvalues/EigenvaluesCommon.h
+- ../../extern/Eigen3/Eigen/src/Eigenvalues/MatrixBaseEigenvalues.h
+- ../../extern/Eigen3/Eigen/src/Eigenvalues/EigenSolver.h
+- ../../extern/Eigen3/Eigen/src/Jacobi/Jacobi.h
+- ../../extern/Eigen3/Eigen/src/Householder/Householder.h
+- ../../extern/Eigen3/Eigen/src/Householder/BlockHouseholder.h
+- ../../extern/Eigen3/Eigen/src/Householder/HouseholderSequence.h
+- ../../extern/Eigen3/Eigen/src/Geometry/RotationBase.h
+- ../../extern/Eigen3/Eigen/src/Geometry/Rotation2D.h
+- ../../extern/Eigen3/Eigen/src/Geometry/Homogeneous.h
+- ../../extern/Eigen3/Eigen/src/Geometry/Hyperplane.h
+- ../../extern/Eigen3/Eigen/src/Geometry/EulerAngles.h
+- ../../extern/Eigen3/Eigen/src/Geometry/arch/Geometry_SSE.h
+- ../../extern/Eigen3/Eigen/src/Geometry/ParametrizedLine.h
+- ../../extern/Eigen3/Eigen/src/Geometry/OrthoMethods.h
+- ../../extern/Eigen3/Eigen/src/Geometry/AngleAxis.h
+- ../../extern/Eigen3/Eigen/src/Geometry/Umeyama.h
+- ../../extern/Eigen3/Eigen/src/Geometry/Scaling.h
+- ../../extern/Eigen3/Eigen/src/Geometry/Translation.h
+- ../../extern/Eigen3/Eigen/src/Geometry/AlignedBox.h
+- ../../extern/Eigen3/Eigen/src/Geometry/Transform.h
+- ../../extern/Eigen3/Eigen/src/Geometry/Quaternion.h
+- ../../extern/Eigen3/Eigen/src/LU/PartialPivLU.h
+- ../../extern/Eigen3/Eigen/src/LU/Determinant.h
+- ../../extern/Eigen3/Eigen/src/LU/arch/Inverse_SSE.h
+- ../../extern/Eigen3/Eigen/src/LU/FullPivLU.h
+- ../../extern/Eigen3/Eigen/src/LU/Inverse.h
+- ../../extern/Eigen3/Eigen/src/Sparse/SparseMatrixBase.h
+- ../../extern/Eigen3/Eigen/src/Sparse/SparseSelfAdjointView.h
+- ../../extern/Eigen3/Eigen/src/Sparse/SparseVector.h
+- ../../extern/Eigen3/Eigen/src/Sparse/SparseDiagonalProduct.h
+- ../../extern/Eigen3/Eigen/src/Sparse/TriangularSolver.h
+- ../../extern/Eigen3/Eigen/src/Sparse/AmbiVector.h
+- ../../extern/Eigen3/Eigen/src/Sparse/SparseDenseProduct.h
+- ../../extern/Eigen3/Eigen/src/Sparse/SparseBlock.h
+- ../../extern/Eigen3/Eigen/src/Sparse/SparseTriangularView.h
+- ../../extern/Eigen3/Eigen/src/Sparse/SparseCwiseBinaryOp.h
+- ../../extern/Eigen3/Eigen/src/Sparse/CoreIterators.h
+- ../../extern/Eigen3/Eigen/src/Sparse/SparseMatrix.h
+- ../../extern/Eigen3/Eigen/src/Sparse/SparseAssign.h
+- ../../extern/Eigen3/Eigen/src/Sparse/SparseSparseProduct.h
+- ../../extern/Eigen3/Eigen/src/Sparse/SparseDot.h
+- ../../extern/Eigen3/Eigen/src/Sparse/DynamicSparseMatrix.h
+- ../../extern/Eigen3/Eigen/src/Sparse/SparseRedux.h
+- ../../extern/Eigen3/Eigen/src/Sparse/SparseFuzzy.h
+- ../../extern/Eigen3/Eigen/src/Sparse/SparseCwiseUnaryOp.h
+- ../../extern/Eigen3/Eigen/src/Sparse/SparseView.h
+- ../../extern/Eigen3/Eigen/src/Sparse/MappedSparseMatrix.h
+- ../../extern/Eigen3/Eigen/src/Sparse/SparseUtil.h
+- ../../extern/Eigen3/Eigen/src/Sparse/SparseTranspose.h
+- ../../extern/Eigen3/Eigen/src/Sparse/SparseProduct.h
+- ../../extern/Eigen3/Eigen/src/Sparse/CompressedStorage.h
+- ../../extern/Eigen3/Eigen/src/Eigen2Support/Cwise.h
+- ../../extern/Eigen3/Eigen/src/Eigen2Support/TriangularSolver.h
+- ../../extern/Eigen3/Eigen/src/Eigen2Support/QR.h
+- ../../extern/Eigen3/Eigen/src/Eigen2Support/Lazy.h
+- ../../extern/Eigen3/Eigen/src/Eigen2Support/Memory.h
+- ../../extern/Eigen3/Eigen/src/Eigen2Support/SVD.h
+- ../../extern/Eigen3/Eigen/src/Eigen2Support/CwiseOperators.h
+- ../../extern/Eigen3/Eigen/src/Eigen2Support/VectorBlock.h
+- ../../extern/Eigen3/Eigen/src/Eigen2Support/Meta.h
+- ../../extern/Eigen3/Eigen/src/Eigen2Support/Macros.h
+- ../../extern/Eigen3/Eigen/src/Eigen2Support/LeastSquares.h
+- ../../extern/Eigen3/Eigen/src/Eigen2Support/LU.h
+- ../../extern/Eigen3/Eigen/src/Eigen2Support/Block.h
+- ../../extern/Eigen3/Eigen/src/Eigen2Support/Geometry/RotationBase.h
+- ../../extern/Eigen3/Eigen/src/Eigen2Support/Geometry/Rotation2D.h
+- ../../extern/Eigen3/Eigen/src/Eigen2Support/Geometry/Hyperplane.h
+- ../../extern/Eigen3/Eigen/src/Eigen2Support/Geometry/ParametrizedLine.h
+- ../../extern/Eigen3/Eigen/src/Eigen2Support/Geometry/AngleAxis.h
+- ../../extern/Eigen3/Eigen/src/Eigen2Support/Geometry/Scaling.h
+- ../../extern/Eigen3/Eigen/src/Eigen2Support/Geometry/All.h
+- ../../extern/Eigen3/Eigen/src/Eigen2Support/Geometry/Translation.h
+- ../../extern/Eigen3/Eigen/src/Eigen2Support/Geometry/AlignedBox.h
+- ../../extern/Eigen3/Eigen/src/Eigen2Support/Geometry/Transform.h
+- ../../extern/Eigen3/Eigen/src/Eigen2Support/Geometry/Quaternion.h
+- ../../extern/Eigen3/Eigen/src/Eigen2Support/Minor.h
+- ../../extern/Eigen3/Eigen/src/Eigen2Support/MathFunctions.h
+- ../../extern/Eigen3/Eigen/src/Core/SelfAdjointView.h
+- ../../extern/Eigen3/Eigen/src/Core/MatrixBase.h
+- ../../extern/Eigen3/Eigen/src/Core/Swap.h
+- ../../extern/Eigen3/Eigen/src/Core/DenseCoeffsBase.h
+- ../../extern/Eigen3/Eigen/src/Core/DenseBase.h
+- ../../extern/Eigen3/Eigen/src/Core/GlobalFunctions.h
+- ../../extern/Eigen3/Eigen/src/Core/ProductBase.h
+- ../../extern/Eigen3/Eigen/src/Core/CwiseBinaryOp.h
+- ../../extern/Eigen3/Eigen/src/Core/Stride.h
+- ../../extern/Eigen3/Eigen/src/Core/Matrix.h
+- ../../extern/Eigen3/Eigen/src/Core/Visitor.h
+- ../../extern/Eigen3/Eigen/src/Core/Array.h
+- ../../extern/Eigen3/Eigen/src/Core/ReturnByValue.h
+- ../../extern/Eigen3/Eigen/src/Core/SelfCwiseBinaryOp.h
+- ../../extern/Eigen3/Eigen/src/Core/EigenBase.h
+- ../../extern/Eigen3/Eigen/src/Core/Random.h
+- ../../extern/Eigen3/Eigen/src/Core/Redux.h
+- ../../extern/Eigen3/Eigen/src/Core/arch/Default/Settings.h
+- ../../extern/Eigen3/Eigen/src/Core/arch/AltiVec/PacketMath.h
+- ../../extern/Eigen3/Eigen/src/Core/arch/AltiVec/Complex.h
+- ../../extern/Eigen3/Eigen/src/Core/arch/NEON/PacketMath.h
+- ../../extern/Eigen3/Eigen/src/Core/arch/NEON/Complex.h
+- ../../extern/Eigen3/Eigen/src/Core/arch/SSE/PacketMath.h
+- ../../extern/Eigen3/Eigen/src/Core/arch/SSE/Complex.h
+- ../../extern/Eigen3/Eigen/src/Core/arch/SSE/MathFunctions.h
+- ../../extern/Eigen3/Eigen/src/Core/BooleanRedux.h
+- ../../extern/Eigen3/Eigen/src/Core/util/ReenableStupidWarnings.h
+- ../../extern/Eigen3/Eigen/src/Core/util/BlasUtil.h
+- ../../extern/Eigen3/Eigen/src/Core/util/Memory.h
+- ../../extern/Eigen3/Eigen/src/Core/util/Meta.h
+- ../../extern/Eigen3/Eigen/src/Core/util/Constants.h
+- ../../extern/Eigen3/Eigen/src/Core/util/Macros.h
+- ../../extern/Eigen3/Eigen/src/Core/util/ForwardDeclarations.h
+- ../../extern/Eigen3/Eigen/src/Core/util/StaticAssert.h
+- ../../extern/Eigen3/Eigen/src/Core/util/DisableStupidWarnings.h
+- ../../extern/Eigen3/Eigen/src/Core/util/XprHelper.h
+- ../../extern/Eigen3/Eigen/src/Core/VectorBlock.h
+- ../../extern/Eigen3/Eigen/src/Core/Transpositions.h
+- ../../extern/Eigen3/Eigen/src/Core/Select.h
+- ../../extern/Eigen3/Eigen/src/Core/BandMatrix.h
+- ../../extern/Eigen3/Eigen/src/Core/CwiseUnaryView.h
+- ../../extern/Eigen3/Eigen/src/Core/Dot.h
+- ../../extern/Eigen3/Eigen/src/Core/GenericPacketMath.h
+- ../../extern/Eigen3/Eigen/src/Core/Product.h
+- ../../extern/Eigen3/Eigen/src/Core/Transpose.h
+- ../../extern/Eigen3/Eigen/src/Core/Block.h
+- ../../extern/Eigen3/Eigen/src/Core/ArrayWrapper.h
+- ../../extern/Eigen3/Eigen/src/Core/MapBase.h
+- ../../extern/Eigen3/Eigen/src/Core/NoAlias.h
+- ../../extern/Eigen3/Eigen/src/Core/ForceAlignedAccess.h
+- ../../extern/Eigen3/Eigen/src/Core/PlainObjectBase.h
+- ../../extern/Eigen3/Eigen/src/Core/IO.h
+- ../../extern/Eigen3/Eigen/src/Core/DiagonalMatrix.h
+- ../../extern/Eigen3/Eigen/src/Core/CwiseUnaryOp.h
+- ../../extern/Eigen3/Eigen/src/Core/Reverse.h
+- ../../extern/Eigen3/Eigen/src/Core/Fuzzy.h
+- ../../extern/Eigen3/Eigen/src/Core/DenseStorage.h
+- ../../extern/Eigen3/Eigen/src/Core/StableNorm.h
+- ../../extern/Eigen3/Eigen/src/Core/NumTraits.h
+- ../../extern/Eigen3/Eigen/src/Core/Map.h
+- ../../extern/Eigen3/Eigen/src/Core/Functors.h
+- ../../extern/Eigen3/Eigen/src/Core/PermutationMatrix.h
+- ../../extern/Eigen3/Eigen/src/Core/ArrayBase.h
+- ../../extern/Eigen3/Eigen/src/Core/CwiseNullaryOp.h
+- ../../extern/Eigen3/Eigen/src/Core/SolveTriangular.h
+- ../../extern/Eigen3/Eigen/src/Core/NestByValue.h
+- ../../extern/Eigen3/Eigen/src/Core/DiagonalProduct.h
+- ../../extern/Eigen3/Eigen/src/Core/CommaInitializer.h
+- ../../extern/Eigen3/Eigen/src/Core/MathFunctions.h
+- ../../extern/Eigen3/Eigen/src/Core/Diagonal.h
+- ../../extern/Eigen3/Eigen/src/Core/Replicate.h
+- ../../extern/Eigen3/Eigen/src/Core/products/TriangularMatrixMatrix.h
+- ../../extern/Eigen3/Eigen/src/Core/products/SelfadjointProduct.h
+- ../../extern/Eigen3/Eigen/src/Core/products/GeneralMatrixVector.h
+- ../../extern/Eigen3/Eigen/src/Core/products/CoeffBasedProduct.h
+- ../../extern/Eigen3/Eigen/src/Core/products/SelfadjointMatrixVector.h
+- ../../extern/Eigen3/Eigen/src/Core/products/SelfadjointRank2Update.h
+- ../../extern/Eigen3/Eigen/src/Core/products/GeneralMatrixMatrixTriangular.h
+- ../../extern/Eigen3/Eigen/src/Core/products/GeneralMatrixMatrix.h
+- ../../extern/Eigen3/Eigen/src/Core/products/SelfadjointMatrixMatrix.h
+- ../../extern/Eigen3/Eigen/src/Core/products/Parallelizer.h
+- ../../extern/Eigen3/Eigen/src/Core/products/TriangularSolverMatrix.h
+- ../../extern/Eigen3/Eigen/src/Core/products/TriangularSolverVector.h
+- ../../extern/Eigen3/Eigen/src/Core/products/TriangularMatrixVector.h
+- ../../extern/Eigen3/Eigen/src/Core/products/GeneralBlockPanelKernel.h
+- ../../extern/Eigen3/Eigen/src/Core/TriangularMatrix.h
+- ../../extern/Eigen3/Eigen/src/Core/VectorwiseOp.h
+- ../../extern/Eigen3/Eigen/src/Core/Assign.h
+- ../../extern/Eigen3/Eigen/src/Core/Flagged.h
+- ../../extern/Eigen3/Eigen/src/Cholesky/LDLT.h
+- ../../extern/Eigen3/Eigen/src/Cholesky/LLT.h
++ /usr/include/eigen3/Eigen/src/plugins/MatrixCwiseUnaryOps.h
++ /usr/include/eigen3/Eigen/src/plugins/CommonCwiseUnaryOps.h
++ /usr/include/eigen3/Eigen/src/plugins/MatrixCwiseBinaryOps.h
++ /usr/include/eigen3/Eigen/src/plugins/BlockMethods.h
++ /usr/include/eigen3/Eigen/src/plugins/ArrayCwiseUnaryOps.h
++ /usr/include/eigen3/Eigen/src/plugins/ArrayCwiseBinaryOps.h
++ /usr/include/eigen3/Eigen/src/plugins/CommonCwiseBinaryOps.h
++ /usr/include/eigen3/Eigen/src/misc/Kernel.h
++ /usr/include/eigen3/Eigen/src/misc/Image.h
++ /usr/include/eigen3/Eigen/src/misc/Solve.h
++ /usr/include/eigen3/Eigen/src/QR/HouseholderQR.h
++ /usr/include/eigen3/Eigen/src/QR/ColPivHouseholderQR.h
++ /usr/include/eigen3/Eigen/src/QR/FullPivHouseholderQR.h
++ /usr/include/eigen3/Eigen/src/StlSupport/details.h
++ /usr/include/eigen3/Eigen/src/StlSupport/StdList.h
++ /usr/include/eigen3/Eigen/src/StlSupport/StdDeque.h
++ /usr/include/eigen3/Eigen/src/StlSupport/StdVector.h
++ /usr/include/eigen3/Eigen/src/SVD/UpperBidiagonalization.h
++ /usr/include/eigen3/Eigen/src/SVD/JacobiSVD.h
++ /usr/include/eigen3/Eigen/src/Eigenvalues/ComplexEigenSolver.h
++ /usr/include/eigen3/Eigen/src/Eigenvalues/ComplexSchur.h
++ /usr/include/eigen3/Eigen/src/Eigenvalues/HessenbergDecomposition.h
++ /usr/include/eigen3/Eigen/src/Eigenvalues/Tridiagonalization.h
++ /usr/include/eigen3/Eigen/src/Eigenvalues/GeneralizedSelfAdjointEigenSolver.h
++ /usr/include/eigen3/Eigen/src/Eigenvalues/SelfAdjointEigenSolver.h
++ /usr/include/eigen3/Eigen/src/Eigenvalues/RealSchur.h
++ /usr/include/eigen3/Eigen/src/Eigenvalues/EigenvaluesCommon.h
++ /usr/include/eigen3/Eigen/src/Eigenvalues/MatrixBaseEigenvalues.h
++ /usr/include/eigen3/Eigen/src/Eigenvalues/EigenSolver.h
++ /usr/include/eigen3/Eigen/src/Jacobi/Jacobi.h
++ /usr/include/eigen3/Eigen/src/Householder/Householder.h
++ /usr/include/eigen3/Eigen/src/Householder/BlockHouseholder.h
++ /usr/include/eigen3/Eigen/src/Householder/HouseholderSequence.h
++ /usr/include/eigen3/Eigen/src/Geometry/RotationBase.h
++ /usr/include/eigen3/Eigen/src/Geometry/Rotation2D.h
++ /usr/include/eigen3/Eigen/src/Geometry/Homogeneous.h
++ /usr/include/eigen3/Eigen/src/Geometry/Hyperplane.h
++ /usr/include/eigen3/Eigen/src/Geometry/EulerAngles.h
++ /usr/include/eigen3/Eigen/src/Geometry/arch/Geometry_SSE.h
++ /usr/include/eigen3/Eigen/src/Geometry/ParametrizedLine.h
++ /usr/include/eigen3/Eigen/src/Geometry/OrthoMethods.h
++ /usr/include/eigen3/Eigen/src/Geometry/AngleAxis.h
++ /usr/include/eigen3/Eigen/src/Geometry/Umeyama.h
++ /usr/include/eigen3/Eigen/src/Geometry/Scaling.h
++ /usr/include/eigen3/Eigen/src/Geometry/Translation.h
++ /usr/include/eigen3/Eigen/src/Geometry/AlignedBox.h
++ /usr/include/eigen3/Eigen/src/Geometry/Transform.h
++ /usr/include/eigen3/Eigen/src/Geometry/Quaternion.h
++ /usr/include/eigen3/Eigen/src/LU/PartialPivLU.h
++ /usr/include/eigen3/Eigen/src/LU/Determinant.h
++ /usr/include/eigen3/Eigen/src/LU/arch/Inverse_SSE.h
++ /usr/include/eigen3/Eigen/src/LU/FullPivLU.h
++ /usr/include/eigen3/Eigen/src/LU/Inverse.h
++ /usr/include/eigen3/Eigen/src/Sparse/SparseMatrixBase.h
++ /usr/include/eigen3/Eigen/src/Sparse/SparseSelfAdjointView.h
++ /usr/include/eigen3/Eigen/src/Sparse/SparseVector.h
++ /usr/include/eigen3/Eigen/src/Sparse/SparseDiagonalProduct.h
++ /usr/include/eigen3/Eigen/src/Sparse/TriangularSolver.h
++ /usr/include/eigen3/Eigen/src/Sparse/AmbiVector.h
++ /usr/include/eigen3/Eigen/src/Sparse/SparseDenseProduct.h
++ /usr/include/eigen3/Eigen/src/Sparse/SparseBlock.h
++ /usr/include/eigen3/Eigen/src/Sparse/SparseTriangularView.h
++ /usr/include/eigen3/Eigen/src/Sparse/SparseCwiseBinaryOp.h
++ /usr/include/eigen3/Eigen/src/Sparse/CoreIterators.h
++ /usr/include/eigen3/Eigen/src/Sparse/SparseMatrix.h
++ /usr/include/eigen3/Eigen/src/Sparse/SparseAssign.h
++ /usr/include/eigen3/Eigen/src/Sparse/SparseSparseProduct.h
++ /usr/include/eigen3/Eigen/src/Sparse/SparseDot.h
++ /usr/include/eigen3/Eigen/src/Sparse/DynamicSparseMatrix.h
++ /usr/include/eigen3/Eigen/src/Sparse/SparseRedux.h
++ /usr/include/eigen3/Eigen/src/Sparse/SparseFuzzy.h
++ /usr/include/eigen3/Eigen/src/Sparse/SparseCwiseUnaryOp.h
++ /usr/include/eigen3/Eigen/src/Sparse/SparseView.h
++ /usr/include/eigen3/Eigen/src/Sparse/MappedSparseMatrix.h
++ /usr/include/eigen3/Eigen/src/Sparse/SparseUtil.h
++ /usr/include/eigen3/Eigen/src/Sparse/SparseTranspose.h
++ /usr/include/eigen3/Eigen/src/Sparse/SparseProduct.h
++ /usr/include/eigen3/Eigen/src/Sparse/CompressedStorage.h
++ /usr/include/eigen3/Eigen/src/Eigen2Support/Cwise.h
++ /usr/include/eigen3/Eigen/src/Eigen2Support/TriangularSolver.h
++ /usr/include/eigen3/Eigen/src/Eigen2Support/QR.h
++ /usr/include/eigen3/Eigen/src/Eigen2Support/Lazy.h
++ /usr/include/eigen3/Eigen/src/Eigen2Support/Memory.h
++ /usr/include/eigen3/Eigen/src/Eigen2Support/SVD.h
++ /usr/include/eigen3/Eigen/src/Eigen2Support/CwiseOperators.h
++ /usr/include/eigen3/Eigen/src/Eigen2Support/VectorBlock.h
++ /usr/include/eigen3/Eigen/src/Eigen2Support/Meta.h
++ /usr/include/eigen3/Eigen/src/Eigen2Support/Macros.h
++ /usr/include/eigen3/Eigen/src/Eigen2Support/LeastSquares.h
++ /usr/include/eigen3/Eigen/src/Eigen2Support/LU.h
++ /usr/include/eigen3/Eigen/src/Eigen2Support/Block.h
++ /usr/include/eigen3/Eigen/src/Eigen2Support/Geometry/RotationBase.h
++ /usr/include/eigen3/Eigen/src/Eigen2Support/Geometry/Rotation2D.h
++ /usr/include/eigen3/Eigen/src/Eigen2Support/Geometry/Hyperplane.h
++ /usr/include/eigen3/Eigen/src/Eigen2Support/Geometry/ParametrizedLine.h
++ /usr/include/eigen3/Eigen/src/Eigen2Support/Geometry/AngleAxis.h
++ /usr/include/eigen3/Eigen/src/Eigen2Support/Geometry/Scaling.h
++ /usr/include/eigen3/Eigen/src/Eigen2Support/Geometry/All.h
++ /usr/include/eigen3/Eigen/src/Eigen2Support/Geometry/Translation.h
++ /usr/include/eigen3/Eigen/src/Eigen2Support/Geometry/AlignedBox.h
++ /usr/include/eigen3/Eigen/src/Eigen2Support/Geometry/Transform.h
++ /usr/include/eigen3/Eigen/src/Eigen2Support/Geometry/Quaternion.h
++ /usr/include/eigen3/Eigen/src/Eigen2Support/Minor.h
++ /usr/include/eigen3/Eigen/src/Eigen2Support/MathFunctions.h
++ /usr/include/eigen3/Eigen/src/Core/SelfAdjointView.h
++ /usr/include/eigen3/Eigen/src/Core/MatrixBase.h
++ /usr/include/eigen3/Eigen/src/Core/Swap.h
++ /usr/include/eigen3/Eigen/src/Core/DenseCoeffsBase.h
++ /usr/include/eigen3/Eigen/src/Core/DenseBase.h
++ /usr/include/eigen3/Eigen/src/Core/GlobalFunctions.h
++ /usr/include/eigen3/Eigen/src/Core/ProductBase.h
++ /usr/include/eigen3/Eigen/src/Core/CwiseBinaryOp.h
++ /usr/include/eigen3/Eigen/src/Core/Stride.h
++ /usr/include/eigen3/Eigen/src/Core/Matrix.h
++ /usr/include/eigen3/Eigen/src/Core/Visitor.h
++ /usr/include/eigen3/Eigen/src/Core/Array.h
++ /usr/include/eigen3/Eigen/src/Core/ReturnByValue.h
++ /usr/include/eigen3/Eigen/src/Core/SelfCwiseBinaryOp.h
++ /usr/include/eigen3/Eigen/src/Core/EigenBase.h
++ /usr/include/eigen3/Eigen/src/Core/Random.h
++ /usr/include/eigen3/Eigen/src/Core/Redux.h
++ /usr/include/eigen3/Eigen/src/Core/arch/Default/Settings.h
++ /usr/include/eigen3/Eigen/src/Core/arch/AltiVec/PacketMath.h
++ /usr/include/eigen3/Eigen/src/Core/arch/AltiVec/Complex.h
++ /usr/include/eigen3/Eigen/src/Core/arch/NEON/PacketMath.h
++ /usr/include/eigen3/Eigen/src/Core/arch/NEON/Complex.h
++ /usr/include/eigen3/Eigen/src/Core/arch/SSE/PacketMath.h
++ /usr/include/eigen3/Eigen/src/Core/arch/SSE/Complex.h
++ /usr/include/eigen3/Eigen/src/Core/arch/SSE/MathFunctions.h
++ /usr/include/eigen3/Eigen/src/Core/BooleanRedux.h
++ /usr/include/eigen3/Eigen/src/Core/util/ReenableStupidWarnings.h
++ /usr/include/eigen3/Eigen/src/Core/util/BlasUtil.h
++ /usr/include/eigen3/Eigen/src/Core/util/Memory.h
++ /usr/include/eigen3/Eigen/src/Core/util/Meta.h
++ /usr/include/eigen3/Eigen/src/Core/util/Constants.h
++ /usr/include/eigen3/Eigen/src/Core/util/Macros.h
++ /usr/include/eigen3/Eigen/src/Core/util/ForwardDeclarations.h
++ /usr/include/eigen3/Eigen/src/Core/util/StaticAssert.h
++ /usr/include/eigen3/Eigen/src/Core/util/DisableStupidWarnings.h
++ /usr/include/eigen3/Eigen/src/Core/util/XprHelper.h
++ /usr/include/eigen3/Eigen/src/Core/VectorBlock.h
++ /usr/include/eigen3/Eigen/src/Core/Transpositions.h
++ /usr/include/eigen3/Eigen/src/Core/Select.h
++ /usr/include/eigen3/Eigen/src/Core/BandMatrix.h
++ /usr/include/eigen3/Eigen/src/Core/CwiseUnaryView.h
++ /usr/include/eigen3/Eigen/src/Core/Dot.h
++ /usr/include/eigen3/Eigen/src/Core/GenericPacketMath.h
++ /usr/include/eigen3/Eigen/src/Core/Product.h
++ /usr/include/eigen3/Eigen/src/Core/Transpose.h
++ /usr/include/eigen3/Eigen/src/Core/Block.h
++ /usr/include/eigen3/Eigen/src/Core/ArrayWrapper.h
++ /usr/include/eigen3/Eigen/src/Core/MapBase.h
++ /usr/include/eigen3/Eigen/src/Core/NoAlias.h
++ /usr/include/eigen3/Eigen/src/Core/ForceAlignedAccess.h
++ /usr/include/eigen3/Eigen/src/Core/PlainObjectBase.h
++ /usr/include/eigen3/Eigen/src/Core/IO.h
++ /usr/include/eigen3/Eigen/src/Core/DiagonalMatrix.h
++ /usr/include/eigen3/Eigen/src/Core/CwiseUnaryOp.h
++ /usr/include/eigen3/Eigen/src/Core/Reverse.h
++ /usr/include/eigen3/Eigen/src/Core/Fuzzy.h
++ /usr/include/eigen3/Eigen/src/Core/DenseStorage.h
++ /usr/include/eigen3/Eigen/src/Core/StableNorm.h
++ /usr/include/eigen3/Eigen/src/Core/NumTraits.h
++ /usr/include/eigen3/Eigen/src/Core/Map.h
++ /usr/include/eigen3/Eigen/src/Core/Functors.h
++ /usr/include/eigen3/Eigen/src/Core/PermutationMatrix.h
++ /usr/include/eigen3/Eigen/src/Core/ArrayBase.h
++ /usr/include/eigen3/Eigen/src/Core/CwiseNullaryOp.h
++ /usr/include/eigen3/Eigen/src/Core/SolveTriangular.h
++ /usr/include/eigen3/Eigen/src/Core/NestByValue.h
++ /usr/include/eigen3/Eigen/src/Core/DiagonalProduct.h
++ /usr/include/eigen3/Eigen/src/Core/CommaInitializer.h
++ /usr/include/eigen3/Eigen/src/Core/MathFunctions.h
++ /usr/include/eigen3/Eigen/src/Core/Diagonal.h
++ /usr/include/eigen3/Eigen/src/Core/Replicate.h
++ /usr/include/eigen3/Eigen/src/Core/products/TriangularMatrixMatrix.h
++ /usr/include/eigen3/Eigen/src/Core/products/SelfadjointProduct.h
++ /usr/include/eigen3/Eigen/src/Core/products/GeneralMatrixVector.h
++ /usr/include/eigen3/Eigen/src/Core/products/CoeffBasedProduct.h
++ /usr/include/eigen3/Eigen/src/Core/products/SelfadjointMatrixVector.h
++ /usr/include/eigen3/Eigen/src/Core/products/SelfadjointRank2Update.h
++ /usr/include/eigen3/Eigen/src/Core/products/GeneralMatrixMatrixTriangular.h
++ /usr/include/eigen3/Eigen/src/Core/products/GeneralMatrixMatrix.h
++ /usr/include/eigen3/Eigen/src/Core/products/SelfadjointMatrixMatrix.h
++ /usr/include/eigen3/Eigen/src/Core/products/Parallelizer.h
++ /usr/include/eigen3/Eigen/src/Core/products/TriangularSolverMatrix.h
++ /usr/include/eigen3/Eigen/src/Core/products/TriangularSolverVector.h
++ /usr/include/eigen3/Eigen/src/Core/products/TriangularMatrixVector.h
++ /usr/include/eigen3/Eigen/src/Core/products/GeneralBlockPanelKernel.h
++ /usr/include/eigen3/Eigen/src/Core/TriangularMatrix.h
++ /usr/include/eigen3/Eigen/src/Core/VectorwiseOp.h
++ /usr/include/eigen3/Eigen/src/Core/Assign.h
++ /usr/include/eigen3/Eigen/src/Core/Flagged.h
++ /usr/include/eigen3/Eigen/src/Cholesky/LDLT.h
++ /usr/include/eigen3/Eigen/src/Cholesky/LLT.h
+ )
+
+ if(WIN32)
+diff -Npur blender-2.61.orig/intern/itasc/SConscript blender-2.61/intern/itasc/SConscript
+--- blender-2.61.orig/intern/itasc/SConscript 2011-12-20 20:22:32.147762093 +0100
++++ blender-2.61/intern/itasc/SConscript 2011-12-20 20:23:36.948760947 +0100
+@@ -5,7 +5,7 @@ sources = env.Glob('*.cpp')
+ sources += env.Glob('kdl/*.cpp')
+ sources += env.Glob('kdl/utilities/*.cpp')
+
+-incs = '. ../../extern/Eigen3'
++incs = '. /usr/include/eigen3'
+
+ defs = []
+
+diff -Npur blender-2.61.orig/source/blender/ikplugin/CMakeLists.txt blender-2.61/source/blender/ikplugin/CMakeLists.txt
+--- blender-2.61.orig/source/blender/ikplugin/CMakeLists.txt 2011-12-20 20:22:32.116762096 +0100
++++ blender-2.61/source/blender/ikplugin/CMakeLists.txt 2011-12-20 20:29:42.547754494 +0100
+@@ -49,9 +49,11 @@ set(SRC
+ if(WITH_IK_ITASC)
+ add_definitions(-DWITH_IK_ITASC)
+ list(APPEND INC
+- ../../../extern/Eigen3
+ ../../../intern/itasc
+ )
++ list(APPEND INC_SYS
++ /usr/include/eigen3
++ )
+ list(APPEND SRC
+ intern/itasc_plugin.cpp
+ )
+diff -Npur blender-2.61.orig/source/blender/ikplugin/SConscript blender-2.61/source/blender/ikplugin/SConscript
+--- blender-2.61.orig/source/blender/ikplugin/SConscript 2011-12-20 20:22:32.116762096 +0100
++++ blender-2.61/source/blender/ikplugin/SConscript 2011-12-20 20:24:26.328760105 +0100
+@@ -4,7 +4,7 @@ defs = []
+ sources = env.Glob('intern/*.c') + env.Glob('intern/*.cpp')
+
+ incs = '#/intern/guardedalloc #/intern/iksolver/extern ../makesdna ../blenlib'
+-incs += ' ../blenkernel ../include ../ikplugin #/intern/itasc #/extern/Eigen3'
++incs += ' ../blenkernel ../include ../ikplugin #/intern/itasc /usr/include/eigen3'
+
+ defs.append('WITH_IK_ITASC')
+
+diff -Npur blender-2.61.orig/source/gameengine/Converter/CMakeLists.txt blender-2.61/source/gameengine/Converter/CMakeLists.txt
+--- blender-2.61.orig/source/gameengine/Converter/CMakeLists.txt 2011-12-20 20:22:31.708762102 +0100
++++ blender-2.61/source/gameengine/Converter/CMakeLists.txt 2011-12-20 20:28:50.404755406 +0100
+@@ -50,7 +50,6 @@ set(INC
+ ../../blender/makesrna
+ ../../blender/windowmanager
+ ../../../extern/bullet2/src
+- ../../../extern/Eigen3
+ ../../../intern/container
+ ../../../intern/guardedalloc
+ ../../../intern/moto/include
+@@ -59,7 +58,7 @@ set(INC
+ )
+
+ set(INC_SYS
+-
++ /usr/include/eigen3
+ )
+
+ set(SRC
+diff -Npur blender-2.61.orig/source/gameengine/Converter/SConscript blender-2.61/source/gameengine/Converter/SConscript
+--- blender-2.61.orig/source/gameengine/Converter/SConscript 2011-12-20 20:22:31.708762102 +0100
++++ blender-2.61/source/gameengine/Converter/SConscript 2011-12-20 20:25:17.397759112 +0100
+@@ -21,7 +21,7 @@ incs += ' #source/blender/windowmanager'
+ incs += ' #source/blender/makesrna'
+ incs += ' #source/blender/ikplugin'
+ incs += ' #extern/recastnavigation/Detour/Include'
+-incs += ' #extern/Eigen3'
++incs += ' /usr/include/eigen3'
+
+ incs += ' ' + env['BF_BULLET_INC']
+
diff --git a/media-gfx/blender/files/blender-2.61-enable_site_module.patch b/media-gfx/blender/files/blender-2.61-enable_site_module.patch
new file mode 100644
index 0000000..b913acd
--- /dev/null
+++ b/media-gfx/blender/files/blender-2.61-enable_site_module.patch
@@ -0,0 +1,31 @@
+--- source/blender/python/intern/bpy_interface.c-original 2011-12-15 23:01:09.059429414 +0100
++++ source/blender/python/intern/bpy_interface.c 2011-12-15 23:01:17.312478333 +0100
+@@ -219,10 +219,6 @@
+ * blender is utf-8 too - campbell */
+ BLI_setenv("PYTHONIOENCODING", "utf-8:surrogateescape");
+
+- /* Python 3.2 now looks for '2.xx/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();
+
+--- source/gameengine/Ketsji/KX_PythonInit.cpp-original 2011-12-15 23:01:05.043919062 +0100
++++ source/gameengine/Ketsji/KX_PythonInit.cpp 2011-12-15 23:01:23.926318921 +0100
+@@ -1823,7 +1823,6 @@
+ STR_String pname = progname;
+ Py_SetProgramName(pname.Ptr());
+ #endif
+- Py_NoSiteFlag=1;
+ Py_FrozenFlag=1;
+
+ /* must run before python initializes */
+@@ -1896,7 +1895,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.61-glew.patch b/media-gfx/blender/files/blender-2.61-glew.patch
new file mode 100644
index 0000000..365fc08
--- /dev/null
+++ b/media-gfx/blender/files/blender-2.61-glew.patch
@@ -0,0 +1,44 @@
+--- extern/SConscript-original 2011-12-15 16:25:29.379238136 +0100
++++ extern/SConscript 2011-12-15 16:26:10.376448670 +0100
+@@ -2,7 +2,6 @@
+
+ Import('env')
+
+-SConscript(['glew/SConscript'])
+ SConscript(['colamd/SConscript'])
+
+ if env['WITH_BF_GAMEENGINE']:
+--- source/blender/editors/include/BIF_gl.h-original 2011-12-15 16:27:31.299733603 +0100
++++ source/blender/editors/include/BIF_gl.h 2011-12-15 16:30:50.993113607 +0100
+@@ -33,7 +33,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-original 2011-12-15 16:26:50.104497900 +0100
++++ extern/CMakeLists.txt 2011-12-15 16:28:04.397940215 +0100
+@@ -40,9 +40,6 @@
+ add_subdirectory(binreloc)
+ endif()
+
+-if(WITH_BUILTIN_GLEW)
+- add_subdirectory(glew)
+-endif()
+
+ if(WITH_GAMEENGINE)
+ add_subdirectory(recastnavigation)
+--- CMakeLists.txt-original 2011-12-15 16:27:03.309176149 +0100
++++ CMakeLists.txt 2011-12-15 16:29:02.001261302 +0100
+@@ -156,7 +156,7 @@
+
+ if(UNIX AND NOT APPLE)
+ option(WITH_X11_XINPUT "Enable X11 Xinput (tablet support and unicode input)" 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)
+ option(WITH_XDG_USER_DIRS "Build with XDG Base Directory Specification (only config and documents for now)" OFF)
+ mark_as_advanced(WITH_XDG_USER_DIRS)
+ else()
diff --git a/media-gfx/blender/files/blender-2.61-insecure.desktop b/media-gfx/blender/files/blender-2.61-insecure.desktop
new file mode 100644
index 0000000..498f303
--- /dev/null
+++ b/media-gfx/blender/files/blender-2.61-insecure.desktop
@@ -0,0 +1,15 @@
+[Desktop Entry]
+Name=Blender-2.61 (reduced security)
+GenericName=3D modeller (reduced security)
+GenericName[es]=modelador 3D (reduced security)
+GenericName[de]=3D Modellierer (weniger Sicherheit)
+GenericName[fr]=modeleur 3D (reduced security)
+GenericName[ru]=Редактор 3D-моделей (reduced security)
+Comment=3D modeling, animation, rendering and post-production
+Comment[es]=modelado 3D, animación, renderizado y post-producción
+Exec=blender-2.61 --enable-autoexec %f
+Icon=blender-2.61
+Terminal=false
+Type=Application
+Categories=Graphics;3DGraphics;
+MimeType=application/x-blender;
diff --git a/media-gfx/blender/files/blender-desktop.patch b/media-gfx/blender/files/blender-desktop.patch
new file mode 100644
index 0000000..515a79d
--- /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;
diff --git a/media-gfx/blender/metadata.xml b/media-gfx/blender/metadata.xml
new file mode 100644
index 0000000..3cb3c70
--- /dev/null
+++ b/media-gfx/blender/metadata.xml
@@ -0,0 +1,67 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+
+ <herd>graphics</herd>
+
+ <maintainer>
+ <email>lu_zero@gentoo.org</email>
+ <name>Luca Barbato</name>
+ </maintainer>
+
+ <maintainer>
+ <email>anthoine.bourgeois@gmail.com</email>
+ <name>Anthoine Bourgeois</name>
+ <description>aluco's overlay maintainer</description>
+ </maintainer>
+
+ <longdescription>
+ Blender, the open source software for 3D modeling, animation,
+ rendering, post-production, interactive creation and playback.
+ Available for Windows, Linux, Irix, Sun Solaris, FreeBSD or Mac OS X.
+ </longdescription>
+ <use>
+ <flag name="3dmouse">
+ Support 3D mouse (<pkg>media-libs/libspnav</pkg>).
+ </flag>
+ <flag name="game-engine">
+ Adds Game Engine support to Blender (>=2.5* ebuilds).
+ </flag>
+ <flag name="contrib">
+ Install contrib scripts.
+ </flag>
+ <flag name="openexr">
+ Support for the OpenEXR graphics file format.
+ </flag>
+ <flag name="collada">
+ Add support for Collada interchange format.
+ </flag>
+ <flag name="cycles">
+ Enables Cycles render engine.
+ </flag>
+ <flag name="dds">
+ Adds DDS textures support to Blender.
+ </flag>
+ <flag name="player">
+ Build the Blender Player.
+ </flag>
+ <flag name="elbeem">
+ Adds surface fluid simulation to Blender using El'Beem library.
+ </flag>
+ <flag name="apidoc">
+ Build GameEngine/Python/C API documentation directly from the source
+ code using tools epydoc (dev-python/epydoc) and doxygen
+ (app-doc/doxygen).
+ </flag>
+ <flag name="tweak-mode">
+ This flag allows you to model without confirming each translation,
+ in particular it lets you grab with left mouse button (LMB) and not
+ having to confirm by another click. Blender 'Tweak Mode' is similar
+ to the 'Tweak Mode' of the Wings modeller (<pkg>media-gfx/wings</pkg>).
+ </flag>
+ <flag name="redcode">
+ This flag add support for RED CODE camera digital format (5K HD
+ images *.r3d) - EXPERIMENTAL.
+ </flag>
+ </use>
+</pkgmetadata>