summary refs log tree commit diff
path: root/tests/gremlin.scm
diff options
context:
space:
mode:
authorChris Marusich <cmmarusich@gmail.com>2021-02-24 00:02:30 -0800
committerChris Marusich <cmmarusich@gmail.com>2021-06-23 20:30:22 -0700
commite4b5a23841bc6a92e2e21dd8b1038addee55eb02 (patch)
tree1588eded7503768f698543bddcec4286d3697ac1 /tests/gremlin.scm
parenta3d9af5eb11cb4b85d011cea3c0da4a1a5aede2f (diff)
downloadguix-e4b5a23841bc6a92e2e21dd8b1038addee55eb02.tar.gz
tests: gremlin: Skip file-needed/recursive if DT_NEEDED is empty.
* tests/gremlin.scm (file-needed/recursive): Skip the test when (file-runpath
%guile-executable) evaluates to the empty list.  This causes the test to be
correctly skipped in the case where Guix has been built using a foreign
distro's toolchain and libraries.
Diffstat (limited to 'tests/gremlin.scm')
-rw-r--r--tests/gremlin.scm6
1 files changed, 5 insertions, 1 deletions
diff --git a/tests/gremlin.scm b/tests/gremlin.scm
index f20a79f4d6..9af899c89a 100644
--- a/tests/gremlin.scm
+++ b/tests/gremlin.scm
@@ -61,7 +61,11 @@
                      (elf-dynamic-info-needed dyninfo))))))
 
 (unless (and %guile-executable (not (getenv "LD_LIBRARY_PATH"))
-             (file-needed %guile-executable))     ;statically linked?
+             (file-needed %guile-executable) ;statically linked?
+             ;; When Guix has been built on a foreign distro, using a
+             ;; toolchain and libraries from that foreign distro, it is not
+             ;; unusual for the runpath to be empty.
+             (pair? (file-runpath %guile-executable)))
   (test-skip 1))
 (test-assert "file-needed/recursive"
   (let* ((needed (file-needed/recursive %guile-executable))