diff mbox series

[bug#40426] v2, cleared

Message ID W_Z4zPusAWrA_7AUIbNoK5t8bCVrbT8LirM67y1WDezKif97jIrB8-7i3SWwuwGlhYlO2TnfMoeZ5E07aGGLt59JVhUpmMs0PLQ0WFp9HLE=@protonmail.com
State Accepted
Headers show
Series [bug#40426] v2, cleared | expand

Checks

Context Check Description
cbaines/comparison success View comparision
cbaines/git branch success View Git branch
cbaines/applying patch fail View Laminar job

Commit Message

ashish.is--- via Guix-patches" via April 15, 2020, 7:15 a.m. UTC
tests #t -- removed;
trying another desc.

Comments

Christopher Baines April 15, 2020, 12:22 p.m. UTC | #1
Vitaliy Shatrov via Guix-patches via <guix-patches@gnu.org> writes:

> tests #t -- removed;
> trying another desc.

Thanks, I've gone ahead and pushed this to master as
dfe277a5ce60d487fe44840506206fea8507bc69.

I moved the package definition up a bit in the file, just so its not at
the bottom, which can help to avoid merge conflicts.

I also used the synopsis/description from the initial patch, mostly to
avoid the lint warnings.

Thanks again,

Chris
diff mbox series

Patch

From a1eec269a63f78e370d945e5b065bcb8274b1eaa Mon Sep 17 00:00:00 2001
From: Vitaliy Shatrov <D0dyBo0D0dyBo0@protonmail.com>
Date: Wed, 15 Apr 2020 14:02:13 +0700
Subject: [PATCH] gnu: Add g-golf

* gnu/packages/guile-xyz.scm (g-golf): New variable
---
 gnu/packages/guile-xyz.scm | 77 ++++++++++++++++++++++++++++++++++++++
 1 file changed, 77 insertions(+)

diff --git a/gnu/packages/guile-xyz.scm b/gnu/packages/guile-xyz.scm
index e1fcc12229..61dae6be41 100644
--- a/gnu/packages/guile-xyz.scm
+++ b/gnu/packages/guile-xyz.scm
@@ -3271,3 +3271,80 @@  Relay Chat} (IRC).")
 WebSocket protocol as defined by RFC 6455.")
       (home-page "https://git.dthompson.us/guile-websocket.git")
       (license license:lgpl3+))))
+
+
+(define-public g-golf
+  (let ((commit "4a4edf25e4877df9182c77843bdd98ab59e13ef7"))
+    (package
+      (name "g-golf")
+      (version (git-version "1" "683" commit))
+      (source (origin
+                (method git-fetch)
+                (uri (git-reference
+                      (url "https://git.savannah.gnu.org/git/g-golf.git")
+                      (commit commit)))
+                (file-name (git-file-name name version))
+                (sha256
+                 (base32
+                  "09p0gf71wbmlm9kri693a8fvr9hl3hhlmlidyadwjdh7853xg0h8"))))
+      (build-system gnu-build-system)
+      (native-inputs
+       `(("autoconf" ,autoconf)
+         ("automake" ,automake)
+         ("texinfo" ,texinfo)
+         ("gettext" ,gettext-minimal)
+         ("libtool" ,libtool)
+         ("pkg-config" ,pkg-config)))
+      (inputs
+       `(("guile" ,guile-2.2)
+         ("guile-lib" ,guile-lib)
+         ("clutter" ,clutter)
+         ("gtk" ,gtk+)
+         ("glib" ,glib)))
+      (propagated-inputs
+       `(("gobject-introspection" ,gobject-introspection)))
+      (arguments
+       `(#:phases
+         (modify-phases %standard-phases
+           (add-before 'configure 'tests-work-arounds
+             (lambda* (#:key inputs #:allow-other-keys)
+               ;; In build environment, There is no /dev/tty
+               (substitute*
+                   "test-suite/tests/gobject.scm"
+                 (("/dev/tty") "/dev/null"))))
+           (add-before 'configure 'substitute-libs
+             (lambda* (#:key inputs outputs #:allow-other-keys)
+               (let* ((get (lambda (key lib)
+                             (string-append (assoc-ref inputs key) "/lib/" lib)))
+                      (libgi      (get "gobject-introspection" "libgirepository-1.0"))
+                      (libglib    (get "glib" "libglib-2.0"))
+                      (libgobject (get "glib" "libgobject-2.0"))
+                      (libgdk     (get "gtk" "libgdk-3")))
+                 (substitute* "configure"
+                   (("SITEDIR=\"\\$datadir/g-golf\"")
+                    "SITEDIR=\"$datadir/guile/site/$GUILE_EFFECTIVE_VERSION\"")
+                   (("SITECCACHEDIR=\"\\$libdir/g-golf/")
+                    "SITECCACHEDIR=\"$libdir/"))
+                 (substitute* "g-golf/init.scm"
+                   (("libgirepository-1.0") libgi)
+                   (("libglib-2.0") libglib)
+                   (("libgdk-3") libgdk)
+                   (("libgobject-2.0") libgobject)
+                   (("\\(dynamic-link \"libg-golf\"\\)")
+                    (format #f "~s"
+                            `(dynamic-link
+                              (format #f "~alibg-golf"
+                                      (if (getenv "GUILE_GGOLF_UNINSTALLED")
+                                          ""
+                                          ,(format #f "~a/lib/"
+                                                   (assoc-ref outputs "out"))))))))
+                 (setenv "GUILE_AUTO_COMPILE" "0")
+                 (setenv "GUILE_GGOLF_UNINSTALLED" "1")
+                 #t))))))
+      (home-page "https://www.gnu.org/software/g-golf/")
+      (synopsis "G-Golf is a Guile Object Library for GNOME")
+      (description "G-Golf low level API comprises a binding to - (most of) the
+GObject Introspection and (some of) the GObject and Glib libraries, as well as
+additional (G-Golf) utilities - used to import GObject libraries and build
+their corresponding G-Golf high level API.")
+      (license license:lgpl3+))))
-- 
2.26.0