From 7c3a2c3c92f03aa418804708527a1e24525da9ca Mon Sep 17 00:00:00 2001 From: Ralph Castain Date: Tue, 30 Oct 2012 17:38:57 +0000 Subject: [PATCH] Allow PMI support to find subdirs named lib64 instead of lib - thanks to Guillaume.Papaure of Bull for the patch This commit was SVN r27519. --- orte/config/orte_check_pmi.m4 | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/orte/config/orte_check_pmi.m4 b/orte/config/orte_check_pmi.m4 index 6e0793a195..2085e39e96 100644 --- a/orte/config/orte_check_pmi.m4 +++ b/orte/config/orte_check_pmi.m4 @@ -43,6 +43,7 @@ AC_DEFUN([ORTE_CHECK_PMI],[ # set defaults orte_check_pmi_$1_LDFLAGS= orte_check_pmi_$1_CPPFLAGS= + orte_check_pmi_$1_LIBS= AC_MSG_CHECKING([if user requested PMI support]) AS_IF([test "$with_pmi" = "no"], @@ -56,8 +57,10 @@ AC_DEFUN([ORTE_CHECK_PMI],[ # work with slurm :-( AS_IF([test ! -z "$with_pmi" -a "$with_pmi" != "yes"], [AS_IF([test -d "$with_pmi/lib64"], - [orte_check_pmi_$1_LDFLAGS="-L$with_pmi/lib64"], - [orte_check_pmi_$1_LDFLAGS="-L$with_pmi/lib"]) + [orte_check_pmi_$1_LDFLAGS="-L$with_pmi/lib64" + orte_check_pmi_$1_LIBS="-lpmi -Wl,-rpath=$with_pmi/lib64"], + [orte_check_pmi_$1_LDFLAGS="-L$with_pmi/lib" + orte_check_pmi_$1_LIBS="-lpmi -Wl,-rpath=$with_pmi/lib"]) AS_IF([test -f "$with_pmi/include/pmi.h"], [orte_check_pmi_$1_CPPFLAGS="-I$with_pmi/include"], [AS_IF([test -f "$with_pmi/include/slurm/pmi.h"], @@ -67,7 +70,7 @@ AC_DEFUN([ORTE_CHECK_PMI],[ LDFLAGS="$LDFLAGS $orte_check_pmi_$1_LDFLAGS" CPPFLAGS="$CPPFLAGS $orte_check_pmi_$1_CPPFLAGS" - LIBS="$LIBS -lpmi" + LIBS="$LIBS $orte_check_pmi_$1_LIBS" orte_have_pmi_support=no AC_CHECK_HEADERS([pmi.h], [AC_CHECK_LIB([pmi], [PMI_Init],