[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
03/10: gnu: Add python-clingo-dl.
From: |
guix-commits |
Subject: |
03/10: gnu: Add python-clingo-dl. |
Date: |
Sat, 3 Feb 2024 08:23:03 -0500 (EST) |
lilyp pushed a commit to branch master
in repository guix.
commit 9f85c0cdb1f309e3f8e12bdbbba00e46a2453986
Author: Liliana Marie Prikler <liliana.prikler@gmail.com>
AuthorDate: Thu Jan 25 10:42:06 2024 +0100
gnu: Add python-clingo-dl.
* gnu/packages/potassco.scm (python-clingo-dl): New variable.
---
gnu/packages/potassco.scm | 36 +++++++++++++++++++++++++++++++++++-
1 file changed, 35 insertions(+), 1 deletion(-)
diff --git a/gnu/packages/potassco.scm b/gnu/packages/potassco.scm
index f2ee27db99..afc4c4d513 100644
--- a/gnu/packages/potassco.scm
+++ b/gnu/packages/potassco.scm
@@ -1,5 +1,5 @@
;;; GNU Guix --- Functional package management for GNU
-;;; Copyright © 2022, 2023 Liliana Marie Prikler <liliana.prikler@gmail.com>
+;;; Copyright © 2022–2024 Liliana Marie Prikler <liliana.prikler@gmail.com>
;;; Copyright © 2023 Simon Tournier <zimon.toutoune@gmail.com>
;;; Copyright © 2023 David Elsing <david.elsing@posteo.net>
;;; Copyright © 2024 Ricardo Wurmus <rekado@elephly.net>
@@ -370,6 +370,40 @@ in particular ones that can be solved by
@command{clingo}.")
making it so that you can write @acronym{ASPs, Answer Set Programs} through
Python code.")))
+(define-public python-clingo-dl
+ (package
+ (inherit clingo-dl)
+ (name "python-clingo-dl")
+ (version (package-version clingo-dl))
+ (arguments
+ (list
+ #:configure-flags #~'("-DPYCLINGODL_ENABLE=pip")
+ #:tests? #f
+ #:imported-modules `(,@%cmake-build-system-modules
+ (guix build python-build-system))
+ #:modules '((guix build cmake-build-system)
+ ((guix build python-build-system) #:prefix python:)
+ (guix build utils))
+ #:phases
+ #~(modify-phases %standard-phases
+ (add-after 'install 'install-distinfo
+ (lambda* (#:key inputs outputs #:allow-other-keys)
+ (with-directory-excursion (python:site-packages inputs outputs)
+ (let ((dir (string-append "clingodl-" #$version ".dist-info")))
+ (mkdir-p dir)
+ (call-with-output-file (string-append dir "/METADATA")
+ (lambda (port)
+ (format port "Metadata-Version: 1.1~%")
+ (format port "Name: clingodl~%")
+ (format port "Version: ~a~%" #$version))))))))))
+ (inputs (modify-inputs (package-inputs clingo-dl)
+ (prepend python-wrapper)))
+ (propagated-inputs (list python-clingo python-cffi))
+ (synopsis "Python bindings for clingo-dl")
+ (description "This package allows users to add the clingo-dl propagator
+as a theory to clingo from Python code. It also supports running clingo-dl
+directly from the python command line.")))
+
(define-public python-clorm
(package
(name "python-clorm")
- branch master updated (9389070b9c -> 179bb57d25), guix-commits, 2024/02/03
- 03/10: gnu: Add python-clingo-dl.,
guix-commits <=
- 07/10: gnu: Add python-tzdata., guix-commits, 2024/02/03
- 09/10: gnu: python-rpy2: Update to 3.5.15., guix-commits, 2024/02/03
- 01/10: gnu: Add waffle., guix-commits, 2024/02/03
- 02/10: gnu: Add piglit., guix-commits, 2024/02/03
- 05/10: gnu: Add python-plingo., guix-commits, 2024/02/03
- 04/10: gnu: python-clorm: Reindent with emacs., guix-commits, 2024/02/03
- 08/10: gnu: python-tzlocal: Update to 5.2., guix-commits, 2024/02/03
- 10/10: gnu: raylib: Update to 5.0., guix-commits, 2024/02/03
- 06/10: gnu: Add lua-clingo., guix-commits, 2024/02/03