Hi all,
 
Tests asm-tst4, asm-tst5 and asm-tst6 can fail if binaries produced by compiler require shared libraries which are not in system directories. For instance if the binaries are produced by development version of compiler. In such cases LD_LIBRARY_PATH should contain path to non-standard location of libraries, but in the aforementioned tests content of this variable is lost.
The following patch can be used to solve the problem:
 
diff --git a/tests/asm-tst4.c b/tests/asm-tst4.c
index 54d054c..e6a6210 100644
--- a/tests/asm-tst4.c
+++ b/tests/asm-tst4.c
@@ -102,7 +102,8 @@ main (void)
 
   if (result == 0)
     result = WEXITSTATUS (system ("\
-env LD_LIBRARY_PATH=../libelf ../src/elflint -q asm-tst4-out.o"));
+env LD_LIBRARY_PATH=../libelf${LD_LIBRARY_PATH:+:}$LD_LIBRARY_PATH\
+ ../src/elflint -q asm-tst4-out.o"));
 
   /* We don't need the file anymore.  */
   unlink (fname);
diff --git a/tests/asm-tst5.c b/tests/asm-tst5.c
index 2a8b3f0..f81272b 100644
--- a/tests/asm-tst5.c
+++ b/tests/asm-tst5.c
@@ -114,7 +114,8 @@ main (void)
 
   if (result == 0)
     result = WEXITSTATUS (system ("\
-env LD_LIBRARY_PATH=../libelf ../src/elflint -q asm-tst5-out.o"));
+env LD_LIBRARY_PATH=../libelf${LD_LIBRARY_PATH:+:}$LD_LIBRARY_PATH\
+ ../src/elflint -q asm-tst5-out.o"));
 
   /* We don't need the file anymore.  */
   unlink (fname);
diff --git a/tests/asm-tst6.c b/tests/asm-tst6.c
index bd6a71d..a4f5ac8 100644
--- a/tests/asm-tst6.c
+++ b/tests/asm-tst6.c
@@ -148,7 +148,8 @@ main (void)
 
   if (result == 0)
     result = WEXITSTATUS (system ("\
-env LD_LIBRARY_PATH=../libelf ../src/elflint -q asm-tst6-out.o"));
+env LD_LIBRARY_PATH=../libelf${LD_LIBRARY_PATH:+:}$LD_LIBRARY_PATH\
+ ../src/elflint -q asm-tst6-out.o"));
 
   /* We don't need the file anymore.  */
   unlink (fname);
 
Thanks,
--Serge