gnu: python-pandas: Fix build on 32-bit.
[jackhill/guix/guix.git] / gnu / packages / gl.scm
index ee56998..a3862f1 100644 (file)
@@ -2,9 +2,10 @@
 ;;; Copyright © 2013, 2015 Andreas Enge <andreas@enge.fr>
 ;;; Copyright © 2013 Joshua Grant <tadni@riseup.net>
 ;;; Copyright © 2014, 2016 David Thompson <davet@gnu.org>
-;;; Copyright © 2014, 2015 Mark H Weaver <mhw@netris.org>
+;;; Copyright © 2014, 2015, 2016, 2017 Mark H Weaver <mhw@netris.org>
 ;;; Copyright © 2016 ng0 <ng0@we.make.ritual.n0.is>
 ;;; Copyright © 2016 Ricardo Wurmus <rekado@elephly.net>
+;;; Copyright © 2016 David Thompson <davet@gnu.org>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -22,6 +23,7 @@
 ;;; along with GNU Guix.  If not, see <http://www.gnu.org/licenses/>.
 
 (define-module (gnu packages gl)
+  #:use-module (gnu packages)
   #:use-module (gnu packages autotools)
   #:use-module (gnu packages bison)
   #:use-module (gnu packages documentation)
@@ -195,7 +197,7 @@ also known as DXTn or DXTC) for Mesa.")
 (define-public mesa
   (package
     (name "mesa")
-    (version "12.0.1")
+    (version "13.0.3")
     (source
       (origin
         (method url-fetch)
@@ -203,7 +205,9 @@ also known as DXTn or DXTC) for Mesa.")
                             version "/mesa-" version ".tar.xz"))
         (sha256
          (base32
-          "12b3i59xdn2in2hchrkgh4fwij8zhznibx976l3pdj3qkyvlzcms"))))
+          "03m4gc6qc50lb0ic06f83r3yl0x4lmj2zjq3sl60vl3nq7jqpanr"))
+        (patches
+         (search-patches "mesa-wayland-egl-symbols-check-mips.patch"))))
     (build-system gnu-build-system)
     (propagated-inputs
       `(("glproto" ,glproto)
@@ -226,7 +230,6 @@ also known as DXTn or DXTC) for Mesa.")
         ("makedepend" ,makedepend)
         ("presentproto" ,presentproto)
         ("s2tc" ,s2tc)
-        ("udev" ,eudev)
         ("wayland" ,wayland)))
     (native-inputs
       `(("pkg-config" ,pkg-config)
@@ -247,6 +250,9 @@ also known as DXTn or DXTC) for Mesa.")
          "--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"
 
          ;; on non-intel systems, drop i915 and i965
          ;; from the default dri drivers
@@ -268,7 +274,6 @@ also known as DXTn or DXTC) for Mesa.")
            'build 'fix-dlopen-libnames
            (lambda* (#:key inputs outputs #:allow-other-keys)
              (let ((s2tc (assoc-ref inputs "s2tc"))
-                   (udev (assoc-ref inputs "udev"))
                    (out (assoc-ref outputs "out")))
                ;; Remain agnostic to .so.X.Y.Z versions while doing
                ;; the substitutions so we're future-safe.
@@ -277,10 +282,6 @@ also known as DXTn or DXTC) for Mesa.")
                      "src/mesa/main/texcompress_s3tc.c")
                  (("\"libtxc_dxtn\\.so")
                   (string-append "\"" s2tc "/lib/libtxc_dxtn.so")))
-               (substitute* "src/loader/loader.c"
-                 (("udev_handle = dlopen\\(name")
-                  (string-append "udev_handle = dlopen(\""
-                                 udev "/lib/libudev.so\"")))
                (substitute* "src/glx/dri_common.c"
                  (("dlopen\\(\"libGL\\.so")
                   (string-append "dlopen(\"" out "/lib/libGL.so")))
@@ -465,7 +466,8 @@ OpenGL graphics API.")
               (file-name (string-append name "-" version ".tar.gz"))
               (sha256
                (base32
-                "1d1brhwfmlzgnphmdwlvn5wbcrxsdyzf1qfcf8nb89xqzznxs037"))))
+                "1d1brhwfmlzgnphmdwlvn5wbcrxsdyzf1qfcf8nb89xqzznxs037"))
+              (patches (search-patches "libepoxy-gl-null-checks.patch"))))
     (arguments
      `(#:phases
        (modify-phases %standard-phases
@@ -570,12 +572,15 @@ OpenGL.")
     (native-inputs
      `(("doxygen" ,doxygen)
        ("unzip" ,unzip)))
-    (inputs
-     `(("mesa" ,mesa)
+    (propagated-inputs
+     `(("mesa" ,mesa)                             ;included in public headers
+
+       ;; These are in 'Requires.private' of 'glfw3.pc'.
        ("libx11" ,libx11)
        ("libxrandr" ,libxrandr)
        ("libxinerama" ,libxinerama)
-       ("libxcursor" ,libxcursor)))
+       ("libxcursor" ,libxcursor)
+       ("libxxf86vm" ,libxxf86vm)))
     (home-page "http://www.glfw.org")
     (synopsis "OpenGL application development library")
     (description