diff options
Diffstat (limited to 'guix/packages.scm')
-rw-r--r-- | guix/packages.scm | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/guix/packages.scm b/guix/packages.scm index a979f31a32..b7a1979a7d 100644 --- a/guix/packages.scm +++ b/guix/packages.scm @@ -56,6 +56,7 @@ search-path-specification search-path-specification? search-path-specification->sexp + sexp->search-path-specification package package? @@ -202,10 +203,24 @@ representation." (define (search-path-specification->sexp spec) "Return an sexp representing SPEC, a <search-path-specification>. The sexp corresponds to the arguments expected by `set-path-environment-variable'." + ;; Note that this sexp format is used both by build systems and in + ;; (guix profiles), so think twice before you change it. (match spec (($ <search-path-specification> variable files separator type pattern) `(,variable ,files ,separator ,type ,pattern)))) +(define (sexp->search-path-specification sexp) + "Convert SEXP, which is as returned by 'search-path-specification->sexp', to +a <search-path-specification> object." + (match sexp + ((variable files separator type pattern) + (search-path-specification + (variable variable) + (files files) + (separator separator) + (file-type type) + (file-pattern pattern))))) + (define %supported-systems ;; This is the list of system types that are supported. By default, we ;; expect all packages to build successfully here. |