[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
02/03: tests: gremlin: Skip file-needed/recursive if DT_NEEDED is empty.
From: |
guix-commits |
Subject: |
02/03: tests: gremlin: Skip file-needed/recursive if DT_NEEDED is empty. |
Date: |
Wed, 24 Feb 2021 04:42:21 -0500 (EST) |
marusich pushed a commit to branch wip-ppc64le
in repository guix.
commit 393683c87bdf3a4473eac4f804d4f490480f9c41
Author: Chris Marusich <cmmarusich@gmail.com>
AuthorDate: Wed Feb 24 00:02:30 2021 -0800
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 fixes the test, which
previously failed incorrectly in the case where Guix has been built using a
foreign distro's toolchain and libraries.
---
tests/gremlin.scm | 7 ++++++-
1 file changed, 6 insertions(+), 1 deletion(-)
diff --git a/tests/gremlin.scm b/tests/gremlin.scm
index 9ddac14..3464feb 100644
--- a/tests/gremlin.scm
+++ b/tests/gremlin.scm
@@ -61,7 +61,12 @@
(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.
+ (and=> (file-runpath %guile-executable)
+ (compose not null-list?)))
(test-skip 1))
(test-assert "file-needed/recursive"
(let* ((needed (file-needed/recursive %guile-executable))