From 688f90a0495a7879e531d100645ecdf9efe47b94 Mon Sep 17 00:00:00 2001 From: Augustin Degomme Date: Tue, 9 Jun 2020 11:28:50 +0200 Subject: [PATCH] don't throw in smpi_helpers when passing configure, it may confuse some checkers petsc fails detection of getcwd and others, because we are pulling them in our header with a different signature --- src/smpi/smpicc.in | 4 ++-- src/smpi/smpicxx.in | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/smpi/smpicc.in b/src/smpi/smpicc.in index 1fc90eb6b2..e0487db70b 100755 --- a/src/smpi/smpicc.in +++ b/src/smpi/smpicc.in @@ -29,9 +29,9 @@ if [ "x@WIN32@" = "x1" ]; then list_add CFLAGS "-include" "@includedir@/smpi/smpi_main.h" list_add LINKARGS "@libdir@\libsimgrid.dll" elif [ "x@APPLE@" = "x1" ]; then - list_add CFLAGS "-include" "@includedir@/smpi/smpi_helpers.h" list_add CFLAGS "-fPIC" if [ "x${SMPI_PRETEND_CC}" = "x" ]; then + list_add CFLAGS "-include" "@includedir@/smpi/smpi_helpers.h" list_add LINKARGS "-shared" else echo "Warning: smpicc pretends to be a regular compiler (SMPI_PRETEND_CC is set). Produced binaries will not be usable in SimGrid." @@ -40,9 +40,9 @@ elif [ "x@APPLE@" = "x1" ]; then list_add LINKARGS "-lsimgrid" ${LINKER_UNDEFINED_ERROR:+"-Wl,-undefined,error"} fi else - list_add CFLAGS "-include" "@includedir@/smpi/smpi_helpers.h" list_add CFLAGS "-fPIC" if [ "x${SMPI_PRETEND_CC}" = "x" ]; then + list_add CFLAGS "-include" "@includedir@/smpi/smpi_helpers.h" list_add LINKARGS "-shared" else echo "Warning: smpicc pretends to be a regular compiler (SMPI_PRETEND_CC is set). Produced binaries will not be usable in SimGrid." diff --git a/src/smpi/smpicxx.in b/src/smpi/smpicxx.in index 2ef3b5e64f..16e8ec06a7 100755 --- a/src/smpi/smpicxx.in +++ b/src/smpi/smpicxx.in @@ -29,9 +29,9 @@ if [ "x@WIN32@" = "x1" ]; then list_add CXXFLAGS "-include" "@includedir@/smpi/smpi_main.h" list_add LINKARGS "@libdir@\libsimgrid.dll" elif [ "x@APPLE@" = "x1" ]; then - list_add CXXFLAGS "-include" "@includedir@/smpi/smpi_helpers.h" list_add CXXFLAGS "-fPIC" if [ "x${SMPI_PRETEND_CC}" = "x" ]; then + list_add CXXFLAGS "-include" "@includedir@/smpi/smpi_helpers.h" list_add LINKARGS "-shared" else echo "Warning: smpicc pretends to be a regular compiler (SMPI_PRETEND_CC is set). Produced binaries will not be usable in SimGrid." @@ -40,9 +40,9 @@ elif [ "x@APPLE@" = "x1" ]; then list_add LINKARGS "-lsimgrid" ${LINKER_UNDEFINED_ERROR:+"-Wl,-undefined,error"} fi else - list_add CXXFLAGS "-include" "@includedir@/smpi/smpi_helpers.h" list_add CXXFLAGS "-fPIC" if [ "x${SMPI_PRETEND_CC}" = "x" ]; then + list_add CXXFLAGS "-include" "@includedir@/smpi/smpi_helpers.h" list_add LINKARGS "-shared" else echo "Warning: smpicc pretends to be a regular compiler (SMPI_PRETEND_CC is set). Produced binaries will not be usable in SimGrid." -- 2.20.1