fortran: workaround Absoft linker issue
MTT found that the addition of the MPI_SIZEOF interfaces to mpif.h was causing a linker error with the Absoft compiler. Absoft is working on a fix, but we can workaround the issue for now. See comment in Makefile.am in this commit for a lengthy explanation. Refs trac:4917 This commit was SVN r32797. The following Trac tickets were found above: Ticket 4917 --> https://svn.open-mpi.org/trac/ompi/ticket/4917
Этот коммит содержится в:
родитель
9c788ff940
Коммит
318e3b426a
@ -81,11 +81,35 @@ libmpi_mpifh_la_SOURCES =
|
||||
# sizeof_f.f90 is generated based on some results from configure tests.
|
||||
CLEANFILES += sizeof_f.f90
|
||||
|
||||
nodist_libmpi_mpifh_la_SOURCES =
|
||||
# If we're building the MPI_SIZEOF interfaces, generate the source
|
||||
# code in sizeof_f.f90 (via a perl script). Normally, we'd just add
|
||||
# sizeof_f.f90 to the libmpi_mpif_la_SOURCES and be done with it.
|
||||
# However, since this is the first *actual Fortran* source that we've
|
||||
# added to libmpi_mpif_la_SOURCEs, this causes Libtool to use the
|
||||
# *Fortran* linker to create the final libmpi_mpif.la library
|
||||
# (vs. using the C linker, as it has done for years). This exposes an
|
||||
# unfortunate bug in the Absoft linker: it does not honor the order of
|
||||
# -Wl arguments, which basically causes the resulting libmpi_mpif.so
|
||||
# to be borked.
|
||||
#
|
||||
# To get around this, we compile sizeof_f.f90 into its own LT
|
||||
# convenience library, and then we LIBADD that convenience library
|
||||
# into the main libmpi_mpifh.la. In this way, we basically trick
|
||||
# Libtool into still using the C linker to create libmpi_mpif.la, and
|
||||
# our -Wl flags therefore don't get re-ordered.
|
||||
#
|
||||
# All this being said, we can't rely on Automake/Libtool not figuring
|
||||
# out this workaround indefinitely. So Jeff advised Absoft to fix
|
||||
# this bug in Sep 2014.
|
||||
noinst_LTLIBRARIES=
|
||||
if BUILD_FORTRAN_SIZEOF
|
||||
nodist_libmpi_mpifh_la_SOURCES += sizeof_f.f90
|
||||
noinst_LTLIBRARIES += libmpi_mpifh_sizeof.la
|
||||
libmpi_mpifh_sizeof_la_SOURCES = sizeof_f.f90
|
||||
libmpi_mpifh_la_LIBADD += libmpi_mpifh_sizeof.la
|
||||
endif
|
||||
sizeof_pl=$(top_srcdir)/ompi/mpi/fortran/base/gen-mpi-sizeof.pl
|
||||
|
||||
sizeof_pl = $(top_srcdir)/ompi/mpi/fortran/base/gen-mpi-sizeof.pl
|
||||
|
||||
sizeof_f.f90: $(top_builddir)/config.status
|
||||
sizeof_f.f90: $(sizeof_pl)
|
||||
sizeof_f.f90:
|
||||
|
Загрузка…
x
Ссылка в новой задаче
Block a user