guix-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[PATCH 1/2] packages: Getting unpatched origin derivations.


From: Eric Bavier
Subject: [PATCH 1/2] packages: Getting unpatched origin derivations.
Date: Tue, 24 Feb 2015 11:54:00 -0600

* guix/packages.scm (origin->derivation): Add #:patched? keyword argument.
---
 guix/packages.scm |   21 ++++++++++++---------
 1 file changed, 12 insertions(+), 9 deletions(-)

diff --git a/guix/packages.scm b/guix/packages.scm
index 96f3adf..301623b 100644
--- a/guix/packages.scm
+++ b/guix/packages.scm
@@ -938,7 +938,8 @@ cross-compilation target triplet."
   (store-lift patch-and-repack))
 
 (define* (origin->derivation source
-                             #:optional (system (%current-system)))
+                             #:optional (system (%current-system))
+                             #:key (patched? #t))
   "When SOURCE is an <origin> object, return its derivation for SYSTEM.  When
 SOURCE is a file name, return either the interned file name (if SOURCE is
 outside of the store) or SOURCE itself (if SOURCE is already a store item.)"
@@ -956,14 +957,16 @@ outside of the store) or SOURCE itself (if SOURCE is 
already a store item.)"
                                                           (default-guile))
                                                       system
                                                       #:graft? #f)))
-       (patch-and-repack* source patches
-                          #:inputs inputs
-                          #:snippet snippet
-                          #:flags flags
-                          #:system system
-                          #:modules modules
-                          #:imported-modules modules
-                          #:guile-for-build guile)))
+       (if patched?
+           (patch-and-repack* source patches
+                              #:inputs inputs
+                              #:snippet snippet
+                              #:flags flags
+                              #:system system
+                              #:modules modules
+                              #:imported-modules modules
+                              #:guile-for-build guile)
+           (return source))))
     ((and (? string?) (? direct-store-path?) file)
      (with-monad %store-monad
        (return file)))
-- 
1.7.9.5




reply via email to

[Prev in Thread] Current Thread [Next in Thread]