diff --git a/blender-2.44-bid.patch b/blender-2.44-bid.patch new file mode 100644 index 0000000..e6acba8 --- /dev/null +++ b/blender-2.44-bid.patch @@ -0,0 +1,16 @@ +--- blender-2.44/release/plugins/bmake.bid 2004-12-27 20:28:48.000000000 +0100 ++++ blender-2.44/release/plugins/bmake 2007-08-09 18:13:34.000000000 +0200 +@@ -60,10 +60,10 @@ elif ( test $UNAME = "OpenBSD" ) then + LDFLAGS="-Bshareable"; + elif ( test $UNAME = "Linux" ) then + CC="gcc"; +- CFLAGS="-fPIC -funsigned-char -O2"; ++ CFLAGS="${RPM_OPT_FLAGS} -fPIC -funsigned-char"; + +- LD="ld"; +- LDFLAGS="-Bshareable"; ++ LD="gcc"; ++ LDFLAGS="--shared ${RPM_OPT_FLAGS}"; + elif ( test $UNAME = "SunOS" ) then + CC="cc"; + CFLAGS="-O"; diff --git a/blender-2.44-scons.patch b/blender-2.44-scons.patch new file mode 100644 index 0000000..5afb80f --- /dev/null +++ b/blender-2.44-scons.patch @@ -0,0 +1,11 @@ +--- blender-2.44/SConstruct.orig 2007-05-07 18:09:40.000000000 +0200 ++++ blender-2.44/SConstruct 2007-05-20 22:52:13.000000000 +0200 +@@ -237,7 +242,7 @@ + + def CheckFreeAlut(context,env): + context.Message( B.bc.OKGREEN + "Linux platform detected:\n checking for FreeAlut... " + B.bc.ENDC ) +- env['LIBS'] = 'alut' ++ env['LIBS'] = ['alut', 'openal'] + result = context.TryLink(mylib_test_source_file, '.c') + context.Result(result) + return result diff --git a/blender-2.45-cve-2008-1102.patch b/blender-2.45-cve-2008-1102.patch new file mode 100644 index 0000000..43015b3 --- /dev/null +++ b/blender-2.45-cve-2008-1102.patch @@ -0,0 +1,13 @@ +diff -up blender-2.45/source/blender/imbuf/intern/radiance_hdr.c.csv blender-2.45/source/blender/imbuf/intern/radiance_hdr.c +--- blender-2.45/source/blender/imbuf/intern/radiance_hdr.c.csv 2008-04-24 16:22:36.000000000 +0200 ++++ blender-2.45/source/blender/imbuf/intern/radiance_hdr.c 2008-04-24 16:25:59.000000000 +0200 +@@ -191,7 +191,8 @@ struct ImBuf *imb_loadhdr(unsigned char + } + } + if (found) { +- sscanf((char*)&mem[x+1], "%s %d %s %d", (char*)&oriY, &height, (char*)&oriX, &width); ++ if (sscanf((char *)&mem[x+1], "%79s %d %79s %d", (char*)&oriY, &height, ++ (char*)&oriX, &width) != 4) return NULL; + + /* find end of this line, data right behind it */ + ptr = (unsigned char *)strchr((char*)&mem[x+1], '\n'); diff --git a/blender-2.45-gcc43.patch b/blender-2.45-gcc43.patch new file mode 100644 index 0000000..6aa444e --- /dev/null +++ b/blender-2.45-gcc43.patch @@ -0,0 +1,87 @@ +diff -up blender-2.45/source/blender/yafray/intern/yafray_Render.cpp.gcc43 blender-2.45/source/blender/yafray/intern/yafray_Render.cpp +--- blender-2.45/source/blender/yafray/intern/yafray_Render.cpp.gcc43 2007-09-18 06:58:44.000000000 +0200 ++++ blender-2.45/source/blender/yafray/intern/yafray_Render.cpp 2008-01-17 20:49:05.000000000 +0100 +@@ -8,6 +8,8 @@ + + #include + ++#include ++ + using namespace std; + + void yafrayRender_t::clearAll() +diff -up blender-2.45/source/blender/yafray/intern/export_File.cpp.gcc43 blender-2.45/source/blender/yafray/intern/export_File.cpp +--- blender-2.45/source/blender/yafray/intern/export_File.cpp.gcc43 2007-09-18 06:58:44.000000000 +0200 ++++ blender-2.45/source/blender/yafray/intern/export_File.cpp 2008-01-17 20:49:05.000000000 +0100 +@@ -2,6 +2,8 @@ + + #include + ++#include ++ + using namespace std; + + static string command_path = ""; +diff -up blender-2.45/source/blender/yafray/intern/export_Plugin.cpp.gcc43 blender-2.45/source/blender/yafray/intern/export_Plugin.cpp +--- blender-2.45/source/blender/yafray/intern/export_Plugin.cpp.gcc43 2007-09-18 06:58:44.000000000 +0200 ++++ blender-2.45/source/blender/yafray/intern/export_Plugin.cpp 2008-01-17 20:49:05.000000000 +0100 +@@ -1,6 +1,9 @@ + #include "export_Plugin.h" + + #include ++ ++#include ++ + using namespace std; + + +diff -up blender-2.45/source/gameengine/GamePlayer/common/GPC_KeyboardDevice.cpp.gcc43 blender-2.45/source/gameengine/GamePlayer/common/GPC_KeyboardDevice.cpp +--- blender-2.45/source/gameengine/GamePlayer/common/GPC_KeyboardDevice.cpp.gcc43 2008-01-17 20:56:36.000000000 +0100 ++++ blender-2.45/source/gameengine/GamePlayer/common/GPC_KeyboardDevice.cpp 2008-01-17 20:57:03.000000000 +0100 +@@ -32,6 +32,8 @@ + + #include "GPC_KeyboardDevice.h" + ++#include ++ + /** + * NextFrame toggles currentTable with previousTable, + * and copies relevant event information from previous to current table +diff -up blender-2.45/source/gameengine/Rasterizer/RAS_OpenGLRasterizer/RAS_GLExtensionManager.h.gcc43 blender-2.45/source/gameengine/Rasterizer/RAS_OpenGLRasterizer/RAS_GLExtensionManager.h +--- blender-2.45/source/gameengine/Rasterizer/RAS_OpenGLRasterizer/RAS_GLExtensionManager.h.gcc43 2007-09-18 06:58:17.000000000 +0200 ++++ blender-2.45/source/gameengine/Rasterizer/RAS_OpenGLRasterizer/RAS_GLExtensionManager.h 2008-01-17 20:49:05.000000000 +0100 +@@ -56,7 +56,7 @@ + # undef GL_ARB_vertex_program + #endif + +-#include "glext.h" ++// #include "glext.h" + + #include "EXT_separate_specular_color.h" + #include "ARB_multitexture.h" +diff -up blender-2.45/intern/string/STR_String.h.gcc43 blender-2.45/intern/string/STR_String.h +--- blender-2.45/intern/string/STR_String.h.gcc43 2007-09-18 06:58:01.000000000 +0200 ++++ blender-2.45/intern/string/STR_String.h 2008-01-17 20:49:05.000000000 +0100 +@@ -47,6 +47,10 @@ + + #include + #include ++ ++#include ++#include ++ + using namespace std; + + +diff -up blender-2.45/intern/ghost/intern/GHOST_WindowX11.cpp.gcc43 blender-2.45/intern/ghost/intern/GHOST_WindowX11.cpp +--- blender-2.45/intern/ghost/intern/GHOST_WindowX11.cpp.gcc43 2007-09-18 06:57:51.000000000 +0200 ++++ blender-2.45/intern/ghost/intern/GHOST_WindowX11.cpp 2008-01-17 20:49:05.000000000 +0100 +@@ -42,6 +42,8 @@ + #include + #endif + ++#include ++#include + + // For obscure full screen mode stuuf + // lifted verbatim from blut. diff --git a/blender-2.45-sc.patch b/blender-2.45-sc.patch new file mode 100644 index 0000000..a461aa4 --- /dev/null +++ b/blender-2.45-sc.patch @@ -0,0 +1,15 @@ +diff -up blender-2.45/tools/btools.py.scons blender-2.45/tools/btools.py +--- blender-2.45/tools/btools.py.scons 2007-09-18 07:00:48.000000000 +0200 ++++ blender-2.45/tools/btools.py 2008-04-27 21:23:27.000000000 +0200 +@@ -1,7 +1,10 @@ + import os + import os.path + import SCons.Options +-import SCons.Options.BoolOption ++try: ++ import SCons.Options.BoolOption ++except ImportError: ++ pass + try: + import subprocess + except ImportError: diff --git a/blender-2.45-yafray.patch b/blender-2.45-yafray.patch new file mode 100644 index 0000000..3c64b90 --- /dev/null +++ b/blender-2.45-yafray.patch @@ -0,0 +1,24 @@ +--- blender-2.45/source/blender/yafray/intern/export_Plugin.cpp.orig 2007-09-18 05:58:44.000000000 +0100 ++++ blender-2.45/source/blender/yafray/intern/export_Plugin.cpp 2008-02-05 14:32:07.000000000 +0000 +@@ -97,8 +97,8 @@ + #else + static char *alternative[]= + { +- "/usr/local/lib/", +- "/usr/lib/", ++ "/usr/local/lib64/", ++ "/usr/lib64/", + NULL + }; + +@@ -120,8 +120,8 @@ + #else + static char *alternative[]= + { +- "/usr/local/lib/yafray", +- "/usr/lib/yafray", ++ "/usr/local/lib64/yafray", ++ "/usr/lib64/yafray", + NULL + }; + diff --git a/blender.desktop b/blender.desktop index 6997a7a..aa50e0e 100644 --- a/blender.desktop +++ b/blender.desktop @@ -7,4 +7,4 @@ Icon=blender.png Terminal=false Type=Application Categories=Graphics;Application; -MimeType=application/x-blender +MimeType=application/x-blender; diff --git a/blender.spec b/blender.spec index b4ffeea..815ef6a 100644 --- a/blender.spec +++ b/blender.spec @@ -1,36 +1,63 @@ +%define blenderlib %{_datadir}/blender +%define plugins %{_libdir}/blender/plugins + Name: blender -Version: 2.37 -Release: 1.fc3.1 +Version: 2.45 +Release: 13%{?dist} Summary: 3D modeling, animation, rendering and post-production Group: Applications/Multimedia -License: GPL +License: GPLv2 URL: http://www.blender.org -Source0: http://download.blender.org/source/blender-2.37.tar.gz +# During a Legel issue (#239476) the package contains a cusromized +# source package created as fellow. +# wget http://download.blender.org/source/blender-%{version}.tar.gz +# tar -zxv blender-%{version}.tar.gz +# rm -rf blender-%{version}/extern/ffmpeg +# tar -zcf blender-%{version}-noffmpeg.tar.gz blender-%{version}/ +Source0: blender-%{version}-noffmpeg.tar.gz Source1: http://bane.servebeer.com/programming/blender/import-3ds-0.7.py Source2: http://bane.servebeer.com/programming/blender/export-3ds-0.71.py Source3: blender.png Source4: blender.desktop Source5: blender.xml -Patch0: blender-2.37-x86_64.patch +Source6: blender-wrapper +Source7: blender-2.44.config + +Patch1: blender-2.44-scons.patch +Patch2: blender-2.44-bid.patch +Patch3: blender-2.45-gcc43.patch +Patch4: blender-2.45-yafray.patch +Patch5: blender-2.45-sc.patch + +Patch100: blender-2.45-cve-2008-1102.patch + BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildRequires: desktop-file-utils BuildRequires: esound-devel BuildRequires: freeglut-devel -BuildRequires: gettext +BuildRequires: gettext-devel BuildRequires: libjpeg-devel BuildRequires: libogg-devel BuildRequires: libpng-devel BuildRequires: libtool BuildRequires: libvorbis-devel -BuildRequires: openal-devel +BuildRequires: freealut-devel BuildRequires: openssl-devel BuildRequires: python-devel BuildRequires: scons BuildRequires: SDL-devel BuildRequires: zlib-devel +BuildRequires: libtiff-devel +BuildRequires: libXi-devel +BuildRequires: xorg-x11-proto-devel +BuildRequires: mesa-libGL-devel +BuildRequires: mesa-libGLU-devel +buildRequires: freetype-devel +BuildRequires: OpenEXR-devel + Requires(post): desktop-file-utils Requires(post): shared-mime-info Requires(postun): desktop-file-utils @@ -43,35 +70,104 @@ animation, rendering and post-production to interactive creation and playback. Professionals and novices can easily and inexpensively publish stand-alone, secure, multi-platform content to the web, CD-ROMs, and other media. +This version doesn't contains ffmpeg support, so that any features may be not +available. %prep -%setup -q -n %{name} -%patch0 -p1 -b .x86_64 +%setup -q +%patch1 -p1 -b .org +%patch2 -p1 -b .bid +%patch3 -p1 -b .gcc43 +%patch5 -p1 -b .scons + + +%if "%{?_lib}" == "lib64" +%patch4 -p1 +%endif + +%patch100 -p1 -b .cve + +PYVER=$(%{__python} -c "import sys ; print sys.version[:3]") + +sed -e 's|@LIB@|%{_libdir}|g' -e "s/@PYVER@/$PYVER/g" \ + <%{SOURCE7} >user-config.py %build -sed -i "s/use_openal =.*/use_openal = 'true'/g;" SConstruct -scons +# +# Don't use $RPM_OPT_FLAGS (see #199418) +# + +scons %{?_smp_mflags} blenderplayer BF_QUIET=0 + +install -d release/plugins/include +install -m 644 source/blender/blenpluginapi/*.h release/plugins/include + +chmod +x release/plugins/bmake + +make -C release/plugins/ %install rm -rf ${RPM_BUILD_ROOT} -install -D -m0755 blender ${RPM_BUILD_ROOT}/%{_bindir}/blender -mkdir -p ${RPM_BUILD_ROOT}%{_datadir}/blender/scripts/ -install -p -D -m0644 release/scripts/*.py ${RPM_BUILD_ROOT}%{_datadir}/blender/scripts/ -install -p -D -m0644 %{SOURCE1} ${RPM_BUILD_ROOT}%{_datadir}/blender/scripts/import-3ds-0.7.py -install -p -D -m0644 %{SOURCE2} ${RPM_BUILD_ROOT}%{_datadir}/blender/scripts/export-3ds-0.71.py -install -p -D -m0644 %{SOURCE3} ${RPM_BUILD_ROOT}%{_datadir}/pixmaps/blender.png -install -p -D -m0644 %{SOURCE5} ${RPM_BUILD_ROOT}%{_datadir}/mime/packages/blender.xml + +install -D -m 755 build/linux2/bin/blender ${RPM_BUILD_ROOT}/%{_bindir}/blender.bin + +install -D -m 755 build/linux2/bin/blenderplayer ${RPM_BUILD_ROOT}/%{_bindir}/blenderplayer + +install -D -m 755 %{SOURCE6} ${RPM_BUILD_ROOT}/%{_bindir}/blender + +# install -D -m 755 blenderplayer ${RPM_BUILD_ROOT}/%{_bindir}/blenderplayer + +# +# Install miscellanous files to /usr/lib/blender +# + +mkdir -p ${RPM_BUILD_ROOT}/%{blenderlib} + +cp -a release/scripts/bpydata ${RPM_BUILD_ROOT}/%{blenderlib} +cp -a release/scripts ${RPM_BUILD_ROOT}/%{blenderlib} + +pushd bin/.blender/locale +mv pt_br pt_BR +mv zh_cn uh_CN +rm -rf $(find -name '.svn' -print) +popd + +cp -a bin/.blender/locale ${RPM_BUILD_ROOT}/%{_datadir} + +install -p -D -m 644 release/scripts/*.py ${RPM_BUILD_ROOT}/%{blenderlib} + +install -m 644 release/VERSION ${RPM_BUILD_ROOT}/%{blenderlib} +install -m 644 bin/.blender/.Blanguages ${RPM_BUILD_ROOT}/%{blenderlib} +install -m 644 bin/.blender/.bfont.ttf ${RPM_BUILD_ROOT}/%{blenderlib} + +install -p -D -m 644 %{SOURCE1} ${RPM_BUILD_ROOT}%{blenderlib}/import-3ds-0.7.py +install -p -D -m 644 %{SOURCE2} ${RPM_BUILD_ROOT}%{blenderlib}/export-3ds-0.71.py + +install -p -D -m 644 %{SOURCE3} ${RPM_BUILD_ROOT}%{_datadir}/pixmaps/blender.png + +install -p -D -m 644 %{SOURCE5} ${RPM_BUILD_ROOT}%{_datadir}/mime/packages/blender.xml + +# +# Install plugins +# + +install -d ${RPM_BUILD_ROOT}/%{plugins}/sequence +install -d ${RPM_BUILD_ROOT}/%{plugins}/texture + +install -m 644 release/plugins/sequence/*.so ${RPM_BUILD_ROOT}/%{plugins}/sequence +install -m 655 release/plugins/texture/*.so ${RPM_BUILD_ROOT}/%{plugins}/texture + desktop-file-install --vendor fedora \ --dir ${RPM_BUILD_ROOT}%{_datadir}/applications \ --add-category X-Fedora \ %{SOURCE4} +%find_lang %name %clean rm -rf ${RPM_BUILD_ROOT} - %post update-mime-database %{_datadir}/mime > /dev/null 2>&1 || : update-desktop-database %{_datadir}/applications > /dev/null 2>&1 || : @@ -82,21 +178,180 @@ update-mime-database %{_datadir}/mime > /dev/null 2>&1 || : update-desktop-database %{_datadir}/applications > /dev/null 2>&1 || : -%files +%files -f %name.lang %defattr(-,root,root,-) %doc COPYING README doc/python-dev-guide.txt doc/GPL-license.txt doc/bf-members.txt %{_bindir}/* %{_datadir}/applications/fedora-blender.desktop %{_datadir}/pixmaps/*.png -%{_datadir}/blender/ +%{blenderlib}/ +%{_libdir}/blender/ %{_datadir}/mime/packages/blender.xml - %changelog -* Mon Jun 6 2005 Toshio Kuratomi 2.37-1.fc3.1 -- Sync against the FC4 package: - + Update to 2.37. - + Patch to fix compilation errors on x86_64. +* Sun Apr 27 2008 Jochen Schmitt 2.45-13 +- More generic patch for scons issue + +* Thu Apr 24 2008 Jochen Schmitt 2.45-12 +- Fix odd scons compatibility issue + +* Thu Apr 24 2008 Jochen Schmitt 2.45-11 +- Fix CVS-2008-1102 (#443937) + +* Wed Mar 12 2008 Jochen Schmitt 2.45-10 +- Clarification of restrictions caused by legal issues + +* Tue Mar 4 2008 Jochen Schmitt 2.45-9 +- Apply yafray patch only on 64-bit systems + +* Thu Feb 28 2008 Jochen Schmitt 2.45-8 +- Fix yafray load bug (#451571) + +* Sun Feb 10 2008 Jochen Schmitt 2.45-7 +- Rebuild for gcc-4.3 + +* Sat Jan 26 2008 Alex Lancaster 2.45-6 +- Rebuild for new gettext + +* Thu Jan 17 2008 Jochen Schmitt 2.45-5 +- Fix gcc-4.3 related issues + +* Tue Oct 16 2007 Jochen Schmitt 2.45-4 +- Rebuild again for OpenEXR + +* Sun Oct 14 2007 Jochen Schmitt 2.45-3 +- Rebuild + +* Sun Sep 23 2007 Jochen Schmitt 2.45-2 +- Change method how to determinate python version + +* Thu Sep 20 2007 Jochen Schmitt 2.45-1 +- New upstream release + +* Thu Aug 9 2007 Jochen Schmitt 2.44-8 +- Fix koji-python issue + +* Wed Aug 8 2007 Jochen Schmitt 2.44-6 +- Changing license tag +- Add python as an BR + +* Mon May 21 2007 Jochen Schmitt 2.44-4 +- Use of $$RPM_OPT_FLAGS to compile blender + +* Sun May 20 2007 Jochen Schmitt 2.44-2 +- Increase release number + +* Tue May 15 2007 Jochen Schmitt 2.44-1 +- New upstream release + +* Wed May 9 2007 Jochen Schmitt 2.42a-24 +- Remove ffmpeg lib during a legal issue (#239476) + +* Tue May 8 2007 Jochen Schmitt 2.42a-23 +- Exclude ppc64 arch + +* Mon May 7 2007 Jochen Schmitt 2.42a-21 +- Fix security issue (#239338) + +* Sun Apr 22 2007 Jochen Schmitt 2.42a-20 +- Romove package from the x86_64 arch (#237423) + +* Mon Jan 8 2007 Jochen Schmitt 2.42a-18 +- Rebult + +* Thu Dec 14 2006 Jochen Schmitt 2.42a-17 +- Replace x86-patch with one from the blender project + +* Thu Dec 14 2006 Jochen Schmitt 2.42a-16 +- Rebuild + +* Tue Dec 12 2006 Jochen Schmitt 2.42a-12 +- Fix typo + +* Tue Dec 12 2006 Jochen Schmitt 2.42a-11 +- Try x64-patch for complle with python-2.5 + +* Tue Dec 12 2006 Jochen Schmitt 2.42a-10 +- Exclude x86_64 arch (#219329) + +* Mon Dec 11 2006 Jochen Schmitt 2.42a-9 +- New build to solve broken deps + +* Wed Nov 29 2006 Jochen Schmitt 2.42a-6 +- Rebuild to solve broken deps + +* Tue Oct 31 2006 Jochen Schmitt 2.42a-5 +- Rebuilt to fix broken deps + +* Mon Oct 16 2006 Jochen Schmitt 2.42a-4 +- /usr/lib/blender should own by the package + +* Wed Oct 11 2006 Jochen Schmitt 2.42a-3 +- Correct invalid locale paths (#210209) + +* Wed Sep 13 2006 Jochen Schmitt 2.42a-2 +- Update to new upstream release + +* Tue Sep 12 2006 Jochen Schmitt 2.42-10 +- Rebuild to solve broken deps + +* Sun Sep 3 2006 Jochen Schmitt 2.42-9 +- Rebuild for FC-6 + +* Thu Aug 10 2006 Jochen Schmitt 2.42-7 +- Remove %%ghost for pyo files for fullfilling new packaging guidelines + +* Thu Aug 10 2006 Jochen Schmitt 2.42-6 +- Rebuilt to solve broken deps + +* Wed Jul 26 2006 Jochen Schmitt 2.42-5 +- Fix symlink in blender-wrapper to locale + +* Thu Jul 20 2006 Jochen Schmitt 2.42-4 +- Fix UI Problem (#199418) + +* Mon Jul 17 2006 Jochen Schmitt 2.42-3 +- Fix some BR stuff. + +* Sun Jul 16 2006 Jochen Schmitt 2.42-1 +- New upstream release. + +* Sun Feb 19 2006 Jochen Schmitt 2.41-3 +- Rebuild for FC-5. + +* Mon Feb 6 2006 Jochen Schmitt 2.41-2 +- Add freealut as dependancy. + +* Sun Jan 30 2006 Jochen Schmitt 2.41-1 +- Update to new upstream release. + +* Wed Jan 18 2006 Jochen Schmitt 2.40-2 +- New upstream release. +- adapting to mudular X. +- add libtiff-devel as BuildRequires. + +* Mon Jun 6 2005 Toshio Kuratomi 2.37-3 +- Bump release for development. + +* Sun Jun 5 2005 Toshio Kuratomi 2.37-2 +- Patch to fix compilation errors on x86_64. + +* Sun Jun 5 2005 Toshio Kuratomi 2.37-1 +- Update to 2.37. +- Drop gcc4 patch. + +* Mon May 16 2005 Toshio Kuratomi 2.36-3 +- Bump and rebuild now that scons is available on all platforms. + +* Sat May 14 2005 Toshio Kuratomi 2.36-2 +- Fix a gcc4 error. + +* Fri May 13 2005 Toshio Kuratomi 2.36-1 +- Update to 2.36. +- Rebuild with new gcc4. + +* Fri Apr 7 2005 Michael Schwendt +- rebuilt * Mon Nov 15 2004 Phillip Compton 2.35-1 - 2.35.