guix: Update development environment to use Guile 2.9.1.
authorDavid Thompson <dthompson2@worcester.edu>
Thu, 25 Oct 2018 21:12:53 +0000 (17:12 -0400)
committerDavid Thompson <dthompson2@worcester.edu>
Thu, 25 Oct 2018 21:12:53 +0000 (17:12 -0400)
guix.scm

index 0439bcf..2b4995e 100644 (file)
--- a/guix.scm
+++ b/guix.scm
@@ -41,6 +41,7 @@
              (guix download)
              (guix git-download)
              (guix build-system gnu)
+             (guix utils)
              (gnu packages)
              (gnu packages autotools)
              (gnu packages pkg-config)
 (define (package-with-guile-2.2 p)
   (package-with-guile p guile-2.2.4))
 
+(define guile-opengl
+  (package
+    (inherit guile-opengl)
+    (inputs
+     (map (match-lambda
+            (("guile" _)
+             `("guile" ,guile-next))
+            (input input))
+          (package-inputs guile-opengl)))
+    (native-inputs
+     (append (package-native-inputs guile-opengl)
+             `(("autoconf" ,autoconf)
+               ("automake" ,automake))))
+    (arguments
+     (substitute-keyword-arguments (package-arguments guile-opengl)
+       ((#:phases phases)
+        `(modify-phases ,phases
+           (delete 'patch-makefile)
+           (add-before 'bootstrap 'patch-configure.ac
+             (lambda _
+               ;; The Guile version check doesn't work for the 3.0
+               ;; pre-release, so just remove it.
+               (substitute* "configure.ac"
+                 (("GUILE_PKG\\(\\[2.2 2.0\\]\\)") ""))
+               (substitute* "Makefile.am"
+                 (("\\$\\(GUILE_EFFECTIVE_VERSION\\)") "3.0")
+                 (("ccache") "site-ccache"))
+               #t))
+           (replace 'bootstrap
+             (lambda _
+               (invoke "autoreconf" "-vfi")))))))))
+
 (define guile-sdl2
-  (let ((commit "5a6ea82c9ad859972c01d2908b2f66fb3addcfbb"))
+  (let ((commit "d0f9c26dce6e23533c23e401f604d712b43d4420"))
     (package
       (name "guile-sdl2")
-      (version (string-append "0.2.0-1." (string-take commit 7)))
+      (version (string-append "0.3.1-1." (string-take commit 7)))
       (source (origin
                 (method git-fetch)
                 (uri (git-reference
                       (commit commit)))
                 (sha256
                  (base32
-                  "1gc8f24l2y939a673kix0jd0kqr4zgwr8kd5qy60czqbqbjqrn96"))))
+                  "183r50bsf317f4iclsdw4ag83s915nymvadh3izw04iv7fm8xbwj"))))
       (build-system gnu-build-system)
       (arguments
        '(#:configure-flags
          ("pkg-config" ,pkg-config)
          ("texinfo" ,texinfo)))
       (inputs
-       `(("guile" ,guile-2.2.4)
+       `(("guile" ,guile-next)
          ("sdl2" ,sdl2)
          ("sdl2-image" ,sdl2-image)
          ("sdl2-mixer" ,sdl2-mixer)
@@ -122,9 +155,9 @@ SDL2 C shared library via the foreign function interface.")
      ("pkg-config" ,pkg-config)
      ("texinfo" ,texinfo)))
   (inputs
-   `(("guile" ,guile-2.2.4)))
+   `(("guile" ,guile-next)))
   (propagated-inputs
-   `(("guile-opengl" ,(package-with-guile-2.2 guile-opengl))
+   `(("guile-opengl" ,guile-opengl)
      ("guile-sdl2" ,guile-sdl2)))
   (synopsis "Game development toolkit for Guile Scheme")
   (description "Chickadee is a game development toolkit for Guile