[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#66461: [PATCH] guix: import: opam: Handle list of licenses.
From: |
Josselin Poiret |
Subject: |
bug#66461: [PATCH] guix: import: opam: Handle list of licenses. |
Date: |
Sun, 15 Oct 2023 11:38:18 +0200 |
From: Josselin Poiret <dev@jpoiret.xyz>
* guix/import/opam.scm (opam->guix-package): Handle lists of licenses.
---
Hello Simon,
Here's a quick fix.
Best,
Josselin
guix/import/opam.scm | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/guix/import/opam.scm b/guix/import/opam.scm
index e67146e593..86e82cde59 100644
--- a/guix/import/opam.scm
+++ b/guix/import/opam.scm
@@ -379,8 +379,10 @@ (define* (opam->guix-package name #:key (repo '("opam"))
version #:allow-other-k
(synopsis ,(metadata-ref opam-content "synopsis"))
(description ,(and=> (metadata-ref opam-content "description")
beautify-description))
- (license ,(spdx-string->license
- (metadata-ref opam-content "license"))))
+ (license ,(match (metadata-ref opam-content "license")
+ ((('string-pat strs) ...)
+ `(list ,@(map spdx-string->license strs)))
+ ((? string? str) (spdx-string->license str)))))
(filter
(lambda (name)
(not (member name '("dune" "jbuilder"))))
base-commit: d2923babf3ac44cb6faa88317f77c98f3016820d
--
2.41.0