Advertisement
Guest User

guix blender

a guest
Sep 6th, 2021
56
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. (define-public blender
  2.   (package
  3.     (name "blender")
  4.     (version "2.93.4")
  5.     (source (origin
  6.               (method url-fetch)
  7.               (uri (string-append "https://download.blender.org/source/"
  8.                                   "blender-" version ".tar.xz"))
  9.               (sha256
  10.                (base32
  11.                 "MEZGEOLCGYZTGYJUHEZDMMDDGU2WGYJWGZRTGZLBGYZTCMRVGEYTSZLDMUYGKY3DMNSTSYJXMNQTKNRUGZQTQM3FGY2TIODBGMZWGOAK"))))
  12.     (build-system cmake-build-system)
  13.     (arguments
  14.       (let ((python-version (version-major+minor (package-version python))))
  15.        `(;; Test files are very large and not included in the release tarball.
  16.          #:tests? #f
  17.          #:configure-flags
  18.          (list "-DWITH_CODEC_FFMPEG=ON"
  19.                "-DWITH_CODEC_SNDFILE=ON"
  20.                "-DWITH_CYCLES=ON"
  21.                "-DWITH_DOC_MANPAGE=ON"
  22.                "-DWITH_FFTW3=ON"
  23.                "-DWITH_IMAGE_OPENJPEG=ON"
  24.                "-DWITH_INPUT_NDOF=ON"
  25.                "-DWITH_INSTALL_PORTABLE=OFF"
  26.                "-DWITH_JACK=ON"
  27.                "-DWITH_MOD_OCEANSIM=ON"
  28.                "-DWITH_OPENVDB=ON"
  29.                "-DWITH_OPENSUBDIV=ON"
  30.                "-DWITH_PYTHON_INSTALL=OFF"
  31.                (string-append "-DPYTHON_LIBRARY=python" ,python-version)
  32.                (string-append "-DPYTHON_LIBPATH=" (assoc-ref %build-inputs "python")
  33.                               "/lib")
  34.                (string-append "-DPYTHON_INCLUDE_DIR=" (assoc-ref %build-inputs "python")
  35.                               "/include/python" ,python-version)
  36.                (string-append "-DPYTHON_VERSION=" ,python-version)
  37.                (string-append "-DPYTHON_NUMPY_INCLUDE_DIRS="
  38.                               (assoc-ref %build-inputs "python-numpy")
  39.                               "/lib/python" ,python-version "/site-packages/numpy/core/include/")
  40.                (string-append "-DPYTHON_NUMPY_PATH="
  41.                               (assoc-ref %build-inputs "python-numpy")
  42.                               "/lib/python" ,python-version "/site-packages/"))
  43.          #:phases
  44.          (modify-phases %standard-phases
  45.            ;; XXX This file doesn't exist in the Git sources but will probably
  46.            ;; exist in the eventual 2.80 source tarball.
  47.            (add-after 'unpack 'fix-broken-import
  48.              (lambda _
  49.                (substitute* "release/scripts/addons/io_scene_fbx/json2fbx.py"
  50.                  (("import encode_bin") "from . import encode_bin"))
  51.                #t))
  52.            (add-after 'set-paths 'add-ilmbase-include-path
  53.              (lambda* (#:key inputs #:allow-other-keys)
  54.                ;; OpenEXR propagates ilmbase, but its include files do not appear
  55.                ;; in the CPATH, so we need to add "$ilmbase/include/OpenEXR/" to
  56.                ;; the CPATH to satisfy the dependency on "half.h".
  57.                (setenv "CPATH"
  58.                        (string-append (assoc-ref inputs "ilmbase")
  59.                                       "/include/OpenEXR"
  60.                                       ":" (or (getenv "CPATH") "")))
  61.                #t))))))
  62.     (inputs
  63.      `(("boost" ,boost)
  64.        ("jemalloc" ,jemalloc)
  65.        ("libx11" ,libx11)
  66.        ("libxi" ,libxi)
  67.        ("libxrender" ,libxrender)
  68.        ("opencolorio" ,opencolorio)
  69.        ("openimageio" ,openimageio)
  70.        ("openexr" ,openexr)
  71.        ("opensubdiv" ,opensubdiv)
  72.        ("ilmbase" ,ilmbase)
  73.        ("openjpeg" ,openjpeg)
  74.        ("libjpeg" ,libjpeg-turbo)
  75.        ("libpng" ,libpng)
  76.        ("libtiff" ,libtiff)
  77.        ("ffmpeg" ,ffmpeg)
  78.        ("fftw" ,fftw)
  79.        ("jack" ,jack-1)
  80.        ("libsndfile" ,libsndfile)
  81.        ("freetype" ,freetype)
  82.        ("glew" ,glew)
  83.        ("openal" ,openal)
  84.        ("pugixml" ,pugixml)
  85.        ("python" ,python)
  86.        ("python-numpy" ,python-numpy)
  87.        ("openvdb" ,openvdb)
  88.        ("tbb" ,tbb)
  89.        ("zlib" ,zlib)
  90.        ("embree" ,embree)))
  91.     (home-page "https://blender.org/")
  92.     (synopsis "3D graphics creation suite")
  93.     (description
  94.      "Blender is a 3D graphics creation suite.  It supports the entirety of
  95. the 3D pipeline—modeling, rigging, animation, simulation, rendering,
  96. compositing and motion tracking, even video editing and game creation.  The
  97. application can be customized via its API for Python scripting.")
  98.     (license license:gpl2+)))
Advertisement
Advertisement
Advertisement
RAW Paste Data Copied
Advertisement