Hi,

The mpivars.sh genereted in openmpi.spec might in some cases lead to a
LD_LIBRARY_PATH that contains a trailing ":". This happens if the
LD_LIBRARY_PATH is originally unset.
This means that current directory is included in the search path for the
loader, which might not be the desired result.

The following patch proposal fixes this potential issue by adding the
":" only if LD_LIBRARY_PATH is already set.

Regards,
Nadia


diff -r 6609b6ba7637 contrib/dist/linux/openmpi.spec
--- a/contrib/dist/linux/openmpi.spec   Mon Feb 15 22:14:59 2010 +0000
+++ b/contrib/dist/linux/openmpi.spec   Tue Feb 16 12:44:41 2010 +0100
@@ -505,7 +505,7 @@ fi

 # LD_LIBRARY_PATH
 if test -z "\`echo \$LD_LIBRARY_PATH | grep %{_libdir}\`"; then
-    LD_LIBRARY_PATH=%{_libdir}:\${LD_LIBRARY_PATH}
+    LD_LIBRARY_PATH=%{_libdir}\${LD_LIBRARY_PATH:+:}\${LD_LIBRARY_PATH}
     export LD_LIBRARY_PATH
 fi


Reply via email to