From 7c435186c8c71bb77d9e90c9f2aab2bd5dbc7a56 Mon Sep 17 00:00:00 2001 From: Gilles Gouaillardet Date: Wed, 14 Nov 2018 11:35:54 -0600 Subject: [PATCH 1/3] configury: do fail lustre detection when llapi_file_create() is not found The result of this test was previously and incorrectly ignored. Signed-off-by: Gilles Gouaillardet (cherry picked from commit 72d3e290848b6e70d4c1101c229cd53be6190c33) --- config/ompi_check_lustre.m4 | 27 ++++++++++++++------------- 1 file changed, 14 insertions(+), 13 deletions(-) diff --git a/config/ompi_check_lustre.m4 b/config/ompi_check_lustre.m4 index 8c385bfe8f..bd0acec15e 100644 --- a/config/ompi_check_lustre.m4 +++ b/config/ompi_check_lustre.m4 @@ -12,8 +12,8 @@ dnl Copyright (c) 2004-2006 The Regents of the University of California. dnl All rights reserved. dnl Copyright (c) 2009-2017 Cisco Systems, Inc. All rights reserved dnl Copyright (c) 2008-2018 University of Houston. All rights reserved. -dnl Copyright (c) 2015 Research Organization for Information Science -dnl and Technology (RIST). All rights reserved. +dnl Copyright (c) 2015-2018 Research Organization for Information Science +dnl and Technology (RIST). All rights reserved. dnl $COPYRIGHT$ dnl dnl Additional copyrights may follow @@ -63,8 +63,9 @@ AC_DEFUN([OMPI_CHECK_LUSTRE],[ [ompi_check_lustre_happy="yes"], [ompi_check_lustre_happy="no"]) - AC_MSG_CHECKING([for required lustre data structures]) - cat > conftest.c < conftest.c < Date: Wed, 14 Nov 2018 11:41:39 -0600 Subject: [PATCH 2/3] configury: fix include path in Lustre detection use -I$ompi_check_lustre_dir/include in order to correctly support configure --with-lustre Signed-off-by: Gilles Gouaillardet (cherry picked from commit 7783e5ad09084caf684cfd9b2acf7bd79354074f) --- config/ompi_check_lustre.m4 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/config/ompi_check_lustre.m4 b/config/ompi_check_lustre.m4 index bd0acec15e..0e78db9f64 100644 --- a/config/ompi_check_lustre.m4 +++ b/config/ompi_check_lustre.m4 @@ -79,7 +79,7 @@ EOF # Try the compile OPAL_LOG_COMMAND( - [$CC $CFLAGS -I$with_lustre/include -c conftest.c], + [$CC $CFLAGS -I$ompi_check_lustre_dir/include -c conftest.c], [ompi_check_lustre_struct_happy="yes"], [ompi_check_lustre_struct_happy="no" ompi_check_lustre_happy="no"] From c43d8e54d630b69fdd3cad59b0e5b04856220a4b Mon Sep 17 00:00:00 2001 From: Howard Pritchard Date: Thu, 23 Apr 2020 10:29:28 -0600 Subject: [PATCH 3/3] rework check lustre config to avoid rpath lib64 The original configury check for lustre was ending up rpathing in /usr/lib64 in the compiler wrapper scripts. This commit fixes that issue. related to #7580 Signed-off-by: Howard Pritchard (cherry picked from commit ea690d008b92a0091b9e5245bf171d25a5ea0b52) --- config/ompi_check_lustre.m4 | 62 +++++++++++++++++++------------------ 1 file changed, 32 insertions(+), 30 deletions(-) diff --git a/config/ompi_check_lustre.m4 b/config/ompi_check_lustre.m4 index 0e78db9f64..9f97b5ff38 100644 --- a/config/ompi_check_lustre.m4 +++ b/config/ompi_check_lustre.m4 @@ -14,6 +14,8 @@ dnl Copyright (c) 2009-2017 Cisco Systems, Inc. All rights reserved dnl Copyright (c) 2008-2018 University of Houston. All rights reserved. dnl Copyright (c) 2015-2018 Research Organization for Information Science dnl and Technology (RIST). All rights reserved. +dnl Copyright (c) 2020 Triad National Security, LLC. All rights +dnl reserved. dnl $COPYRIGHT$ dnl dnl Additional copyrights may follow @@ -36,7 +38,6 @@ AC_DEFUN([OMPI_CHECK_LUSTRE],[ check_lustre_save_LDFLAGS="$LDFLAGS" check_lustre_save_CPPFLAGS="$CPPFLAGS" - check_lustre_configuration="none" ompi_check_lustre_happy="yes" # Get some configuration information @@ -46,26 +47,28 @@ AC_DEFUN([OMPI_CHECK_LUSTRE],[ OPAL_CHECK_WITHDIR([lustre], [$with_lustre], [include/lustre/lustreapi.h]) AS_IF([test "$with_lustre" = "no"], - [ompi_check_lustre_happy="no"], - [AS_IF([test -z "$with_lustre" || test "$with_lustre" = "yes"], - [ompi_check_lustre_dir="/usr"], - [ompi_check_lustre_dir=$with_lustre]) - - if test -e "$ompi_check_lustre_dir/lib64" ; then - ompi_check_lustre_libdir="$ompi_check_lustre_dir/lib64" - else - ompi_check_lustre_libdir="$ompi_check_lustre_dir/lib" - fi - - # Add correct -I and -L flags - OPAL_CHECK_PACKAGE([$1], [lustre/lustreapi.h], [lustreapi], [llapi_file_create], + [ompi_check_lustre_happy=no]) + + AS_IF([test "$ompi_check_lustre_happy" != "no" ], + [AC_MSG_CHECKING([looking for lustre libraries and header files in]) + AS_IF([test "$with_lustre" != "yes"], + [ompi_check_lustre_dir=$with_lustre + AC_MSG_RESULT([($ompi_check_lustre_dir)])], + [AC_MSG_RESULT([(default search paths)])]) + AS_IF([test -n "$with_lustre_libdir" && \ + test "$with_lustre_libdir" != "yes"], + [ompi_check_lustre_libdir=$with_lustre_libdir]) + ]) + + AS_IF([test "$ompi_check_lustre_happy" != "no" ], + [OPAL_CHECK_PACKAGE([$1], [lustre/lustreapi.h], [lustreapi], [llapi_file_create], [], [$ompi_check_lustre_dir], [$ompi_check_lustre_libdir], [ompi_check_lustre_happy="yes"], - [ompi_check_lustre_happy="no"]) + [ompi_check_lustre_happy="no"])]) - AS_IF([test "$ompi_check_lustre_happy" = "yes"], - [AC_MSG_CHECKING([for required lustre data structures]) - cat > conftest.c < conftest.c <