diff --git a/common/test/Makefile.am b/common/test/Makefile.am
index aa7596fc967da82027b64045e3001848a056d37d..b44d09be68475442424cf14350a3dfbd4942e180 100644
--- a/common/test/Makefile.am
+++ b/common/test/Makefile.am
@@ -72,11 +72,11 @@ gcdlcdtest_DEPENDENCIES = $(LOCAL_LIBS)
 
 mpihelpertest_SOURCES = mpihelpertest.cc
 mpihelpertest_CXXFLAGS = $(MPI_CPPFLAGS)
-mpihelpertest_LDFLAGS = $(MPI_LDFLAGS) $(MPI_LIBS)
+mpihelpertest_LDFLAGS = $(LOCAL_LIBS) $(MPI_LDFLAGS) $(MPI_LIBS)
 
 mpicollcomm_SOURCES = mpicollectivecommunication.cc
 mpicollcomm_CXXFLAGS = $(MPI_CPPFLAGS)
-mpicollcomm_LDFLAGS = $(MPI_LDFLAGS) $(MPI_LIBS)
+mpicollcomm_LDFLAGS =  $(LOCAL_LIBS) $(MPI_LDFLAGS) $(MPI_LIBS)
 
 singletontest_SOURCES = singletontest.cc
 singletontest_LDFLAGS = $(LOCAL_LIBS)