summary refs log tree commit diff
path: root/gnu/packages
diff options
context:
space:
mode:
authorRoman Scherer <roman@burningswell.com>2023-07-02 14:00:39 +0200
committerGuillaume Le Vaillant <glv@posteo.net>2023-07-04 10:40:27 +0200
commitec2b5784abc18870c3a1031928f86131d78684ae (patch)
treeedcf303a7ea8f901226124025e5d79fdddbc089d /gnu/packages
parent9a3cd4a969b168c6b6f19c62cfc5a055dfe51d3e (diff)
downloadguix-ec2b5784abc18870c3a1031928f86131d78684ae.tar.gz
gnu: Add cl-postgres+local-time.
The local-time extension for cl-postgres has to be put in a separate package
to solve a dependency cycle between local-time and postmodern.

* gnu/packages/lisp-xyz.scm (sbcl-local-time)[arguments]: Add
  'delete-local-time' phase.
  (sbcl-cl-postgres+local-time): New variable.

Co-authored-by: Guillaume Le Vaillant <glv@posteo.net>
Diffstat (limited to 'gnu/packages')
-rw-r--r--gnu/packages/lisp-xyz.scm40
1 files changed, 39 insertions, 1 deletions
diff --git a/gnu/packages/lisp-xyz.scm b/gnu/packages/lisp-xyz.scm
index d578c46b90..38e8abb63b 100644
--- a/gnu/packages/lisp-xyz.scm
+++ b/gnu/packages/lisp-xyz.scm
@@ -37,6 +37,7 @@
 ;;; Copyright © 2022 Arun Isaac <arunisaac@systemreboot.net>
 ;;; Copyright © 2022 Trevor Richards <trev@trevdev.ca>
 ;;; Copyright © 2022, 2023 Artyom Bologov <mail@aartaka.me>
+;;; Copyright © 2023 Roman Scherer <roman@burningswell.com>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -6875,7 +6876,7 @@ generators: Indirection, Shift, Accumulate, Add, and Count.")
 
 (define-public sbcl-local-time
   (let ((commit "40169fe26d9639f3d9560ec0255789bf00b30036")
-        (revision "3"))
+        (revision "4"))
     (package
      (name "sbcl-local-time")
      (version (git-version "1.0.6" revision commit))
@@ -6889,6 +6890,14 @@ generators: Indirection, Shift, Accumulate, Add, and Count.")
        (sha256
         (base32 "1dbp33zmkqzzshmf5k76pxqgli285wvy0p0dhcz816fdikpwn2jg"))))
      (build-system asdf-build-system/sbcl)
+     (arguments
+       `(#:phases
+         (modify-phases %standard-phases
+           ;; Delete the extension provided by sbcl-cl-postgres+local-time
+           (add-after 'unpack 'delete-local-time
+             (lambda _
+               (delete-file "cl-postgres+local-time.asd")
+               (delete-file "src/integration/cl-postgres.lisp"))))))
      (native-inputs
       (list sbcl-hu.dwim.stefil))
      (home-page "https://common-lisp.net/project/local-time/")
@@ -6905,6 +6914,35 @@ Long Painful History of Time\".")
 (define-public ecl-local-time
   (sbcl-package->ecl-package sbcl-local-time))
 
+(define-public sbcl-cl-postgres+local-time
+  (package
+    (inherit sbcl-local-time)
+    (name "sbcl-cl-postgres+local-time")
+    (inputs (list sbcl-local-time sbcl-postmodern))
+    (arguments
+     `(#:asd-systems '("cl-postgres+local-time")
+       #:phases
+       (modify-phases %standard-phases
+         (add-after 'unpack 'delete-local-time
+           (lambda _
+             (delete-file "local-time.asd")
+             (delete-file "src/package.lisp")
+             (delete-file "src/local-time.lisp")
+             (delete-file-recursively "doc")
+             (delete-file-recursively "test")
+             (delete-file-recursively "zoneinfo"))))))
+    (synopsis "Integration between cl-postgres and local-time")
+    (description
+     "This package provides the LOCAL-TIME extensions for the cl-postgres
+ASDF system of postmodern.")
+    (license license:expat)))
+
+(define-public cl-postgres+local-time
+  (sbcl-package->cl-source-package sbcl-cl-postgres+local-time))
+
+(define-public ecl-cl-postgres+local-time
+  (sbcl-package->ecl-package sbcl-cl-postgres+local-time))
+
 (define-public sbcl-chronicity
   (package
     (name "sbcl-chronicity")