From 8b672b2c48164c78731ae142ae4761d91666bdec Mon Sep 17 00:00:00 2001 From: Mark H Weaver Date: Mon, 18 Mar 2019 21:39:12 -0400 Subject: gnu: blender: Restore version 2.79b for systems without OpenGL 3. Fixes . * gnu/packages/graphics.scm (blender-2.79): New variable. (blender)[description]: Remove obsolete claim that the stable release no longer works in Guix. * gnu/packages/patches/blender-2.79-newer-ffmpeg.patch, gnu/packages/patches/blender-2.79-python-3.7-fix.patch: New files. * gnu/local.mk (dist_patch_DATA): Add them. --- gnu/packages/graphics.scm | 93 ++++++++++++++++++++++++++++++++++++++++++++++- 1 file changed, 91 insertions(+), 2 deletions(-) (limited to 'gnu/packages/graphics.scm') diff --git a/gnu/packages/graphics.scm b/gnu/packages/graphics.scm index bf4cc89b08..11158bdfd1 100644 --- a/gnu/packages/graphics.scm +++ b/gnu/packages/graphics.scm @@ -11,6 +11,7 @@ ;;; Copyright © 2018 Mathieu Othacehe ;;; Copyright © 2018 Alex Kost ;;; Copyright © 2018 Kei Kebreau +;;; Copyright © 2019 Mark H Weaver ;;; ;;; This file is part of GNU Guix. ;;; @@ -165,10 +166,98 @@ the 3D pipeline—modeling, rigging, animation, simulation, rendering, compositing and motion tracking, even video editing and game creation. The application can be customized via its API for Python scripting. -WARNING: This package offers a beta build of Blender, because the stable release -no longer works in Guix. See @uref{https://issues.guix.info/issue/33882}.") +WARNING: This is a beta build of Blender.") (license license:gpl2+)))) +(define-public blender-2.79 + (package + (name "blender") + (version "2.79b") + (source (origin + (method url-fetch) + (uri (string-append "https://download.blender.org/source/" + "blender-" version ".tar.gz")) + (sha256 + (base32 + "1g4kcdqmf67srzhi3hkdnr4z1ph4h9sza1pahz38mrj998q4r52c")) + (patches (search-patches "blender-2.79-newer-ffmpeg.patch" + "blender-2.79-python-3.7-fix.patch")))) + (build-system cmake-build-system) + (arguments + (let ((python-version (version-major+minor (package-version python)))) + `(;; Test files are very large and not included in the release tarball. + #:tests? #f + #:configure-flags + (list "-DWITH_CODEC_FFMPEG=ON" + "-DWITH_CODEC_SNDFILE=ON" + "-DWITH_CYCLES=ON" + "-DWITH_DOC_MANPAGE=ON" + "-DWITH_FFTW3=ON" + "-DWITH_GAMEENGINE=ON" + "-DWITH_IMAGE_OPENJPEG=ON" + "-DWITH_INPUT_NDOF=ON" + "-DWITH_INSTALL_PORTABLE=OFF" + "-DWITH_JACK=ON" + "-DWITH_MOD_OCEANSIM=ON" + "-DWITH_PLAYER=ON" + "-DWITH_PYTHON_INSTALL=OFF" + "-DWITH_PYTHON_INSTALL=OFF" + "-DWITH_SYSTEM_OPENJPEG=ON" + (string-append "-DPYTHON_LIBRARY=python" ,python-version "m") + (string-append "-DPYTHON_LIBPATH=" (assoc-ref %build-inputs "python") + "/lib") + (string-append "-DPYTHON_INCLUDE_DIR=" (assoc-ref %build-inputs "python") + "/include/python" ,python-version "m") + (string-append "-DPYTHON_VERSION=" ,python-version)) + #:phases + (modify-phases %standard-phases + (add-after 'unpack 'fix-broken-import + (lambda _ + (substitute* "release/scripts/addons/io_scene_fbx/json2fbx.py" + (("import encode_bin") "from . import encode_bin")) + #t)) + (add-after 'set-paths 'add-ilmbase-include-path + (lambda* (#:key inputs #:allow-other-keys) + ;; OpenEXR propagates ilmbase, but its include files do not appear + ;; in the CPATH, so we need to add "$ilmbase/include/OpenEXR/" to + ;; the CPATH to satisfy the dependency on "half.h". + (setenv "CPATH" + (string-append (assoc-ref inputs "ilmbase") + "/include/OpenEXR" + ":" (or (getenv "CPATH") ""))) + #t)))))) + (inputs + `(("boost" ,boost) + ("jemalloc" ,jemalloc) + ("libx11" ,libx11) + ("openimageio" ,openimageio) + ("openexr" ,openexr) + ("ilmbase" ,ilmbase) + ("openjpeg" ,openjpeg-1) + ("libjpeg" ,libjpeg) + ("libpng" ,libpng) + ("libtiff" ,libtiff) + ("ffmpeg" ,ffmpeg) + ("fftw" ,fftw) + ("jack" ,jack-1) + ("libsndfile" ,libsndfile) + ("freetype" ,freetype) + ("glew" ,glew) + ("openal" ,openal) + ("python" ,python) + ("zlib" ,zlib))) + (home-page "https://blender.org/") + (synopsis "3D graphics creation suite") + (description + "Blender is a 3D graphics creation suite. It supports the entirety of +the 3D pipeline—modeling, rigging, animation, simulation, rendering, +compositing and motion tracking, even video editing and game creation. The +application can be customized via its API for Python scripting. + +NOTE: This older version of Blender is the last release that does not require +OpenGL 3. It is retained for use with older computers.") + (license license:gpl2+))) + (define-public assimp (package (name "assimp") -- cgit v1.2.3