summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--guix/packages.scm8
1 files changed, 6 insertions, 2 deletions
diff --git a/guix/packages.scm b/guix/packages.scm
index b4fc026dbb..97a2464309 100644
--- a/guix/packages.scm
+++ b/guix/packages.scm
@@ -345,8 +345,12 @@ IMPORTED-MODULES specify modules to use/import for use by SNIPPET."
   (define patch-inputs
     (map (lambda (number patch)
            (list (string-append "patch" (number->string number))
-                 (add-to-store store (basename patch) #t
-                               "sha256" patch)))
+                 (match patch
+                   ((? string?)
+                    (add-to-store store (basename patch) #t
+                                  "sha256" patch))
+                   ((? origin?)
+                    (package-source-derivation store patch)))))
          (iota (length patches))
 
          patches))