[bug#43367,2/5] utils: Rename wrapper? to wrapped-program?.
diff mbox series

Message ID 20200913054557.12911-2-mail@brendan.scot
State New
Headers show
  • [bug#43367,1/5] utils: wrap-program: Refuse to wrap .X-real files.
Related show

Commit Message

Brendan Tildesley Sept. 13, 2020, 5:45 a.m. UTC
* guix/build/utils.scm (wrap-program): The wrapper? procedure is
incorrectly named as it actually checks to see if prog is the
original program that was moved, not the wrapper.

* guix/build/python-build-system: (wrap): Use renamed wrapped-program?.
 guix/build/python-build-system.scm | 2 +-
 guix/build/utils.scm               | 6 +++---
 2 files changed, 4 insertions(+), 4 deletions(-)

diff mbox series

diff --git a/guix/build/python-build-system.scm b/guix/build/python-build-system.scm
index 62e7a7b305..d1dbbc1de2 100644
--- a/guix/build/python-build-system.scm
+++ b/guix/build/python-build-system.scm
@@ -196,7 +196,7 @@  when running checks after installing the package."
   (define (list-of-files dir)
     (find-files dir (lambda (file stat)
                       (and (eq? 'regular (stat:type stat))
-                           (not (wrapper? file))))))
+                           (not (wrapped-program? file))))))
   (define bindirs
     (append-map (match-lambda
diff --git a/guix/build/utils.scm b/guix/build/utils.scm
index 822191f4de..4cd227a668 100644
--- a/guix/build/utils.scm
+++ b/guix/build/utils.scm
@@ -90,7 +90,7 @@ 
-            wrapper?
+            wrapped-program?
@@ -1118,8 +1118,8 @@  known as `nuke-refs' in Nixpkgs."
   (program    wrap-error-program)
   (type       wrap-error-type))
-(define (wrapper? prog)
-  "Return #t if PROG is a wrapper as produced by 'wrap-program'."
+(define (wrapped-program? prog)
+  "Return #t if PROG is a program that was moved and wrapped by 'wrap-program'."
   (and (file-exists? prog)
        (let ((base (basename prog)))
          (and (string-prefix? "." base)