aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--guix/packages.scm8
1 files changed, 4 insertions, 4 deletions
diff --git a/guix/packages.scm b/guix/packages.scm
index 4ab8650340..70b1478c91 100644
--- a/guix/packages.scm
+++ b/guix/packages.scm
@@ -363,12 +363,12 @@ object."
(let ((field (assoc field inits)))
(match field
((_ value)
- (let ((props (source-properties value)))
- (and props
+ (let ((loc (and=> (source-properties value)
+ source-properties->location)))
+ (and loc
;; Preserve the original file name, which may be a
;; relative file name.
- (let ((loc (source-properties->location props)))
- (set-field loc (location-file) file)))))
+ (set-field loc (location-file) file))))
(_
#f))))
(_