guix-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

01/01: gnu: Add golly.


From: Kei Kebreau
Subject: 01/01: gnu: Add golly.
Date: Sun, 28 Jan 2018 19:00:03 -0500 (EST)

kkebreau pushed a commit to branch master
in repository guix.

commit 06f5f0b10a11f4cebc9996ca20580c1250f74cf7
Author: Kei Kebreau <address@hidden>
Date:   Fri Jan 19 22:53:50 2018 -0500

    gnu: Add golly.
    
    * gnu/packages/games.scm (golly): New variable.
---
 gnu/packages/games.scm | 90 +++++++++++++++++++++++++++++++++++++++++++++++++-
 1 file changed, 89 insertions(+), 1 deletion(-)

diff --git a/gnu/packages/games.scm b/gnu/packages/games.scm
index 6b80f74..7cf048e 100644
--- a/gnu/packages/games.scm
+++ b/gnu/packages/games.scm
@@ -19,7 +19,7 @@
 ;;; Copyright © 2016 Manolis Fragkiskos Ragkousis <address@hidden>
 ;;; Copyright © 2016, 2017 ng0 <address@hidden>
 ;;; Copyright © 2016 Albin Söderqvist <address@hidden>
-;;; Copyright © 2016, 2017 Kei Kebreau <address@hidden>
+;;; Copyright © 2016, 2017, 2018 Kei Kebreau <address@hidden>
 ;;; Copyright © 2016 Alex Griffin <address@hidden>
 ;;; Copyright © 2016, 2017 Efraim Flashner <address@hidden>
 ;;; Copyright © 2016 Jan Nieuwenhuizen <address@hidden>
@@ -363,6 +363,94 @@ played.  Freedoom complements the Doom engine with free 
levels, artwork, sound
 effects and music to make a completely free game.")
    (license license:bsd-3)))
 
+(define-public golly
+  (package
+    (name "golly")
+    (version "3.1")
+    (source (origin
+              (method url-fetch)
+              (uri (string-append "mirror://sourceforge/golly/golly-"
+                                  version "/golly-" version
+                                  "-src.tar.gz"))
+              (sha256
+               (base32
+                "0dn74k3rylhx023n047lz4z6qrqijfcxi0b6jryqklhmm2n532f7"))))
+    (build-system gnu-build-system)
+    (arguments
+     '(#:make-flags (list "CC=gcc"
+                          (string-append "GOLLYDIR="
+                                         (assoc-ref %outputs "out")
+                                         "/share/golly"))
+       #:tests? #f ; no check target
+       #:phases
+       (modify-phases %standard-phases
+         (replace 'configure
+           (lambda* (#:key inputs #:allow-other-keys)
+             ;; For some reason, setting the PYTHON_SHLIB make flag doesn't
+             ;; properly set the path to the Python shared library. This
+             ;; substitution acheives the same end by different means.
+             (substitute* "gui-wx/wxprefs.cpp"
+               (("pythonlib = wxT\\(STRINGIFY\\(PYTHON_SHLIB\\)\\)")
+                (string-append "pythonlib = \""
+                               (assoc-ref inputs "python")
+                               "/lib/libpython-2.7.so\"")))
+             #t))
+         (replace 'build
+           (lambda* (#:key make-flags outputs #:allow-other-keys)
+             (with-directory-excursion "gui-wx"
+               (apply invoke `("make" ,@make-flags "-f" "makefile-gtk")))))
+         (replace 'install
+           (lambda* (#:key outputs #:allow-other-keys)
+             (let* ((out (assoc-ref outputs "out"))
+                    (bin (string-append out "/bin"))
+                    (doc (string-append out "/share/doc/golly"))
+                    (pixmaps (string-append out "/share/pixmaps"))
+                    (share (string-append out "/share/golly")))
+               (for-each (lambda (binary)
+                           (install-file binary bin))
+                         '("bgolly" "golly"))
+               (for-each (lambda (document)
+                           (install-file
+                            (string-append "docs/" document ".html")
+                            doc))
+                         '("License" "ReadMe" "ToDo"))
+               (install-file "gui-wx/icons/appicon.xpm" pixmaps)
+               (for-each (lambda (folder)
+                           (copy-recursively
+                            folder
+                            (string-append share "/" folder)))
+                         '("Help" "Patterns" "Rules" "Scripts")))
+             #t)))))
+    (native-inputs
+     `(("lua" ,lua)))
+    (inputs
+     `(("glu" ,glu)
+       ("mesa" ,mesa)
+       ("python" ,python-2)
+       ("wxwidgets" ,wxwidgets-gtk2)
+       ("zlib" ,zlib)))
+    (home-page "http://golly.sourceforge.net/";)
+    (synopsis "Software for exploring cellular automata")
+    (description
+     "Golly simulates Conway's Game of Life and many other types of cellular
+automata.  The following features are available:
address@hidden
address@hidden Support for bounded and unbounded universes, with cells of up to 
256
+  states.
address@hidden Support for multiple algorithms, including Bill Gosper's Hashlife
+  algorithm.
address@hidden Loading patterns from BMP, PNG, GIF and TIFF image files.
address@hidden Reading RLE, macrocell, Life 1.05/1.06, dblife and MCell files.
address@hidden Scriptable via Lua or Python.
address@hidden Extracting patterns, rules and scripts from zip files.
address@hidden Downloading patterns, rules and scripts from online archives.
address@hidden Pasting patterns from the clipboard.
address@hidden Unlimited undo/redo.
address@hidden Configurable keyboard shortcuts.
address@hidden Auto fit option to keep patterns within the view.
address@hidden enumerate")
+    (license license:gpl2+)))
+
 (define-public meandmyshadow
   (package
     (name "meandmyshadow")



reply via email to

[Prev in Thread] Current Thread [Next in Thread]