diff --git a/ompi/mca/pubsub/pmi/Makefile.am b/ompi/mca/pubsub/pmi/Makefile.am index 7cb69d5230..f9426b137b 100644 --- a/ompi/mca/pubsub/pmi/Makefile.am +++ b/ompi/mca/pubsub/pmi/Makefile.am @@ -30,7 +30,8 @@ mcacomponentdir = $(pkglibdir) mcacomponent_LTLIBRARIES = $(component_install) mca_pubsub_pmi_la_SOURCES = $(local_sources) mca_pubsub_pmi_la_LDFLAGS = -module -avoid-version $(pubsub_pmi_LDFLAGS) -mca_pubsub_pmi_la_LIBADD = $(pubsub_pmi_LIBS) +mca_pubsub_pmi_la_LIBADD = $(pubsub_pmi_LIBS) \ + $(top_ompi_builddir)/orte/mca/common/pmi/libmca_common_pmi.la noinst_LTLIBRARIES = $(component_noinst) libmca_pubsub_pmi_la_SOURCES = $(local_sources) diff --git a/orte/mca/common/pmi/Makefile.am b/orte/mca/common/pmi/Makefile.am index d1a06b728d..00a8ccf2d8 100644 --- a/orte/mca/common/pmi/Makefile.am +++ b/orte/mca/common/pmi/Makefile.am @@ -1,5 +1,6 @@ # # Copyright (c) 2011 Cisco Systems, Inc. All rights reserved. +# Copyright (c) 2012 Sandia National Laboratories. All rights reserved. # $COPYRIGHT$ # # Additional copyrights may follow @@ -7,29 +8,32 @@ # $HEADER$ # +# This library is shared among all the consumers of PMI to provide a +# single point for initializing and shutting down PMI. +# +# This is not a component in the traditional sense. It is a library +# (either rolled into libmpi if the components are rolled into libmpi +# or a stand-alone library). Users of this "component" must +# explicitly link against libmca_common_pmi.la when building +# stand-alone libraries (it won't hurt to do so in all cases). +# +# Note that building this common component statically and linking +# against other dynamic components is *not* supported! + AM_CPPFLAGS = $(common_pmi_CPPFLAGS) -sources = common_pmi.h common_pmi.c - -# Make the output library in this directory, and name it either -# mca__.la (for DSO builds) or libmca__.la -# (for static builds). - +# control whether building an installed library or a convenience +# (noinst) library if MCA_BUILD_orte_common_pmi_DSO component_noinst = -component_install = mca_common_pmi.la +component_install = libmca_common_pmi.la else component_noinst = libmca_common_pmi.la component_install = endif -mcacomponentdir = $(pkglibdir) -mcacomponent_LTLIBRARIES = $(component_install) -mca_common_pmi_la_SOURCES = $(sources) -mca_common_pmi_la_LDFLAGS = -module -avoid-version $(common_pmi_LDFLAGS) -mca_common_pmi_la_LIBADD = $(common_pmi_LIBS) - +lib_LTLIBRARIES = $(component_install) noinst_LTLIBRARIES = $(component_noinst) -libmca_common_pmi_la_SOURCES =$(sources) +libmca_common_pmi_la_SOURCES = common_pmi.h common_pmi.c libmca_common_pmi_la_LDFLAGS = -module -avoid-version $(common_pmi_LDFLAGS) libmca_common_pmi_la_LIBADD = $(common_pmi_LIBS) diff --git a/orte/mca/ess/pmi/Makefile.am b/orte/mca/ess/pmi/Makefile.am index 2233cd0e0b..f1ab2e5084 100644 --- a/orte/mca/ess/pmi/Makefile.am +++ b/orte/mca/ess/pmi/Makefile.am @@ -30,7 +30,8 @@ mcacomponentdir = $(pkglibdir) mcacomponent_LTLIBRARIES = $(component_install) mca_ess_pmi_la_SOURCES = $(sources) mca_ess_pmi_la_LDFLAGS = -module -avoid-version $(ess_pmi_LDFLAGS) -mca_ess_pmi_la_LIBADD = $(ess_pmi_LIBS) +mca_ess_pmi_la_LIBADD = $(ess_pmi_LIBS) \ + $(top_ompi_builddir)/orte/mca/common/pmi/libmca_common_pmi.la noinst_LTLIBRARIES = $(component_noinst) libmca_ess_pmi_la_SOURCES =$(sources) diff --git a/orte/mca/grpcomm/pmi/Makefile.am b/orte/mca/grpcomm/pmi/Makefile.am index 0a18f311ff..0ad79abf93 100644 --- a/orte/mca/grpcomm/pmi/Makefile.am +++ b/orte/mca/grpcomm/pmi/Makefile.am @@ -30,7 +30,8 @@ mcacomponentdir = $(pkglibdir) mcacomponent_LTLIBRARIES = $(component_install) mca_grpcomm_pmi_la_SOURCES = $(sources) mca_grpcomm_pmi_la_LDFLAGS = -module -avoid-version $(grpcomm_pmi_LDFLAGS) -mca_grpcomm_pmi_la_LIBADD = $(grpcomm_pmi_LIBS) +mca_grpcomm_pmi_la_LIBADD = $(grpcomm_pmi_LIBS) \ + $(top_ompi_builddir)/orte/mca/common/pmi/libmca_common_pmi.la noinst_LTLIBRARIES = $(component_noinst) libmca_grpcomm_pmi_la_SOURCES =$(sources)