all messages for Guix-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* [bug#56472] [PATCH]: gnu: Add glop
@ 2022-07-09 21:47 Sharlatan Hellseher
  2022-07-19 21:02 ` bug#56472: " Ludovic Courtès
  0 siblings, 1 reply; 2+ messages in thread
From: Sharlatan Hellseher @ 2022-07-09 21:47 UTC (permalink / raw)
  To: 56472

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

Hi Guix team!

Patch adds Common Lisp FFI bindings  to OpenGL.

Sharlatan Hellseher (1):
  gnu: Add glop

 gnu/packages/lisp-xyz.scm | 68 +++++++++++++++++++++++++++++++++++++++
 1 file changed, 68 insertions(+)

base-commit: e0d47d8facafb6d6c04741bbf30eefbc68aaefb9

> ./pre-inst-env guix build sbcl-glop ecl-glop cl-glop --rounds=2
/gnu/store/z6hivp2g8zqm2q8brcghl1wfzd9gb1ay-cl-glop-0.1.0-1.45e722a
/gnu/store/z5bk61yzhhaj67drkfr8py342h6baw1j-ecl-glop-0.1.0-1.45e722a
/gnu/store/w87di9p2r01y92gll56h7mrgfn682wvx-sbcl-glop-0.1.0-1.45e722a

-- 
… наш разум - превосходная объяснительная машина которая способна
найти смысл почти в чем угодно, истолковать любой феномен, но
совершенно не в состоянии принять мысль о непредсказуемости.

[-- Attachment #2: 0001-gnu-Add-glop.patch --]
[-- Type: text/x-patch, Size: 3661 bytes --]

From 618fa41db9995a792db8d85e09fc08db75635051 Mon Sep 17 00:00:00 2001
From: Sharlatan Hellseher <sharlatanus@gmail.com>
Date: Sat, 9 Jul 2022 22:42:11 +0100
Subject: [PATCH 1/1] gnu: Add glop

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

diff --git a/gnu/packages/lisp-xyz.scm b/gnu/packages/lisp-xyz.scm
index 129b99e485..48a94f80b1 100644
--- a/gnu/packages/lisp-xyz.scm
+++ b/gnu/packages/lisp-xyz.scm
@@ -17839,6 +17839,74 @@ (define-public ecl-cl-posix-mqueue
 (define-public cl-posix-mqueue
   (sbcl-package->cl-source-package sbcl-cl-posix-mqueue))
 
+(define-public sbcl-glop
+  (let ((commit "45e722ab4a0cd2944d550bf790206b3326041e38")
+        (revision "1"))
+    (package
+      (name "sbcl-glop")
+      (version (git-version "0.1.0" revision commit))
+      (source
+       (origin
+         (method git-fetch)
+         (uri (git-reference
+               (url "https://github.com/lispgames/glop")
+               (commit commit)))
+         (file-name (git-file-name "glop" version))
+         (sha256
+          (base32 "1nm35kvigflfjlmsa8zwdajc61f02fh4sq08jv0wnqylhx8yg2bv"))))
+      (build-system asdf-build-system/sbcl)
+      (arguments
+       (list #:test-asd-file "glop-test.asd"
+             #:phases
+             #~(modify-phases %standard-phases
+                 (add-after 'unpack 'patch-lib-paths
+                   (lambda* (#:key inputs #:allow-other-keys)
+                     (substitute* "src/x11/xcomposite.lisp"
+                       (("libXcomposite.so")
+                        (search-input-file inputs "/lib/libXcomposite.so")))
+                     (substitute* "src/x11/xlib.lisp"
+                       (("libX11")
+                        (string-drop-right
+                         (search-input-file inputs "/lib/libX11.so") 3)))
+                     (substitute* "src/utils.lisp"
+                       (("libX11")
+                        (string-drop-right
+                         (search-input-file inputs "/lib/libX11.so") 3)))
+                     (substitute* "src/utils.lisp"
+                       (("libGL.so")
+                        (search-input-file inputs "/lib/libGL.so.1")))
+                     (substitute* "src/x11/glx.lisp"
+                       (("libGL.so")
+                        (search-input-file inputs "/lib/libGL.so")))
+                     (substitute* "src/x11/display-ctrl.lisp"
+                       (("libXrandr")
+                        (string-drop-right
+                         (search-input-file inputs "/lib/libXrandr.so") 3))))))))
+      (native-inputs
+       (list sbcl-cl-opengl))
+      (inputs
+       (list libx11
+             libxcomposite
+             libxrandr
+             mesa
+             sbcl-cffi
+             sbcl-split-sequence
+             sbcl-trivial-garbage))
+      (home-page "https://github.com/lispgames/glop")
+      (synopsis "Direct FFI bindings for OpenGL window and context management")
+      (description
+       "This package provides Common Lisp bindings to create OpenGL window and
+context manipulation code as well as system input handling.  Direct FFI
+bindings to system functions are used so no third party C lib is required
+except system libraries.")
+      (license license:expat))))
+
+(define-public ecl-glop
+  (sbcl-package->ecl-package sbcl-glop))
+
+(define-public cl-glop
+  (sbcl-package->cl-source-package sbcl-glop))
+
 (define-public sbcl-sdl2
   (let ((commit "bb2aa2a41cf799e3bb1ddf50de41fe389c6db668")
         (revision "1"))
-- 
2.36.1


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

* bug#56472: [PATCH]: gnu: Add glop
  2022-07-09 21:47 [bug#56472] [PATCH]: gnu: Add glop Sharlatan Hellseher
@ 2022-07-19 21:02 ` Ludovic Courtès
  0 siblings, 0 replies; 2+ messages in thread
From: Ludovic Courtès @ 2022-07-19 21:02 UTC (permalink / raw)
  To: Sharlatan Hellseher; +Cc: 56472-done

Hi,

Sharlatan Hellseher <sharlatanus@gmail.com> skribis:

> From 618fa41db9995a792db8d85e09fc08db75635051 Mon Sep 17 00:00:00 2001
> From: Sharlatan Hellseher <sharlatanus@gmail.com>
> Date: Sat, 9 Jul 2022 22:42:11 +0100
> Subject: [PATCH 1/1] gnu: Add glop
>
> * gnu/packages/lisp-xyz.scm: (sbcl-glop, ecl-glop, cl-glop): New variables.

Applied, thanks!

Ludo’.




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

end of thread, other threads:[~2022-07-19 21:03 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-07-09 21:47 [bug#56472] [PATCH]: gnu: Add glop Sharlatan Hellseher
2022-07-19 21:02 ` bug#56472: " Ludovic Courtès

Code repositories for project(s) associated with this external index

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

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.