unofficial mirror of guix-patches@gnu.org 
 help / color / mirror / code / Atom feed
* [bug#65149] [PATCH 0/4] Add sbcl-cl-gtk4.
@ 2023-08-08 13:47 ykonai via Guix-patches via
  2023-08-08 13:52 ` [bug#65149] [PATCH 1/4] gnu: sbcl-cl-gobject-introspection: Update to 0.3-2.c4fef07 ykonai via Guix-patches via
                   ` (2 more replies)
  0 siblings, 3 replies; 12+ messages in thread
From: ykonai via Guix-patches via @ 2023-08-08 13:47 UTC (permalink / raw)
  To: 65149

Hello guix-patches,

This patch adds the Common Lisp GTK4 bindings. I tested them on SBCL x64, and
modulo the apparent dbus requirement it seems to work. ECL version of the
cl-gtk4 package is not included because I didn't manage to build it (either it
doesn't build or takes more than an hour to build on my computer (compared to
about ~10s for SBCL)).

ykonai (4):
  gnu: sbcl-cl-gobject-introspection: Update to 0.3-2.c4fef07
  gnu: Add sbcl-cl-gobject-introspection-wrapper.
  gnu: Add sbcl-cl-glib.
  gnu: Add sbcl-cl-gtk4.

 gnu/packages/lisp-xyz.scm | 167 ++++++++++++++++++++++++++++++--------
 1 file changed, 135 insertions(+), 32 deletions(-)


base-commit: d43b53c476b4e9322b31274b788e851d37e72302
-- 
2.41.0





^ permalink raw reply	[flat|nested] 12+ messages in thread

* [bug#65149] [PATCH 1/4] gnu: sbcl-cl-gobject-introspection: Update to 0.3-2.c4fef07
  2023-08-08 13:47 [bug#65149] [PATCH 0/4] Add sbcl-cl-gtk4 ykonai via Guix-patches via
@ 2023-08-08 13:52 ` ykonai via Guix-patches via
  2023-08-08 13:52   ` [bug#65149] [PATCH 2/4] gnu: Add sbcl-cl-gobject-introspection-wrapper ykonai via Guix-patches via
                     ` (2 more replies)
  2023-08-15 19:49 ` [bug#65149] [PATCH v2 1/4] gnu: sbcl-cl-gobject-introspection: Update to 0.3-2.c4fef07 ykonai via Guix-patches via
  2023-08-18 11:46 ` bug#65149: [PATCH 0/4] " Guillaume Le Vaillant
  2 siblings, 3 replies; 12+ messages in thread
From: ykonai via Guix-patches via @ 2023-08-08 13:52 UTC (permalink / raw)
  To: 65149

* gnu/packages/lisp.xyz (sbcl-cl-gobject-introspection): Update to 0.3-2.c4fef07
---
 gnu/packages/lisp-xyz.scm | 60 ++++++++++++++++++---------------------
 1 file changed, 28 insertions(+), 32 deletions(-)

diff --git a/gnu/packages/lisp-xyz.scm b/gnu/packages/lisp-xyz.scm
index d2596ebc2d..0f66ba961e 100644
--- a/gnu/packages/lisp-xyz.scm
+++ b/gnu/packages/lisp-xyz.scm
@@ -9556,43 +9556,39 @@ (define-public cl-specialization-store
   (sbcl-package->cl-source-package sbcl-specialization-store))
 
 (define-public sbcl-cl-gobject-introspection
-  (let ((commit "d0136c8d9ade2560123af1fc55bbf70d2e3db539")
-        (revision "1"))
+  (let ((commit "c4fef07d01cec7c830ce84ef150ed8e4da5959c4")
+        (revision "2"))
     (package
       (name "sbcl-cl-gobject-introspection")
       (version (git-version "0.3" revision commit))
       (home-page "https://github.com/andy128k/cl-gobject-introspection")
-      (source
-       (origin
-         (method git-fetch)
-         (uri (git-reference
-               (url home-page)
-               (commit commit)))
-         (file-name (git-file-name name version))
-         (sha256
-          (base32
-           "0dz0r73pq7yhz2iq2jnkq977awx2zws2qfxdcy33329sys1ii32p"))))
-      (build-system asdf-build-system/sbcl)
-      (inputs
-       `(("alexandria" ,sbcl-alexandria)
-         ("cffi" ,sbcl-cffi)
-         ("iterate" ,sbcl-iterate)
-         ("trivial-garbage" ,sbcl-trivial-garbage)
-         ("glib" ,glib)
-         ("gobject-introspection" ,gobject-introspection)))
-      (native-inputs
-       (list sbcl-fiveam))
+      (source (origin
+                (method git-fetch)
+                (uri (git-reference
+                      (url home-page)
+                      (commit commit)))
+                (file-name (git-file-name name version))
+                (sha256
+                 (base32
+                  "18n4wg93sf6cjmpcpr47bg2rd8mbm9ml9lykmjsxgvsf3nwr5vnw"))))
+      (build-system asdf-build-system/sbcl)
+      (inputs `(("alexandria" ,sbcl-alexandria)
+                ("cffi" ,sbcl-cffi)
+                ("iterate" ,sbcl-iterate)
+                ("trivial-garbage" ,sbcl-trivial-garbage)
+                ("glib" ,glib)
+                ("gobject-introspection" ,gobject-introspection)))
+      (native-inputs (list sbcl-fiveam))
       (arguments
-       '(#:phases
-         (modify-phases %standard-phases
-           (add-after 'unpack 'fix-paths
-             (lambda* (#:key inputs #:allow-other-keys)
-               (substitute* "src/init.lisp"
-                 (("libgobject-2\\.0\\.so")
-                  (search-input-file inputs "/lib/libgobject-2.0.so"))
-                 (("libgirepository-1\\.0\\.so")
-                  (search-input-file inputs
-                                     "/lib/libgirepository-1.0.so"))))))))
+       '(#:phases (modify-phases %standard-phases
+                    (add-after 'unpack 'fix-paths
+                      (lambda* (#:key inputs #:allow-other-keys)
+                        (substitute* "src/init.lisp"
+                          (("libgobject-2\\.0\\.so")
+                           (search-input-file inputs "/lib/libgobject-2.0.so"))
+                          (("libgirepository-1\\.0\\.so")
+                           (search-input-file inputs
+                                              "/lib/libgirepository-1.0.so"))))))))
       (synopsis "Common Lisp bindings to GObject Introspection")
       (description
        "This library is a bridge between Common Lisp and GObject
-- 
2.41.0





^ permalink raw reply related	[flat|nested] 12+ messages in thread

* [bug#65149] [PATCH 2/4] gnu: Add sbcl-cl-gobject-introspection-wrapper.
  2023-08-08 13:52 ` [bug#65149] [PATCH 1/4] gnu: sbcl-cl-gobject-introspection: Update to 0.3-2.c4fef07 ykonai via Guix-patches via
@ 2023-08-08 13:52   ` ykonai via Guix-patches via
  2023-08-08 13:52   ` [bug#65149] [PATCH 3/4] gnu: Add sbcl-cl-glib ykonai via Guix-patches via
  2023-08-08 13:52   ` [bug#65149] [PATCH 4/4] gnu: Add sbcl-cl-gtk4 ykonai via Guix-patches via
  2 siblings, 0 replies; 12+ messages in thread
From: ykonai via Guix-patches via @ 2023-08-08 13:52 UTC (permalink / raw)
  To: 65149

* gnu/packages/lisp-xyz.scm (sbcl-cl-gobject-introspection-wrapper,
cl-gobject-introspection-wrapper, ecl-cl-gobject-introspection-wrapper): New variables.
---
 gnu/packages/lisp-xyz.scm | 37 +++++++++++++++++++++++++++++++++++++
 1 file changed, 37 insertions(+)

diff --git a/gnu/packages/lisp-xyz.scm b/gnu/packages/lisp-xyz.scm
index 0f66ba961e..f35b363113 100644
--- a/gnu/packages/lisp-xyz.scm
+++ b/gnu/packages/lisp-xyz.scm
@@ -9604,6 +9604,43 @@ (define-public cl-gobject-introspection
 (define-public ecl-cl-gobject-introspection
   (sbcl-package->ecl-package sbcl-cl-gobject-introspection))
 
+(define-public sbcl-cl-gobject-introspection-wrapper
+  (let ((commit "2d197cba7e7d734ac8a2e181e5e709e5b218bada")
+        (revision "1"))
+    (package
+      (name "sbcl-cl-gobject-introspection-wrapper")
+      (version (git-version "1.0.0" revision commit))
+      (source (origin
+                (method git-fetch)
+                (uri (git-reference
+                      (url
+                       "https://github.com/bohonghuang/cl-gobject-introspection-wrapper")
+                      (commit commit)))
+                (file-name (git-file-name "cl-gobject-introspection-wrapper"
+                                          version))
+                (sha256
+                 (base32
+                  "05np2zs5806ib6qfz7d6knyaz6llxgwvjqavl1fsz5hcga40296s"))))
+      (build-system asdf-build-system/sbcl)
+      (inputs
+       (list sbcl-cl-ppcre
+             sbcl-alexandria
+             sbcl-cl-gobject-introspection))
+      (home-page
+       "https://github.com/bohonghuang/cl-gobject-introspection-wrapper")
+      (synopsis
+       "Wrap and call GObject Introspection FFI function in Common Lisp")
+      (description
+       "This library converts the elements from GObject Introspection into
+Common Lisp-style definitions, based on cl-gobject-introspection.")
+      (license license:lgpl3))))
+
+(define-public cl-gobject-introspection-wrapper
+  (sbcl-package->cl-source-package sbcl-cl-gobject-introspection-wrapper))
+
+(define-public ecl-cl-gobject-introspection-wrapper
+  (sbcl-package->ecl-package sbcl-cl-gobject-introspection-wrapper))
+
 (define-public sbcl-cl-slug
   (let ((commit "ffb229d10f0d3f7f54e706791725225e200bf749")
         (revision "1"))
-- 
2.41.0





^ permalink raw reply related	[flat|nested] 12+ messages in thread

* [bug#65149] [PATCH 3/4] gnu: Add sbcl-cl-glib.
  2023-08-08 13:52 ` [bug#65149] [PATCH 1/4] gnu: sbcl-cl-gobject-introspection: Update to 0.3-2.c4fef07 ykonai via Guix-patches via
  2023-08-08 13:52   ` [bug#65149] [PATCH 2/4] gnu: Add sbcl-cl-gobject-introspection-wrapper ykonai via Guix-patches via
@ 2023-08-08 13:52   ` ykonai via Guix-patches via
  2023-08-08 13:52   ` [bug#65149] [PATCH 4/4] gnu: Add sbcl-cl-gtk4 ykonai via Guix-patches via
  2 siblings, 0 replies; 12+ messages in thread
From: ykonai via Guix-patches via @ 2023-08-08 13:52 UTC (permalink / raw)
  To: 65149

* gnu/packages/lisp-xyz.scm (sbcl-cl-glib. cl-glib. ecl-cl-glib): New variables.
---
 gnu/packages/lisp-xyz.scm | 36 ++++++++++++++++++++++++++++++++++++
 1 file changed, 36 insertions(+)

diff --git a/gnu/packages/lisp-xyz.scm b/gnu/packages/lisp-xyz.scm
index f35b363113..58370e0c91 100644
--- a/gnu/packages/lisp-xyz.scm
+++ b/gnu/packages/lisp-xyz.scm
@@ -9641,6 +9641,42 @@ (define-public cl-gobject-introspection-wrapper
 (define-public ecl-cl-gobject-introspection-wrapper
   (sbcl-package->ecl-package sbcl-cl-gobject-introspection-wrapper))
 
+(define-public sbcl-cl-glib
+  (let ((commit "9e52827cce1cbb3962536b6a5e628febab593f57")
+        (revision "1"))
+    (package
+      (name "sbcl-cl-glib")
+      (version (git-version "1.0.0" revision commit))
+      (source
+       (origin
+         (method git-fetch)
+         (uri (git-reference
+               (url "https://github.com/bohonghuang/cl-glib")
+               (commit commit)))
+         (file-name (git-file-name "cl-glib" version))
+         (sha256
+          (base32 "0dxa493zdp1p93cahhpp3yaggn3j3kkn90mdw99g4ld7scmiglp4" ))))
+      (build-system asdf-build-system/sbcl)
+      (arguments
+       '(#:asd-systems '("cl-gio" "cl-glib" "cl-gobject")))
+      (propagated-inputs
+       (list glib))
+      (inputs
+       (list gobject-introspection
+             sbcl-cl-gobject-introspection-wrapper
+             sbcl-bordeaux-threads))
+      (home-page "https://github.com/bohonghuang/cl-glib")
+      (synopsis "Glib, GIO, Gobject bindings for Common Lisp")
+      (description "Provides Glib, GIO, Gobject bindings for Common Lisp via Gobject
+Introspection.")
+      (license license:lgpl3))))
+
+(define-public cl-glib
+  (sbcl-package->cl-source-package sbcl-cl-glib))
+
+(define-public ecl-cl-glib
+  (sbcl-package->ecl-package sbcl-cl-glib))
+
 (define-public sbcl-cl-slug
   (let ((commit "ffb229d10f0d3f7f54e706791725225e200bf749")
         (revision "1"))
-- 
2.41.0





^ permalink raw reply related	[flat|nested] 12+ messages in thread

* [bug#65149] [PATCH 4/4] gnu: Add sbcl-cl-gtk4.
  2023-08-08 13:52 ` [bug#65149] [PATCH 1/4] gnu: sbcl-cl-gobject-introspection: Update to 0.3-2.c4fef07 ykonai via Guix-patches via
  2023-08-08 13:52   ` [bug#65149] [PATCH 2/4] gnu: Add sbcl-cl-gobject-introspection-wrapper ykonai via Guix-patches via
  2023-08-08 13:52   ` [bug#65149] [PATCH 3/4] gnu: Add sbcl-cl-glib ykonai via Guix-patches via
@ 2023-08-08 13:52   ` ykonai via Guix-patches via
  2023-08-10 12:00     ` Guillaume Le Vaillant
  2 siblings, 1 reply; 12+ messages in thread
From: ykonai via Guix-patches via @ 2023-08-08 13:52 UTC (permalink / raw)
  To: 65149

* gnu/packages/lisp-xyz.scm (sbcl-cl-gtk4, cl-gtk4): New variables.
---
 gnu/packages/lisp-xyz.scm | 34 ++++++++++++++++++++++++++++++++++
 1 file changed, 34 insertions(+)

diff --git a/gnu/packages/lisp-xyz.scm b/gnu/packages/lisp-xyz.scm
index 58370e0c91..e35c0d6d8c 100644
--- a/gnu/packages/lisp-xyz.scm
+++ b/gnu/packages/lisp-xyz.scm
@@ -9677,6 +9677,40 @@ (define-public cl-glib
 (define-public ecl-cl-glib
   (sbcl-package->ecl-package sbcl-cl-glib))
 
+(define-public sbcl-cl-gtk4
+  (let ((commit "d116905e7b68508d03681a50b3b24d63e7b111e4")
+        (revision "1"))
+    (package
+      (name "sbcl-cl-gtk4")
+      (version (git-version "1.0.0" revision commit))
+      (source (origin
+                (method git-fetch)
+                (uri (git-reference
+                      (url "https://github.com/bohonghuang/cl-gtk4")
+                      (commit commit)))
+                (file-name (git-file-name "cl-gtk4" version))
+                (sha256
+                 (base32
+                  "0mprmmvbagnflvhynn51l42nbwr08rld99ls0c48m5lpjn0ja4zc"))))
+      (build-system asdf-build-system/sbcl)
+      (arguments
+       '(#:asd-systems '("cl-gtk4" "cl-gdk4")))
+      ;; propagate because it at least requires the typelib files at runtime
+      (propagated-inputs (list gtk))
+      (inputs
+       (list gobject-introspection
+             sbcl-cl-glib
+             sbcl-cl-gobject-introspection-wrapper))
+      (home-page "https://github.com/bohonghuang/cl-gtk4")
+      (synopsis "GTK4 bindings for Common Lisp")
+      (description
+       "Provides GTK4 bindings for Common Lisp via Gobject Introspection, in the
+cl-gtk4 ASDF system.")
+      (license license:lgpl3))))
+
+(define-public cl-gtk4
+  (sbcl-package->cl-source-package sbcl-cl-gtk4))
+
 (define-public sbcl-cl-slug
   (let ((commit "ffb229d10f0d3f7f54e706791725225e200bf749")
         (revision "1"))
-- 
2.41.0





^ permalink raw reply related	[flat|nested] 12+ messages in thread

* [bug#65149] [PATCH 4/4] gnu: Add sbcl-cl-gtk4.
  2023-08-08 13:52   ` [bug#65149] [PATCH 4/4] gnu: Add sbcl-cl-gtk4 ykonai via Guix-patches via
@ 2023-08-10 12:00     ` Guillaume Le Vaillant
  2023-08-10 22:15       ` ykonai via Guix-patches via
  0 siblings, 1 reply; 12+ messages in thread
From: Guillaume Le Vaillant @ 2023-08-10 12:00 UTC (permalink / raw)
  To: ykonai; +Cc: 65149

[-- Attachment #1: Type: text/plain, Size: 561 bytes --]

ykonai via Guix-patches via <guix-patches@gnu.org> skribis:

> * gnu/packages/lisp-xyz.scm (sbcl-cl-gtk4, cl-gtk4): New variables.
> [...]
> +      ;; propagate because it at least requires the typelib files at runtime
> +      (propagated-inputs (list gtk))
> +      (inputs
> +       (list gobject-introspection
> +             sbcl-cl-glib
> +             sbcl-cl-gobject-introspection-wrapper))
> [...]

Hi.
Instead of propagating Gtk, have your checked if having the
GI_TYPELIB_PATH environment variable set at runtime could be enough to
make things work?

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 247 bytes --]

^ permalink raw reply	[flat|nested] 12+ messages in thread

* [bug#65149] [PATCH 4/4] gnu: Add sbcl-cl-gtk4.
  2023-08-10 12:00     ` Guillaume Le Vaillant
@ 2023-08-10 22:15       ` ykonai via Guix-patches via
  0 siblings, 0 replies; 12+ messages in thread
From: ykonai via Guix-patches via @ 2023-08-10 22:15 UTC (permalink / raw)
  To: Guillaume Le Vaillant; +Cc: 65149


Guillaume Le Vaillant <glv@posteo.net> writes:
> Instead of propagating Gtk, have your checked if having the
> GI_TYPELIB_PATH environment variable set at runtime could be enough to
> make things work?


That does look like it works. I assume the best way would be to set the
search-paths of the package (which unfortunately seems to involve
copying the typelib files)?

I'll try to send a v2 patch once I get it to work.




^ permalink raw reply	[flat|nested] 12+ messages in thread

* [bug#65149] [PATCH v2 1/4] gnu: sbcl-cl-gobject-introspection: Update to 0.3-2.c4fef07
  2023-08-08 13:47 [bug#65149] [PATCH 0/4] Add sbcl-cl-gtk4 ykonai via Guix-patches via
  2023-08-08 13:52 ` [bug#65149] [PATCH 1/4] gnu: sbcl-cl-gobject-introspection: Update to 0.3-2.c4fef07 ykonai via Guix-patches via
@ 2023-08-15 19:49 ` ykonai via Guix-patches via
  2023-08-15 19:49   ` [bug#65149] [PATCH v2 2/4] gnu: Add sbcl-cl-gobject-introspection-wrapper ykonai via Guix-patches via
                     ` (2 more replies)
  2023-08-18 11:46 ` bug#65149: [PATCH 0/4] " Guillaume Le Vaillant
  2 siblings, 3 replies; 12+ messages in thread
From: ykonai via Guix-patches via @ 2023-08-15 19:49 UTC (permalink / raw)
  To: 65149

* gnu/packages/lisp.xyz (sbcl-cl-gobject-introspection): Update to 0.3-2.c4fef07
---
 gnu/packages/lisp-xyz.scm | 60 ++++++++++++++++++---------------------
 1 file changed, 28 insertions(+), 32 deletions(-)

diff --git a/gnu/packages/lisp-xyz.scm b/gnu/packages/lisp-xyz.scm
index d2596ebc2d..0f66ba961e 100644
--- a/gnu/packages/lisp-xyz.scm
+++ b/gnu/packages/lisp-xyz.scm
@@ -9556,43 +9556,39 @@ (define-public cl-specialization-store
   (sbcl-package->cl-source-package sbcl-specialization-store))
 
 (define-public sbcl-cl-gobject-introspection
-  (let ((commit "d0136c8d9ade2560123af1fc55bbf70d2e3db539")
-        (revision "1"))
+  (let ((commit "c4fef07d01cec7c830ce84ef150ed8e4da5959c4")
+        (revision "2"))
     (package
       (name "sbcl-cl-gobject-introspection")
       (version (git-version "0.3" revision commit))
       (home-page "https://github.com/andy128k/cl-gobject-introspection")
-      (source
-       (origin
-         (method git-fetch)
-         (uri (git-reference
-               (url home-page)
-               (commit commit)))
-         (file-name (git-file-name name version))
-         (sha256
-          (base32
-           "0dz0r73pq7yhz2iq2jnkq977awx2zws2qfxdcy33329sys1ii32p"))))
-      (build-system asdf-build-system/sbcl)
-      (inputs
-       `(("alexandria" ,sbcl-alexandria)
-         ("cffi" ,sbcl-cffi)
-         ("iterate" ,sbcl-iterate)
-         ("trivial-garbage" ,sbcl-trivial-garbage)
-         ("glib" ,glib)
-         ("gobject-introspection" ,gobject-introspection)))
-      (native-inputs
-       (list sbcl-fiveam))
+      (source (origin
+                (method git-fetch)
+                (uri (git-reference
+                      (url home-page)
+                      (commit commit)))
+                (file-name (git-file-name name version))
+                (sha256
+                 (base32
+                  "18n4wg93sf6cjmpcpr47bg2rd8mbm9ml9lykmjsxgvsf3nwr5vnw"))))
+      (build-system asdf-build-system/sbcl)
+      (inputs `(("alexandria" ,sbcl-alexandria)
+                ("cffi" ,sbcl-cffi)
+                ("iterate" ,sbcl-iterate)
+                ("trivial-garbage" ,sbcl-trivial-garbage)
+                ("glib" ,glib)
+                ("gobject-introspection" ,gobject-introspection)))
+      (native-inputs (list sbcl-fiveam))
       (arguments
-       '(#:phases
-         (modify-phases %standard-phases
-           (add-after 'unpack 'fix-paths
-             (lambda* (#:key inputs #:allow-other-keys)
-               (substitute* "src/init.lisp"
-                 (("libgobject-2\\.0\\.so")
-                  (search-input-file inputs "/lib/libgobject-2.0.so"))
-                 (("libgirepository-1\\.0\\.so")
-                  (search-input-file inputs
-                                     "/lib/libgirepository-1.0.so"))))))))
+       '(#:phases (modify-phases %standard-phases
+                    (add-after 'unpack 'fix-paths
+                      (lambda* (#:key inputs #:allow-other-keys)
+                        (substitute* "src/init.lisp"
+                          (("libgobject-2\\.0\\.so")
+                           (search-input-file inputs "/lib/libgobject-2.0.so"))
+                          (("libgirepository-1\\.0\\.so")
+                           (search-input-file inputs
+                                              "/lib/libgirepository-1.0.so"))))))))
       (synopsis "Common Lisp bindings to GObject Introspection")
       (description
        "This library is a bridge between Common Lisp and GObject

base-commit: d43b53c476b4e9322b31274b788e851d37e72302
-- 
2.41.0





^ permalink raw reply related	[flat|nested] 12+ messages in thread

* [bug#65149] [PATCH v2 2/4] gnu: Add sbcl-cl-gobject-introspection-wrapper.
  2023-08-15 19:49 ` [bug#65149] [PATCH v2 1/4] gnu: sbcl-cl-gobject-introspection: Update to 0.3-2.c4fef07 ykonai via Guix-patches via
@ 2023-08-15 19:49   ` ykonai via Guix-patches via
  2023-08-15 19:49   ` [bug#65149] [PATCH v2 3/4] gnu: Add sbcl-cl-glib ykonai via Guix-patches via
  2023-08-15 19:49   ` [bug#65149] [PATCH v2 4/4] gnu: Add sbcl-cl-gtk4 ykonai via Guix-patches via
  2 siblings, 0 replies; 12+ messages in thread
From: ykonai via Guix-patches via @ 2023-08-15 19:49 UTC (permalink / raw)
  To: 65149

* gnu/packages/lisp-xyz.scm (sbcl-cl-gobject-introspection-wrapper,
cl-gobject-introspection-wrapper, ecl-cl-gobject-introspection-wrapper): New variables.
---
 gnu/packages/lisp-xyz.scm | 37 +++++++++++++++++++++++++++++++++++++
 1 file changed, 37 insertions(+)

diff --git a/gnu/packages/lisp-xyz.scm b/gnu/packages/lisp-xyz.scm
index 0f66ba961e..f35b363113 100644
--- a/gnu/packages/lisp-xyz.scm
+++ b/gnu/packages/lisp-xyz.scm
@@ -9604,6 +9604,43 @@ (define-public cl-gobject-introspection
 (define-public ecl-cl-gobject-introspection
   (sbcl-package->ecl-package sbcl-cl-gobject-introspection))
 
+(define-public sbcl-cl-gobject-introspection-wrapper
+  (let ((commit "2d197cba7e7d734ac8a2e181e5e709e5b218bada")
+        (revision "1"))
+    (package
+      (name "sbcl-cl-gobject-introspection-wrapper")
+      (version (git-version "1.0.0" revision commit))
+      (source (origin
+                (method git-fetch)
+                (uri (git-reference
+                      (url
+                       "https://github.com/bohonghuang/cl-gobject-introspection-wrapper")
+                      (commit commit)))
+                (file-name (git-file-name "cl-gobject-introspection-wrapper"
+                                          version))
+                (sha256
+                 (base32
+                  "05np2zs5806ib6qfz7d6knyaz6llxgwvjqavl1fsz5hcga40296s"))))
+      (build-system asdf-build-system/sbcl)
+      (inputs
+       (list sbcl-cl-ppcre
+             sbcl-alexandria
+             sbcl-cl-gobject-introspection))
+      (home-page
+       "https://github.com/bohonghuang/cl-gobject-introspection-wrapper")
+      (synopsis
+       "Wrap and call GObject Introspection FFI function in Common Lisp")
+      (description
+       "This library converts the elements from GObject Introspection into
+Common Lisp-style definitions, based on cl-gobject-introspection.")
+      (license license:lgpl3))))
+
+(define-public cl-gobject-introspection-wrapper
+  (sbcl-package->cl-source-package sbcl-cl-gobject-introspection-wrapper))
+
+(define-public ecl-cl-gobject-introspection-wrapper
+  (sbcl-package->ecl-package sbcl-cl-gobject-introspection-wrapper))
+
 (define-public sbcl-cl-slug
   (let ((commit "ffb229d10f0d3f7f54e706791725225e200bf749")
         (revision "1"))
-- 
2.41.0





^ permalink raw reply related	[flat|nested] 12+ messages in thread

* [bug#65149] [PATCH v2 3/4] gnu: Add sbcl-cl-glib.
  2023-08-15 19:49 ` [bug#65149] [PATCH v2 1/4] gnu: sbcl-cl-gobject-introspection: Update to 0.3-2.c4fef07 ykonai via Guix-patches via
  2023-08-15 19:49   ` [bug#65149] [PATCH v2 2/4] gnu: Add sbcl-cl-gobject-introspection-wrapper ykonai via Guix-patches via
@ 2023-08-15 19:49   ` ykonai via Guix-patches via
  2023-08-15 19:49   ` [bug#65149] [PATCH v2 4/4] gnu: Add sbcl-cl-gtk4 ykonai via Guix-patches via
  2 siblings, 0 replies; 12+ messages in thread
From: ykonai via Guix-patches via @ 2023-08-15 19:49 UTC (permalink / raw)
  To: 65149

* gnu/packages/lisp-xyz.scm (sbcl-cl-glib, cl-glib, ecl-cl-glib): New variables.
---
 gnu/packages/lisp-xyz.scm | 36 ++++++++++++++++++++++++++++++++++++
 1 file changed, 36 insertions(+)

diff --git a/gnu/packages/lisp-xyz.scm b/gnu/packages/lisp-xyz.scm
index f35b363113..2a47a21b65 100644
--- a/gnu/packages/lisp-xyz.scm
+++ b/gnu/packages/lisp-xyz.scm
@@ -9641,6 +9641,42 @@ (define-public cl-gobject-introspection-wrapper
 (define-public ecl-cl-gobject-introspection-wrapper
   (sbcl-package->ecl-package sbcl-cl-gobject-introspection-wrapper))
 
+(define-public sbcl-cl-glib
+  (let ((commit "9e52827cce1cbb3962536b6a5e628febab593f57")
+        (revision "1"))
+    (package
+      (name "sbcl-cl-glib")
+      (version (git-version "1.0.0" revision commit))
+      (source
+       (origin
+         (method git-fetch)
+         (uri (git-reference
+               (url "https://github.com/bohonghuang/cl-glib")
+               (commit commit)))
+         (file-name (git-file-name "cl-glib" version))
+         (sha256
+          (base32 "0dxa493zdp1p93cahhpp3yaggn3j3kkn90mdw99g4ld7scmiglp4" ))))
+      (build-system asdf-build-system/sbcl)
+      (arguments
+       '(#:asd-systems '("cl-gio" "cl-glib" "cl-gobject")))
+      (inputs
+       (list
+        glib
+        gobject-introspection
+        sbcl-cl-gobject-introspection-wrapper
+        sbcl-bordeaux-threads))
+      (home-page "https://github.com/bohonghuang/cl-glib")
+      (synopsis "Glib, GIO, Gobject bindings for Common Lisp")
+      (description "Provides Glib, GIO, Gobject bindings for Common Lisp via Gobject
+Introspection.")
+      (license license:lgpl3))))
+
+(define-public cl-glib
+  (sbcl-package->cl-source-package sbcl-cl-glib))
+
+(define-public ecl-cl-glib
+  (sbcl-package->ecl-package sbcl-cl-glib))
+
 (define-public sbcl-cl-slug
   (let ((commit "ffb229d10f0d3f7f54e706791725225e200bf749")
         (revision "1"))
-- 
2.41.0





^ permalink raw reply related	[flat|nested] 12+ messages in thread

* [bug#65149] [PATCH v2 4/4] gnu: Add sbcl-cl-gtk4.
  2023-08-15 19:49 ` [bug#65149] [PATCH v2 1/4] gnu: sbcl-cl-gobject-introspection: Update to 0.3-2.c4fef07 ykonai via Guix-patches via
  2023-08-15 19:49   ` [bug#65149] [PATCH v2 2/4] gnu: Add sbcl-cl-gobject-introspection-wrapper ykonai via Guix-patches via
  2023-08-15 19:49   ` [bug#65149] [PATCH v2 3/4] gnu: Add sbcl-cl-glib ykonai via Guix-patches via
@ 2023-08-15 19:49   ` ykonai via Guix-patches via
  2 siblings, 0 replies; 12+ messages in thread
From: ykonai via Guix-patches via @ 2023-08-15 19:49 UTC (permalink / raw)
  To: 65149

* gnu/packages/lisp-xyz.scm (sbcl-cl-gtk4, cl-gtk4): New variables.
---
 gnu/packages/lisp-xyz.scm | 57 +++++++++++++++++++++++++++++++++++++++
 1 file changed, 57 insertions(+)

diff --git a/gnu/packages/lisp-xyz.scm b/gnu/packages/lisp-xyz.scm
index 2a47a21b65..a13363f69a 100644
--- a/gnu/packages/lisp-xyz.scm
+++ b/gnu/packages/lisp-xyz.scm
@@ -9677,6 +9677,63 @@ (define-public cl-glib
 (define-public ecl-cl-glib
   (sbcl-package->ecl-package sbcl-cl-glib))
 
+(define-public sbcl-cl-gtk4
+  (let ((commit "d116905e7b68508d03681a50b3b24d63e7b111e4")
+        (revision "1"))
+    (package
+      (name "sbcl-cl-gtk4")
+      (version (git-version "1.0.0" revision commit))
+      (source
+       (origin
+         (method git-fetch)
+         (uri (git-reference
+               (url "https://github.com/bohonghuang/cl-gtk4")
+               (commit commit)))
+         (file-name (git-file-name "cl-gtk4" version))
+         (sha256
+          (base32 "0mprmmvbagnflvhynn51l42nbwr08rld99ls0c48m5lpjn0ja4zc"))))
+      (build-system asdf-build-system/sbcl)
+      (arguments
+       '(#:asd-systems '("cl-gtk4" "cl-gdk4")
+         #:phases
+         (modify-phases %standard-phases
+           (add-after 'unpack 'copy-typelibs
+             (lambda* (#:key inputs outputs #:allow-other-keys)
+               (let ((out (assoc-ref outputs "out"))
+                     (dirs
+                      (list (assoc-ref inputs "gtk")
+                            (assoc-ref inputs "graphene")
+                            (assoc-ref inputs "harfbuzz")
+                            (assoc-ref inputs "pango")
+                            (assoc-ref inputs "gdk-pixbuf"))))
+                 (map
+                  (lambda (d)
+                     (copy-recursively
+                      (string-append d "/lib/girepository-1.0")
+                      (string-append out "/lib/girepository-1.0")))
+                  dirs)))))))
+      (native-inputs
+       (list graphene pango harfbuzz gdk-pixbuf))
+      (inputs
+       (list
+        gtk
+        gobject-introspection
+        sbcl-cl-glib
+        sbcl-cl-gobject-introspection-wrapper))
+      (native-search-paths
+       (list (search-path-specification
+              (variable "GI_TYPELIB_PATH")
+              (separator ":")
+              (files (list "lib/girepository-1.0")))))
+      (home-page "https://github.com/bohonghuang/cl-gtk4")
+      (synopsis "GTK4 bindings for Common Lisp.")
+      (description "Provides GTK4 bindings for Common Lisp via Gobject Introspection, in the
+cl-gtk4 ASDF system.")
+      (license license:lgpl3))))
+
+(define-public cl-gtk4
+  (sbcl-package->cl-source-package sbcl-cl-gtk4))
+
 (define-public sbcl-cl-slug
   (let ((commit "ffb229d10f0d3f7f54e706791725225e200bf749")
         (revision "1"))
-- 
2.41.0





^ permalink raw reply related	[flat|nested] 12+ messages in thread

* bug#65149: [PATCH 0/4] Add sbcl-cl-gtk4.
  2023-08-08 13:47 [bug#65149] [PATCH 0/4] Add sbcl-cl-gtk4 ykonai via Guix-patches via
  2023-08-08 13:52 ` [bug#65149] [PATCH 1/4] gnu: sbcl-cl-gobject-introspection: Update to 0.3-2.c4fef07 ykonai via Guix-patches via
  2023-08-15 19:49 ` [bug#65149] [PATCH v2 1/4] gnu: sbcl-cl-gobject-introspection: Update to 0.3-2.c4fef07 ykonai via Guix-patches via
@ 2023-08-18 11:46 ` Guillaume Le Vaillant
  2 siblings, 0 replies; 12+ messages in thread
From: Guillaume Le Vaillant @ 2023-08-18 11:46 UTC (permalink / raw)
  To: ykonai; +Cc: 65149-done

[-- Attachment #1: Type: text/plain, Size: 480 bytes --]

Patches applied as cb948aef0caae7e9f3b61c57aa06a73be04a5868 and
following with a few minor fixes.

For cl-gtk4, I used the patch propagating gtk instead of the patch
copying files from several gtk-related libraries (it will probably be
easier to maintain). If one day we have a package with a standalone
binary depending on cl-gtk4, we will just have not to forget to wrap it
so that it can find GI_TYPELIB_PATH (e.g. like for gnome-music, sushi,
gnome-characters, etc).

Thanks.

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 247 bytes --]

^ permalink raw reply	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2023-08-18 12:02 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-08-08 13:47 [bug#65149] [PATCH 0/4] Add sbcl-cl-gtk4 ykonai via Guix-patches via
2023-08-08 13:52 ` [bug#65149] [PATCH 1/4] gnu: sbcl-cl-gobject-introspection: Update to 0.3-2.c4fef07 ykonai via Guix-patches via
2023-08-08 13:52   ` [bug#65149] [PATCH 2/4] gnu: Add sbcl-cl-gobject-introspection-wrapper ykonai via Guix-patches via
2023-08-08 13:52   ` [bug#65149] [PATCH 3/4] gnu: Add sbcl-cl-glib ykonai via Guix-patches via
2023-08-08 13:52   ` [bug#65149] [PATCH 4/4] gnu: Add sbcl-cl-gtk4 ykonai via Guix-patches via
2023-08-10 12:00     ` Guillaume Le Vaillant
2023-08-10 22:15       ` ykonai via Guix-patches via
2023-08-15 19:49 ` [bug#65149] [PATCH v2 1/4] gnu: sbcl-cl-gobject-introspection: Update to 0.3-2.c4fef07 ykonai via Guix-patches via
2023-08-15 19:49   ` [bug#65149] [PATCH v2 2/4] gnu: Add sbcl-cl-gobject-introspection-wrapper ykonai via Guix-patches via
2023-08-15 19:49   ` [bug#65149] [PATCH v2 3/4] gnu: Add sbcl-cl-glib ykonai via Guix-patches via
2023-08-15 19:49   ` [bug#65149] [PATCH v2 4/4] gnu: Add sbcl-cl-gtk4 ykonai via Guix-patches via
2023-08-18 11:46 ` bug#65149: [PATCH 0/4] " Guillaume Le Vaillant

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/guix.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).