guix-commits
[Top][All Lists]
Advanced

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

branch master updated: gnu: Move PACKAGES-WITH-*PATCHES to (guix package


From: guix-commits
Subject: branch master updated: gnu: Move PACKAGES-WITH-*PATCHES to (guix packages)
Date: Mon, 06 Apr 2020 14:09:47 -0400

This is an automated email from the git hooks/post-receive script.

carl pushed a commit to branch master
in repository guix.

The following commit(s) were added to refs/heads/master by this push:
     new b066c25  gnu: Move PACKAGES-WITH-*PATCHES to (guix packages)
b066c25 is described below

commit b066c25026f21fb57677aa34692a5034338e7ee3
Author: Carl Dong <address@hidden>
AuthorDate: Mon Apr 6 14:02:42 2020 -0400

    gnu: Move PACKAGES-WITH-*PATCHES to (guix packages)
    
    * gnu/packages/cross-base.scm (package-with-extra-patches,
    package-with-patches): Move procedures from here...
    * guix/packages.scm (package-with-extra-patches, package-with-patches):
    ...to here, and export.
---
 gnu/packages/cross-base.scm | 12 ------------
 guix/packages.scm           | 14 ++++++++++++++
 2 files changed, 14 insertions(+), 12 deletions(-)

diff --git a/gnu/packages/cross-base.scm b/gnu/packages/cross-base.scm
index ae3ac21..b0eb7ab 100644
--- a/gnu/packages/cross-base.scm
+++ b/gnu/packages/cross-base.scm
@@ -70,18 +70,6 @@
         `(cons ,(string-append "--target=" target)
                ,flags))))))
 
-(define (package-with-patches original patches)
-  "Return package ORIGINAL with PATCHES applied."
-  (package (inherit original)
-    (source (origin (inherit (package-source original))
-                    (patches patches)))))
-
-(define (package-with-extra-patches original patches)
-  "Return package ORIGINAL with all PATCHES appended to its list of patches."
-  (package-with-patches original
-                        (append (origin-patches (package-source original))
-                                patches)))
-
 (define (cross-binutils target)
   "Return a cross-Binutils for TARGET."
   (let ((binutils (package (inherit binutils)
diff --git a/guix/packages.scm b/guix/packages.scm
index 04d9b78..6c6a06e 100644
--- a/guix/packages.scm
+++ b/guix/packages.scm
@@ -111,6 +111,8 @@
             package-output
             package-grafts
             package-patched-vulnerabilities
+            package-with-patches
+            package-with-extra-patches
             package/inherit
 
             transitive-input-references
@@ -654,6 +656,18 @@ specifies modules in scope when evaluating SNIPPET."
                         #:properties `((type . origin)
                                        (patches . ,(length patches)))))))
 
+(define (package-with-patches original patches)
+  "Return package ORIGINAL with PATCHES applied."
+  (package (inherit original)
+           (source (origin (inherit (package-source original))
+                           (patches patches)))))
+
+(define (package-with-extra-patches original patches)
+  "Return package ORIGINAL with all PATCHES appended to its list of patches."
+  (package-with-patches original
+                        (append (origin-patches (package-source original))
+                                patches)))
+
 (define (transitive-inputs inputs)
   "Return the closure of INPUTS when considering the 'propagated-inputs'
 edges.  Omit duplicate inputs, except for those already present in INPUTS



reply via email to

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