Skip to content

Commit 50d05e7

Browse files
committed
Revert "Add extra libs to PRRTE binaries for external deps"
This reverts commit 1aabbe4. Update PMIx and PRRTE, plus PRRTE config integration Cleanup how we pass the extra libs and LDFLAGS for linking against external libevent, hwloc, and pmix installs. Catch the flag indicating that PMIx provided the user-level default MCA params so we don't go looking for them ourselves. Cleanup misc config warnings Signed-off-by: Ralph Castain <[email protected]>
1 parent 92b5898 commit 50d05e7

File tree

4 files changed

+34
-32
lines changed

4 files changed

+34
-32
lines changed

config/ompi_setup_prrte.m4

Lines changed: 20 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@
2424
#
2525

2626
AC_DEFUN([OMPI_SETUP_PRRTE],[
27-
OPAL_VAR_SCOPE_PUSH([opal_prrte_save_CPPFLAGS opal_prrte_save_CFLAGS opal_prrte_save_LDFLAGS opal_prrte_save_LIBS opal_prrte_args opal_prrte_save_enable_dlopen opal_prrte_save_enable_mca_dso opal_prrte_save_enable_mca_static opal_prrte_extra_libs opal_prrte_extra_ltlibs opal_prrte_extra_ldflags])
27+
OPAL_VAR_SCOPE_PUSH([opal_prrte_save_CPPFLAGS opal_prrte_save_CFLAGS opal_prrte_save_LDFLAGS opal_prrte_save_LIBS opal_prrte_args opal_prrte_save_enable_dlopen opal_prrte_save_enable_mca_dso opal_prrte_save_enable_mca_static])
2828

2929
opal_prrte_save_CFLAGS=$CFLAGS
3030
opal_prrte_save_CPPFLAGS=$CPPFLAGS
@@ -59,29 +59,29 @@ AC_DEFUN([OMPI_SETUP_PRRTE],[
5959
if test "$enable_internal_rte" != "no"; then
6060
AC_MSG_RESULT([yes])
6161
ompi_want_prrte=yes
62-
opal_prrte_extra_libs=$OMPI_TOP_BUILDDIR/opal/libopen-pal.la
63-
opal_prrte_extra_ltlibs=$OMPI_TOP_BUILDDIR/opal/libopen-pal.la
64-
65-
if test "$opal_event_external_support" = "yes"; then
66-
opal_prrte_extra_libs="$opal_prrte_extra_libs $opal_event_external_LIBS"
67-
opal_prrte_extra_ltlibs="$opal_prrte_extra_ltlibs $opal_event_external_LIBS"
62+
if test -z $with_libevent || test "$with_libevent" = "internal" || test "$with_libevent" = "yes"; then
63+
opal_prrte_libevent_arg="--with-libevent-header=$OMPI_TOP_SRCDIR/opal/mca/event/event.h"
64+
elif test "$with_libevent" = "external"; then
65+
opal_prrte_libevent_arg=""
66+
else
67+
opal_prrte_libevent_arg="--with-libevent=$with_libevent"
6868
fi
69-
# specifying --with-libevent-header causes prrte to ignore the with_libevent and with_libevent_libdir options
70-
opal_prrte_libevent_arg="--with-libevent-header=$OMPI_TOP_SRCDIR/opal/mca/event/event.h"
7169

72-
if test "$opal_hwloc_external_support" = "yes"; then
73-
opal_prrte_extra_libs="$opal_prrte_extra_libs $opal_hwloc_external_LIBS"
74-
opal_prrte_extra_ltlibs="$opal_prrte_extra_ltlibs $opal_hwloc_external_LIBS"
70+
if test -z $with_hwloc || test "$with_hwloc" = "internal" || test "$with_hwloc" = "yes"; then
71+
opal_prrte_hwloc_arg="--with-hwloc-header=$OMPI_TOP_SRCDIR/opal/mca/hwloc/hwloc-internal.h"
72+
elif test "$with_hwloc" = "external"; then
73+
opal_prrte_hwloc_arg=""
74+
else
75+
opal_prrte_hwloc_arg="--with-hwloc=$with_hwloc"
7576
fi
76-
# specifying --with-hwloc-header causes prrte to ignore the with_hwloc and with_hwloc_libdir options
77-
opal_prrte_hwloc_arg="--with-hwloc-header=$OMPI_TOP_SRCDIR/opal/mca/hwloc/hwloc-internal.h"
7877

79-
if test "$opal_external_pmix_happy" = "yes"; then
80-
opal_prrte_extra_libs="$opal_prrte_extra_libs $opal_pmix_external_LIBS"
81-
opal_prrte_extra_ltlibs="$opal_prrte_extra_ltlibs $opal_pmix_external_LIBS"
78+
if test -z $with_pmix || test "$with_pmix" = "internal" || test "$with_pmix" = "yes"; then
79+
opal_prrte_pmix_arg="--with-pmix-header=$OMPI_TOP_SRCDIR/opal/mca/pmix/pmix-internal.h"
80+
elif test "$with_pmix" = "external"; then
81+
opal_prrte_pmix_arg=""
82+
else
83+
opal_prrte_pmix_arg="--with-pmix=$with_pmix"
8284
fi
83-
# specifying --with-pmix-header causes prrte to ignore the with_pmix and with_pmix_libdir options
84-
opal_prrte_pmix_arg="--with-pmix-header=$OMPI_TOP_SRCDIR/opal/mca/pmix/pmix-internal.h"
8585

8686
if test -z $enable_prte_prefix_by_default || test "$enable_prte_prefix_by_default" = "yes" ||
8787
test "$enable_orterun_prefix_given" = "yes"; then
@@ -102,7 +102,7 @@ AC_DEFUN([OMPI_SETUP_PRRTE],[
102102
opal_prrte_args="$opal_prrte_args --with-platform=$with_prrte_platform"
103103
fi
104104
# add the extra libs
105-
opal_prrte_args="$opal_prrte_args --with-prrte-extra-lib=\"$opal_prrte_extra_libs\" --with-prrte-extra-ltlib=\"$opal_prrte_extra_ltlibs\""
105+
opal_prrte_args="$opal_prrte_args --with-prrte-extra-lib=$OMPI_TOP_BUILDDIR/opal/libopen-pal.la --with-prrte-extra-ltlib=$OMPI_TOP_BUILDDIR/opal/libopen-pal.la"
106106

107107
AC_MSG_CHECKING([final prrte configure args])
108108
AC_MSG_RESULT([$opal_prrte_args])

opal/mca/base/mca_base_var.c

Lines changed: 12 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
* Copyright (c) 2008-2018 Cisco Systems, Inc. All rights reserved
1414
* Copyright (c) 2012-2018 Los Alamos National Security, LLC. All rights
1515
* reserved.
16-
* Copyright (c) 2014-2016 Intel, Inc. All rights reserved.
16+
* Copyright (c) 2014-2020 Intel, Inc. All rights reserved.
1717
* Copyright (c) 2015 Research Organization for Information Science
1818
* and Technology (RIST). All rights reserved.
1919
* Copyright (c) 2017 IBM Corporation. All rights reserved.
@@ -290,6 +290,13 @@ int mca_base_var_init(void)
290290
return ret;
291291
}
292292

293+
/* We may need this later */
294+
home = (char*)opal_home_directory();
295+
if (NULL == home) {
296+
opal_output(0, "Error: Unable to get the user home directory\n");
297+
return OPAL_ERROR;
298+
}
299+
293300
/* Set this before we register the parameter, below */
294301

295302
mca_base_var_initialized = true;
@@ -412,16 +419,11 @@ int mca_base_var_cache_files(bool rel_path_search)
412419
}
413420

414421
#if OPAL_WANT_HOME_CONFIG_FILES
415-
/* We may need this later */
416-
home = (char*)opal_home_directory();
417-
if (NULL == home) {
418-
opal_output(0, "Error: Unable to get the user home directory\n");
419-
return OPAL_ERROR;
422+
if (NULL == getenv("OPAL_USER_PARAMS_GIVEN")) {
423+
opal_asprintf(&mca_base_var_files, "%s"OPAL_PATH_SEP".openmpi" OPAL_PATH_SEP
424+
"mca-params.conf%c%s" OPAL_PATH_SEP "openmpi-mca-params.conf",
425+
home, ',', opal_install_dirs.sysconfdir);
420426
}
421-
422-
opal_asprintf(&mca_base_var_files, "%s"OPAL_PATH_SEP".openmpi" OPAL_PATH_SEP
423-
"mca-params.conf%c%s" OPAL_PATH_SEP "openmpi-mca-params.conf",
424-
home, ',', opal_install_dirs.sysconfdir);
425427
#else
426428
opal_asprintf(&mca_base_var_files, "%s" OPAL_PATH_SEP "openmpi-mca-params.conf",
427429
opal_install_dirs.sysconfdir);

0 commit comments

Comments
 (0)