Improve Gromacs portability
authorErik Lindahl <erik@kth.se>
Wed, 30 Jul 2014 12:34:32 +0000 (14:34 +0200)
committerGerrit Code Review <gerrit@gerrit.gromacs.org>
Sun, 10 Aug 2014 16:46:10 +0000 (18:46 +0200)
commit8b7f2d16750c2c433c4aaebeaf4123a1fccc10f4
tree55d324a83ce02daf91863bd26021613c4d4b9505
parentd5958252fb4116cfb6ad2081b7067b89f87c4e59
Improve Gromacs portability

This patch addresses a few general portability issues
that we have experienced at least on Fujitsu compilers
(K computer) and (partly) for Pathscale x86 compilers.
- I have added a generic compiler definition fallback
  for boost, so it will work on unidentified compilers.
- There is now  a define for gmock-1.7.0 to handle
  the case where wcscasecmp() is not available. We use
  this by default since it is not important for us.
- If we do not find atomics for sparc64 we now warn and
  fall back on mutexes rather than the compile dying.
- The compiler flag checks have been updated from
  cmake-3.0, and more warning checks added.
- Since some non-GCC compilers set _GNUC_ for
  compatibilty, we do not assume all such compilers
  support tr1, but use the internal tr1/tuple definition
  in Gmock by default.
- Before using the sched.h affinity functions, we now
  check that all the functions we need are supported,
  rather than just one of them.

Change-Id: I31b7f0f46a9d03a627c73a0789b4a9b24fa860ee
16 files changed:
CMakeLists.txt
cmake/CheckCCompilerFlag.cmake
cmake/CheckCXXCompilerFlag.cmake
cmake/TestSchedAffinity.cmake [moved from cmake/gmxGetMsvcTupleWorkaround.cmake with 57% similarity]
cmake/gmxGetGmockTupleWorkaround.cmake [new file with mode: 0644]
src/config.h.cmakein
src/external/boost/README
src/external/boost/boost/config/compiler/generic.hpp [new file with mode: 0644]
src/external/boost/boost/config/select_compiler_config.hpp
src/external/gmock-1.7.0/CMakeLists.txt
src/external/gmock-1.7.0/README.Gromacs
src/external/gmock-1.7.0/gtest/src/gtest.cc
src/external/thread_mpi/include/thread_mpi/atomic.h
src/gromacs/gmxlib/gmx_cpuid.c
src/gromacs/gmxlib/gmx_thread_affinity.c
src/gromacs/onlinehelp/helpwritercontext.cpp