diff options
author | Ricardo Wurmus <rekado@elephly.net> | 2020-04-16 21:44:21 +0200 |
---|---|---|
committer | Ricardo Wurmus <rekado@elephly.net> | 2020-04-16 23:41:52 +0200 |
commit | 3fd4c4c8394bca7aa9dd81c0ad81f2bb31989464 (patch) | |
tree | 3fd51e5f1584f43e3915a6b177b87aea5bc0f0fa | |
parent | 7cef499bb060aabf3d59cc4eca37350e5c79ff7d (diff) | |
download | patches-3fd4c4c8394bca7aa9dd81c0ad81f2bb31989464.tar patches-3fd4c4c8394bca7aa9dd81c0ad81f2bb31989464.tar.gz |
import/utils: alist->package: Include arguments.
* guix/import/utils.scm (alist->package): Process arguments field in input
data and include it in the generated package.
-rw-r--r-- | guix/import/utils.scm | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/guix/import/utils.scm b/guix/import/utils.scm index 5fb1322535..3809c3d074 100644 --- a/guix/import/utils.scm +++ b/guix/import/utils.scm @@ -322,6 +322,11 @@ specifications to look up and replace them with plain symbols instead." known-inputs))) (append (specs->package-lists regular) (map string->symbol known)))) + (define (process-arguments arguments) + (append-map (match-lambda + ((key . value) + (list (symbol->keyword (string->symbol key)) value))) + arguments)) (package (name (assoc-ref meta "name")) (version (assoc-ref meta "version")) @@ -329,6 +334,10 @@ specifications to look up and replace them with plain symbols instead." (build-system (lookup-build-system-by-name (string->symbol (assoc-ref meta "build-system")))) + (arguments + (or (and=> (assoc-ref meta "arguments") + process-arguments) + '())) (native-inputs (process-inputs "native-inputs")) (inputs (process-inputs "inputs")) (propagated-inputs (process-inputs "propagated-inputs")) |