X-Git-Url: https://git.hcoop.net/jackhill/guix/guix.git/blobdiff_plain/706ae8e15c8d36b0aee7c19c54c143d3e17f5784..0cb9bacbfaa3eac0d97fd56924da276b48363528:/gnu/packages/gl.scm diff --git a/gnu/packages/gl.scm b/gnu/packages/gl.scm index bde6e55607..72f450c5f7 100644 --- a/gnu/packages/gl.scm +++ b/gnu/packages/gl.scm @@ -3,13 +3,13 @@ ;;; Copyright © 2013 Joshua Grant ;;; Copyright © 2014, 2016 David Thompson ;;; Copyright © 2014, 2015, 2016, 2017 Mark H Weaver -;;; Copyright © 2016 Nils Gillmann -;;; Copyright © 2016, 2017 Ricardo Wurmus +;;; Copyright © 2016 ng0 +;;; Copyright © 2016, 2017, 2018 Ricardo Wurmus ;;; Copyright © 2016 David Thompson ;;; Copyright © 2017, 2018 Efraim Flashner ;;; Copyright © 2017 Arun Isaac -;;; Copyright © 2017, 2018 Rutger Helling -;;; Copyright © 2018 Tobias Geerinckx-Rice +;;; Copyright © 2017, 2018, 2019 Rutger Helling +;;; Copyright © 2018, 2019 Tobias Geerinckx-Rice ;;; ;;; This file is part of GNU Guix. ;;; @@ -43,15 +43,17 @@ #:use-module (gnu packages llvm) #:use-module (gnu packages pkg-config) #:use-module (gnu packages python) + #:use-module (gnu packages python-xyz) #:use-module (gnu packages tls) #:use-module (gnu packages video) #:use-module (gnu packages xdisorg) #:use-module (gnu packages xml) #:use-module (gnu packages xorg) #:use-module (guix download) - #:use-module (guix build utils) + #:use-module (guix git-download) #:use-module (guix build-system gnu) #:use-module (guix build-system cmake) + #:use-module (guix build-system meson) #:use-module ((guix licenses) #:prefix license:) #:use-module (guix packages) #:use-module (guix utils) @@ -118,7 +120,7 @@ as ASCII text.") "Freeglut is a completely Free/OpenSourced alternative to the OpenGL Utility Toolkit (GLUT) library. GLUT was originally written by Mark Kilgard to support the sample programs in the -second edition OpenGL 'RedBook'. Since then, GLUT has been used +second edition OpenGL @code{RedBook}. Since then, GLUT has been used in a wide variety of practical applications because it is simple, widely available and highly portable. @@ -156,6 +158,8 @@ the X-Consortium license.") (base32 "0nsn4s6vnv5xcgxcw6q031amvh2zfj2smy1r5mbnjj2548hxcn2l")))) (build-system gnu-build-system) + (arguments + `(#:configure-flags '("--disable-static"))) ;; The pkg-config file lists "freetype2" as Requires.private. (propagated-inputs `(("freetype" ,freetype))) (inputs `(("libx11" ,libx11) @@ -177,12 +181,13 @@ Polygon meshes, and Extruded polygon meshes.") (version "1.0") (source (origin - (method url-fetch) - (uri (string-append - "https://github.com/divVerent/s2tc/archive/v" version ".tar.gz")) + (method git-fetch) + (uri (git-reference + (url "https://github.com/divVerent/s2tc.git") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) (sha256 - (base32 "0ibfdib277fhbqvxzan0bmglwnsl1y1rw2g8skvz82l1sfmmn752")) - (file-name (string-append name "-" version ".tar.gz")))) + (base32 "1fg323fk7wlv2xh6lw66wswgcv6qi8aaadk7c28h2f2lj1s7njnf")))) (build-system gnu-build-system) (native-inputs `(("autoconf" ,autoconf) @@ -190,12 +195,6 @@ Polygon meshes, and Extruded polygon meshes.") ("libtool" ,libtool))) (inputs `(("mesa-headers" ,mesa-headers))) - (arguments - '(#:phases - (modify-phases %standard-phases - (add-after 'unpack 'autogen - (lambda _ - (zero? (system* "sh" "autogen.sh"))))))) (home-page "https://github.com/divVerent/s2tc") (synopsis "S3 Texture Compression implementation") (description @@ -224,7 +223,7 @@ also known as DXTn or DXTC) for Mesa.") (define-public mesa (package (name "mesa") - (version "18.1.2") + (version "18.3.5") (source (origin (method url-fetch) @@ -236,10 +235,10 @@ also known as DXTn or DXTC) for Mesa.") version "/mesa-" version ".tar.xz"))) (sha256 (base32 - "1ydivzm4c2k53b65lvm11d62z140xlmd7viw63bl5cm5idjg02q7")) + "0lvrfjaic7dhay9v52f9k3q5aac8xagfq3pnzjrl0cn65jlaw9s0")) (patches (search-patches "mesa-skip-disk-cache-test.patch")))) - (build-system gnu-build-system) + (build-system meson-build-system) (propagated-inputs `(;; The following are in the Requires.private field of gl.pc. ("libdrm" ,libdrm) @@ -252,10 +251,11 @@ also known as DXTn or DXTC) for Mesa.") ("xorgproto" ,xorgproto))) (inputs `(("expat" ,expat) - ("libelf" ,libelf) ;required for r600 when using llvm + ("libelf" ,elfutils) ;required for r600 when using llvm ("libva" ,(force libva-without-mesa)) ("libxml2" ,libxml2) ;; TODO: Add 'libxml2-python' for OpenGL ES 1.1 and 2.0 support + ("libxrandr" ,libxrandr) ("libxvmc" ,libxvmc) ,@(match (%current-system) ((or "x86_64-linux" "i686-linux") @@ -266,62 +266,60 @@ also known as DXTn or DXTC) for Mesa.") ("wayland" ,wayland) ("wayland-protocols" ,wayland-protocols))) (native-inputs - `(("pkg-config" ,pkg-config) - ("python" ,python-2) - ("python2-mako" ,python2-mako) + `(("bison" ,bison) + ("flex" ,flex) + ("gettext" ,gettext-minimal) + ("pkg-config" ,pkg-config) + ("python" ,python) + ("python-mako" ,python-mako) ("which" ,(@ (gnu packages base) which)))) (arguments `(#:configure-flags '(,@(match (%current-system) - ("armhf-linux" - ;; TODO: Add etnaviv,imx when libdrm supports etnaviv. - '("--with-gallium-drivers=freedreno,nouveau,r300,r600,swrast,tegra,vc4,virgl")) - ("aarch64-linux" + ((or "armhf-linux" "aarch64-linux") ;; TODO: Fix svga driver for aarch64 and armhf. - '("--with-gallium-drivers=freedreno,nouveau,pl111,r300,r600,swrast,tegra,vc4,virgl")) + '("-Dgallium-drivers=etnaviv,freedreno,imx,nouveau,pl111,r300,r600,swrast,tegra,v3d,vc4,virgl")) (_ - '("--with-gallium-drivers=i915,nouveau,r300,r600,radeonsi,svga,swrast,virgl"))) + '("-Dgallium-drivers=nouveau,r300,r600,radeonsi,svga,swrast,virgl"))) ;; Enable various optional features. TODO: opencl requires libclc, ;; omx requires libomxil-bellagio - "--with-platforms=x11,drm,surfaceless,wayland" - "--enable-glx-tls" ;Thread Local Storage, improves performance - ;; "--enable-opencl" - ;; "--enable-omx" - "--enable-osmesa" - "--enable-xa" + "-Dplatforms=x11,drm,surfaceless,wayland" + "-Dglx=dri" ;Thread Local Storage, improves performance + ;; "-Dopencl=true" + ;; "-Domx=true" + "-Dosmesa=gallium" + "-Dgallium-xa=true" + ;; features required by wayland - "--enable-gles2" - "--enable-gbm" - "--enable-shared-glapi" - ;; Without floating point texture support, drivers such as Nouveau - ;; are stuck at OpenGL 2.1 instead of OpenGL 3.0+. - "--enable-texture-float" + "-Dgles2=true" + "-Dgbm=true" + "-Dshared-glapi=true" ;; Enable Vulkan on i686-linux and x86-64-linux. ,@(match (%current-system) ("x86_64-linux" - '("--with-vulkan-drivers=intel,radeon")) + '("-Dvulkan-drivers=intel,amd")) ;; TODO: Fix intel driver on i686-linux. ("i686-linux" - '("--with-vulkan-drivers=radeon")) + '("-Dvulkan-drivers=amd")) (_ - '(""))) + '("-Dvulkan-drivers=auto"))) ;; Also enable the tests. - "--enable-gallium-tests" + "-Dbuild-tests=true" ;; on non-intel systems, drop i915 and i965 ;; from the default dri drivers ,@(match (%current-system) ((or "x86_64-linux" "i686-linux") - '("--with-dri-drivers=i915,i965,nouveau,r200,radeon,swrast" - "--enable-llvm")) ; default is x86/x86_64 only + '("-Ddri-drivers=i915,i965,nouveau,r200,r100" + "-Dllvm=true")) ; default is x86/x86_64 only (_ - '("--with-dri-drivers=nouveau,r200,radeon,swrast")))) + '("-Ddri-drivers=nouveau,r200,r100")))) #:modules ((ice-9 match) (srfi srfi-1) (guix build utils) - (guix build gnu-build-system)) + (guix build meson-build-system)) #:phases (modify-phases %standard-phases (add-after @@ -331,7 +329,7 @@ also known as DXTn or DXTC) for Mesa.") (("/usr/bin/env python2") (which "python"))) #t)) (add-before - 'build 'fix-dlopen-libnames + 'configure 'fix-dlopen-libnames (lambda* (#:key inputs outputs #:allow-other-keys) (let ((out (assoc-ref outputs "out"))) ;; Remain agnostic to .so.X.Y.Z versions while doing @@ -460,14 +458,14 @@ glxgears, glxheads, and glxinfo.") (define-public glew (package (name "glew") - (version "2.0.0") + (version "2.1.0") (source (origin (method url-fetch) (uri (string-append "mirror://sourceforge/glew/glew/" version "/glew-" version ".tgz")) (sha256 (base32 - "0r37fg2s1f0jrvwh6c8cz5x6v4wqmhq42qm15cs9qs349q5c6wn5")) + "159wk5dc0ykjbxvag5i1m2mhp23zkk6ra04l26y3jc3nwvkr3ph4")) (modules '((guix build utils))) (snippet '(begin @@ -550,7 +548,7 @@ OpenGL graphics API.") (define-public libepoxy (package (name "libepoxy") - (version "1.5.2") + (version "1.5.3") (source (origin (method url-fetch) (uri (string-append @@ -558,10 +556,11 @@ OpenGL graphics API.") version "/libepoxy-" version ".tar.xz")) (sha256 (base32 - "1n57xj5i6giw4mp5s59w1m9bm33sd6gjg7r00dzzvcwya6326mm9")))) + "0ga3qjv50x37my6pw5xr14g5n6z78hy5s8s06kays8c3ab2mha80")))) (arguments `(#:phases (modify-phases %standard-phases + (delete 'bootstrap) (add-before 'configure 'patch-paths (lambda* (#:key inputs #:allow-other-keys) @@ -573,7 +572,7 @@ OpenGL graphics API.") (("libGL.so.1") (string-append mesa "/lib/libGL.so.1")) (("libEGL.so.1") (string-append mesa "/lib/libEGL.so.1"))) #t)))))) - (build-system gnu-build-system) + (build-system meson-build-system) (native-inputs `(("pkg-config" ,pkg-config) ("python" ,python))) @@ -725,25 +724,26 @@ mixed vector/bitmap output.") (define-public virtualgl (package (name "virtualgl") - (version "2.5.2") + (version "2.6.1") (source (origin - (method url-fetch) - (uri (string-append "https://github.com/VirtualGL/virtualgl/archive/" - version ".tar.gz")) - (file-name (string-append name "-" version ".tar.gz")) + (method git-fetch) + (uri (git-reference + (url "https://github.com/VirtualGL/virtualgl.git") + (commit version))) + (file-name (git-file-name name version)) (sha256 - (base32 - "0rnid3hwrry9d5d4m7sygq00xxx976rgk00a3557m9r5kxbmy476")))) + (base32 "04fdwm6mz76lw4iwd5m7yxjfhpa0rpxd357bv5smk5lclnlbz1bv")))) (arguments - `(#:tests? #f ;; no tests are available + `(#:tests? #f ; no tests are available #:configure-flags (list - (string-append "-DCMAKE_INSTALL_LIBDIR=" - (assoc-ref %outputs "out") "/lib") - "-DVGL_USESSL=1"))) ;; use OpenSSL + (string-append "-DCMAKE_INSTALL_LIBDIR=" + (assoc-ref %outputs "out") "/lib") + "-DVGL_USESSL=1"))) ; use OpenSSL (build-system cmake-build-system) (inputs `(("glu" ,glu) ("libjpeg-turbo" ,libjpeg-turbo) + ("libxtst" ,libxtst) ("mesa" ,mesa) ("openssl" ,openssl))) (native-inputs `(("pkg-config" ,pkg-config)))