make charm++ compilable with mpich-gm.
authorGengbin Zheng <gzheng@illinois.edu>
Sun, 16 Jan 2005 05:22:23 +0000 (05:22 +0000)
committerGengbin Zheng <gzheng@illinois.edu>
Sun, 16 Jan 2005 05:22:23 +0000 (05:22 +0000)
src/arch/mpi-darwin-ppc/conv-mach-gm.h [new file with mode: 0644]
src/arch/mpi-darwin-ppc/conv-mach-gm.sh [new file with mode: 0644]
src/arch/mpi-darwin-ppc/conv-mach.sh

diff --git a/src/arch/mpi-darwin-ppc/conv-mach-gm.h b/src/arch/mpi-darwin-ppc/conv-mach-gm.h
new file mode 100644 (file)
index 0000000..e69de29
diff --git a/src/arch/mpi-darwin-ppc/conv-mach-gm.sh b/src/arch/mpi-darwin-ppc/conv-mach-gm.sh
new file mode 100644 (file)
index 0000000..c360a09
--- /dev/null
@@ -0,0 +1,13 @@
+#default gm dir
+#guess where the gm.h is installed
+if test -z "$CMK_INCDIR"
+then
+  if test -f /turing/software/gm-2.0.15/include/gm.h
+  then
+    CMK_INCDIR="-I/turing/software/gm-2.0.15/include "
+    CMK_LIBDIR="-L/turing/software/gm-2.0.15/lib "
+  fi
+fi
+
+
+CMK_SYSLIBS="$CMK_SYSLIBS -lgm"
index 72cb9ef10f83a82d20acb626175f69a526c61357..3c797ec678d3d909ea2491ee990a227c2488de95 100644 (file)
@@ -1,27 +1,36 @@
-CMK_CPP_CHARM='/lib/cpp -P'
-CMK_CPP_C='mpicc -E'
-CMK_CC='mpicc -Wno-long-double -fPIC -dynamic -fno-common '
-CMK_CXX='mpicxx -Wno-long-double -fPIC -dynamic -fno-common '
-CMK_CXXPP='mpicxx -E '
-CMK_LDXX="$CMK_CXX -multiply_defined suppress "
-CMK_LIBS='-lckqt -lmpich '
-CMK_RANLIB='ranlib'
+# preprocess mpicxx which include mpich before ampi
+# this default conv-mach does not work with linking ampi
+
+CMK_CPP_CHARM="/lib/cpp -P"
+CMK_CPP_C="mpicc -E"
+OPTS_CC="$OPTS_CC -Wno-long-double -dynamic -fno-common "
+CMK_CC="mpicc -fPIC "
+#CMK_CXX="/private/automount/home/gzheng/csar/genx/build_charm_mpi/mpicxx -Wno-long-double -fPIC -dynamic -fno-common "
+OPTS_CXX="$OPTS_CXX -Wno-long-double -dynamic -fno-common "
+CMK_CXX="mpicxx -fPIC "
+CMK_CXXPP="mpicxx -E "
+OPTS_LD="$OPTS_LD -multiply_defined suppress -flat_namespace -Wl,-u,_gmpi_macosx_malloc_hack  "
+CMK_LD="$CMK_CC "
+OPTS_LDXX="$OPTS_LDXX -multiply_defined suppress -flat_namespace -Wl,-u,_gmpi_macosx_malloc_hack  "
+CMK_LDXX="$CMK_CXX "
+CMK_LIBS="-lckqt -lmpich -lpmpich"
+CMK_RANLIB="ranlib"
 
 # Assumes IBM xlf90 compiler:
-CMK_CF77='f77'
-CMK_CF90='f90 -qnocommon -qextname '
+CMK_CF77="f77"
+CMK_CF90="f90 -qnocommon -qextname "
 CMK_CF90_FIXED="xlf90 -qnocommon -qextname -qsuffix=f=f"
 CMK_F90LIBS="-L/opt/ibmcmp/xlf/8.1/lib -lxlf90 -lxlopt -lxl -lxlfmath"
 CMK_MOD_EXT="mod"
 
 # native compilers
-CMK_NATIVE_LIBS=''
-CMK_NATIVE_CC='gcc '
-CMK_NATIVE_LD='gcc'
-CMK_NATIVE_CXX='g++ '
-CMK_NATIVE_LDXX='g++'
-CMK_NATIVE_CC='gcc '
-CMK_NATIVE_CXX='g++ '
+CMK_NATIVE_LIBS=""
+CMK_NATIVE_CC="gcc "
+CMK_NATIVE_LD="gcc"
+CMK_NATIVE_CXX="g++ "
+CMK_NATIVE_LDXX="g++"
+CMK_NATIVE_CC="gcc "
+CMK_NATIVE_CXX="g++ "
 
 # setting for shared lib
 # need -lstdc++ for c++ reference, and it needs to be put at very last
@@ -29,7 +38,7 @@ CMK_NATIVE_CXX='g++ '
 # need 10.3 in this Mac environment varaible
 export MACOSX_DEPLOYMENT_TARGET=10.3
 CMK_SHARED_SUF="dylib"
-CMK_LD_SHARED=" -dynamic -dynamiclib -undefined dynamic_lookup -single_module"
+CMK_LD_SHARED=" -dynamic -dynamiclib -flat_namespace -undefined dynamic_lookup "
 CMK_LD_SHARED_LIBS="-lstdc++"
 CMK_LD_SHARED_ABSOLUTE_PATH=true