Commit 4f898a74 authored by Philip Carns's avatar Philip Carns

update all of the fortran compilers to list the darshan libraries twice

in the link order; following the lead of mpixlf90


git-svn-id: https://svn.mcs.anl.gov/repos/darshan/trunk@26 3b7491f3-a168-0410-bf4b-c445ed680a29
parent cd78c10f
......@@ -51,7 +51,7 @@ WRAPPER_FFLAGS="-I/bgsys/drivers/V1R3M0_460_2008-081112P/ppc/comm/sys/include"
WRAPPER_LDFLAGS="${CP_WRAPPERS}"
MPILIBNAME="mpich.cnk"
PMPILIBNAME="pmpich.cnk"
MPI_OTHERLIBS=" -L/bgsys/drivers/V1R3M0_460_2008-081112P/ppc/comm/sys/lib -Wl,-rpath,/bgsys/drivers/V1R3M0_460_2008-081112P/ppc/comm/sys/lib -ldcmfcoll.cnk -ldcmf.cnk -lpthread -L/bgsys/drivers/V1R3M0_460_2008-081112P/ppc/runtime/SPI -Wl,-rpath,/bgsys/drivers/V1R3M0_460_2008-081112P/ppc/runtime/SPI -lSPI.cna -lrt -L${DARSHAN_LIB_PATH} -ldarshan-posix "
MPI_OTHERLIBS=" -L/bgsys/drivers/V1R3M0_460_2008-081112P/ppc/comm/sys/lib -Wl,-rpath,/bgsys/drivers/V1R3M0_460_2008-081112P/ppc/comm/sys/lib -ldcmfcoll.cnk -ldcmf.cnk -lpthread -L/bgsys/drivers/V1R3M0_460_2008-081112P/ppc/runtime/SPI -Wl,-rpath,/bgsys/drivers/V1R3M0_460_2008-081112P/ppc/runtime/SPI -lSPI.cna -lrt"
NEEDSPLIB="no"
#
# MPIVERSION is the version of the MPICH2 library for which mpif77 is intended
......@@ -276,7 +276,13 @@ if [ "$linking" = yes ] ; then
# Prepend the path for the shared libraries to the library list
mpilibs="$FC_LINKPATH_SHL$libdir $mpilibs"
fi
$Show $FC $FFLAGS $LDFLAGS "${allargs[@]}" -L${DARSHAN_LIB_PATH} -lfmpich.cnk -ldarshan-mpi-io -lz -I$includedir -L$libdir $mpilibs $MPI_OTHERLIBS
# If we link link darshan-mpi-io before system mpi lib, we don't get a
# trace but if we don't link it early enough, we get undefined MPI symbols.
# Seems like listing the darshan libs twice does the trick
$Show $FC $FFLAGS $LDFLAGS "${allargs[@]}" -L${DARSHAN_LIB_PATH} -lfmpich.cnk\
-ldarshan-posix -ldarshan-mpi-io \
-I$includedir -L$libdir $mpilibs $MPI_OTHERLIBS \
-L${DARSHAN_LIB_PATH} -ldarshan-posix -ldarshan-mpi-io -lz
rc=$?
else
$Show $FC "${allargs[@]}" -I$includedir $FFLAGS
......
......@@ -50,7 +50,7 @@ WRAPPER_FFLAGS="-I/bgsys/drivers/V1R3M0_460_2008-081112P/ppc/comm/sys/include"
WRAPPER_LDFLAGS="${CP_WRAPPERS}"
MPILIBNAME="mpich.cnk"
PMPILIBNAME="pmpich.cnk"
MPI_OTHERLIBS=" -L/bgsys/drivers/V1R3M0_460_2008-081112P/ppc/comm/sys/lib -Wl,-rpath,/bgsys/drivers/V1R3M0_460_2008-081112P/ppc/comm/sys/lib -ldcmfcoll.cnk -ldcmf.cnk -lpthread -L/bgsys/drivers/V1R3M0_460_2008-081112P/ppc/runtime/SPI -Wl,-rpath,/bgsys/drivers/V1R3M0_460_2008-081112P/ppc/runtime/SPI -lSPI.cna -lrt -L${DARSHAN_LIB_PATH} -ldarshan-posix "
MPI_OTHERLIBS=" -L/bgsys/drivers/V1R3M0_460_2008-081112P/ppc/comm/sys/lib -Wl,-rpath,/bgsys/drivers/V1R3M0_460_2008-081112P/ppc/comm/sys/lib -ldcmfcoll.cnk -ldcmf.cnk -lpthread -L/bgsys/drivers/V1R3M0_460_2008-081112P/ppc/runtime/SPI -Wl,-rpath,/bgsys/drivers/V1R3M0_460_2008-081112P/ppc/runtime/SPI -lSPI.cna -lrt"
NEEDSPLIB="no"
#
# MPIVERSION is the version of the MPICH2 library for which mpif77 is intended
......@@ -275,7 +275,13 @@ if [ "$linking" = yes ] ; then
# Prepend the path for the shared libraries to the library list
mpilibs="$FC_LINKPATH_SHL$libdir $mpilibs"
fi
$Show $FC "${allargs[@]}" -I$includedir $FFLAGS $LDFLAGS -L${DARSHAN_LIB_PATH} -lfmpich.cnk -ldarshan-mpi-io -lz -L$libdir $mpilibs $MPI_OTHERLIBS
# If we link link darshan-mpi-io before system mpi lib, we don't get a
# trace but if we don't link it early enough, we get undefined MPI symbols.
# Seems like listing the darshan libs twice does the trick
$Show $FC "${allargs[@]}" -I$includedir $FFLAGS $LDFLAGS -L${DARSHAN_LIB_PATH} -lfmpich.cnk \
-ldarshan-posix -ldarshan-mpi-io \
-L$libdir $mpilibs $MPI_OTHERLIBS \
-L${DARSHAN_LIB_PATH} -ldarshan-posix -ldarshan-mpi-io -lz
rc=$?
else
$Show $FC "${allargs[@]}" -I$includedir $FFLAGS
......
......@@ -50,7 +50,7 @@ WRAPPER_FFLAGS="-I/bgsys/drivers/V1R3M0_460_2008-081112P/ppc/comm/sys/include"
WRAPPER_LDFLAGS="${CP_WRAPPERS}"
MPILIBNAME="mpich.cnk"
PMPILIBNAME="pmpich.cnk"
MPI_OTHERLIBS=" -L/bgsys/drivers/V1R3M0_460_2008-081112P/ppc/comm/sys/lib -Wl,-rpath,/bgsys/drivers/V1R3M0_460_2008-081112P/ppc/comm/sys/lib -ldcmfcoll.cnk -ldcmf.cnk -lpthread -L/bgsys/drivers/V1R3M0_460_2008-081112P/ppc/runtime/SPI -Wl,-rpath,/bgsys/drivers/V1R3M0_460_2008-081112P/ppc/runtime/SPI -lSPI.cna -lrt -L${DARSHAN_LIB_PATH} -ldarshan-posix "
MPI_OTHERLIBS=" -L/bgsys/drivers/V1R3M0_460_2008-081112P/ppc/comm/sys/lib -Wl,-rpath,/bgsys/drivers/V1R3M0_460_2008-081112P/ppc/comm/sys/lib -ldcmfcoll.cnk -ldcmf.cnk -lpthread -L/bgsys/drivers/V1R3M0_460_2008-081112P/ppc/runtime/SPI -Wl,-rpath,/bgsys/drivers/V1R3M0_460_2008-081112P/ppc/runtime/SPI -lSPI.cna -lrt"
NEEDSPLIB="no"
#
# MPIVERSION is the version of the MPICH2 library for which mpif77 is intended
......@@ -275,7 +275,13 @@ if [ "$linking" = yes ] ; then
# Prepend the path for the shared libraries to the library list
mpilibs="$FC_LINKPATH_SHL$libdir $mpilibs"
fi
$Show $FC "${allargs[@]}" -L${DARSHAN_LIB_PATH} -lfmpich.cnk -ldarshan-mpi-io -lz -I$includedir $FFLAGS $LDFLAGS -L$libdir $mpilibs $MPI_OTHERLIBS
# If we link link darshan-mpi-io before system mpi lib, we don't get a
# trace but if we don't link it early enough, we get undefined MPI symbols.
# Seems like listing the darshan libs twice does the trick
$Show $FC "${allargs[@]}" -L${DARSHAN_LIB_PATH} -lfmpich.cnk \
-ldarshan-posix -ldarshan-mpi-io \
-I$includedir $FFLAGS $LDFLAGS -L$libdir $mpilibs $MPI_OTHERLIBS \
-L${DARSHAN_LIB_PATH} -ldarshan-posix -ldarshan-mpi-io -lz
rc=$?
else
$Show $FC "${allargs[@]}" -I$includedir $FFLAGS
......
......@@ -50,7 +50,7 @@ WRAPPER_FFLAGS="-I/bgsys/drivers/V1R3M0_460_2008-081112P/ppc/comm/sys/include "
WRAPPER_LDFLAGS="${CP_WRAPPERS} "
MPILIBNAME="mpich.cnk"
PMPILIBNAME="pmpich.cnk"
MPI_OTHERLIBS=" -L/bgsys/drivers/V1R3M0_460_2008-081112P/ppc/comm/sys/lib -Wl,-rpath,/bgsys/drivers/V1R3M0_460_2008-081112P/ppc/comm/sys/lib -ldcmfcoll.cnk -ldcmf.cnk -lpthread -L/bgsys/drivers/V1R3M0_460_2008-081112P/ppc/runtime/SPI -Wl,-rpath,/bgsys/drivers/V1R3M0_460_2008-081112P/ppc/runtime/SPI -lSPI.cna -lrt -L${DARSHAN_LIB_PATH} -ldarshan-posix "
MPI_OTHERLIBS=" -L/bgsys/drivers/V1R3M0_460_2008-081112P/ppc/comm/sys/lib -Wl,-rpath,/bgsys/drivers/V1R3M0_460_2008-081112P/ppc/comm/sys/lib -ldcmfcoll.cnk -ldcmf.cnk -lpthread -L/bgsys/drivers/V1R3M0_460_2008-081112P/ppc/runtime/SPI -Wl,-rpath,/bgsys/drivers/V1R3M0_460_2008-081112P/ppc/runtime/SPI -lSPI.cna -lrt"
NEEDSPLIB="no"
#
# MPIVERSION is the version of the MPICH2 library for which mpif77 is intended
......@@ -275,7 +275,13 @@ if [ "$linking" = yes ] ; then
# Prepend the path for the shared libraries to the library list
mpilibs="$FC_LINKPATH_SHL$libdir $mpilibs"
fi
$Show $FC "${allargs[@]}" -L${DARSHAN_LIB_PATH} -lfmpich.cnk -ldarshan-mpi-io -lz -I$includedir $FFLAGS $LDFLAGS -L$libdir $mpilibs $MPI_OTHERLIBS
# If we link link darshan-mpi-io before system mpi lib, we don't get a
# trace but if we don't link it early enough, we get undefined MPI symbols.
# Seems like listing the darshan libs twice does the trick
$Show $FC "${allargs[@]}" -L${DARSHAN_LIB_PATH} -lfmpich.cnk \
-ldarshan-posix -ldarshan-mpi-io \
-I$includedir $FFLAGS $LDFLAGS -L$libdir $mpilibs $MPI_OTHERLIBS \
-L${DARSHAN_LIB_PATH} -ldarshan-posix -ldarshan-mpi-io -lz
rc=$?
else
$Show $FC "${allargs[@]}" -I$includedir $FFLAGS
......
......@@ -50,7 +50,7 @@ WRAPPER_FFLAGS="-I/bgsys/drivers/V1R3M0_460_2008-081112P/ppc/comm/sys/include"
WRAPPER_LDFLAGS="${CP_WRAPPERS}"
MPILIBNAME="mpich.cnk"
PMPILIBNAME="pmpich.cnk"
MPI_OTHERLIBS=" -L/bgsys/drivers/V1R3M0_460_2008-081112P/ppc/comm/sys/lib -Wl,-rpath,/bgsys/drivers/V1R3M0_460_2008-081112P/ppc/comm/sys/lib -ldcmfcoll.cnk -ldcmf.cnk -lpthread -L/bgsys/drivers/V1R3M0_460_2008-081112P/ppc/runtime/SPI -Wl,-rpath,/bgsys/drivers/V1R3M0_460_2008-081112P/ppc/runtime/SPI -lSPI.cna -lrt -L${DARSHAN_LIB_PATH} -ldarshan-posix "
MPI_OTHERLIBS=" -L/bgsys/drivers/V1R3M0_460_2008-081112P/ppc/comm/sys/lib -Wl,-rpath,/bgsys/drivers/V1R3M0_460_2008-081112P/ppc/comm/sys/lib -ldcmfcoll.cnk -ldcmf.cnk -lpthread -L/bgsys/drivers/V1R3M0_460_2008-081112P/ppc/runtime/SPI -Wl,-rpath,/bgsys/drivers/V1R3M0_460_2008-081112P/ppc/runtime/SPI -lSPI.cna -lrt"
NEEDSPLIB="no"
#
# MPIVERSION is the version of the MPICH2 library for which mpif77 is intended
......@@ -281,7 +281,7 @@ if [ "$linking" = yes ] ; then
$Show $FC "${allargs[@]}" -L${DARSHAN_LIB_PATH} -lfmpich.cnk \
-ldarshan-posix -ldarshan-mpi-io \
-I$includedir $FFLAGS $LDFLAGS -L$libdir $mpilibs $MPI_OTHERLIBS \
-ldarshan-posix -ldarshan-mpi-io -lz
-L${DARSHAN_LIB_PATH} -ldarshan-posix -ldarshan-mpi-io -lz
rc=$?
else
$Show $FC "${allargs[@]}" -I$includedir $FFLAGS
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment