f602d6d70d7a75040150477f6135d97f6736ec94
[alexxy/gromacs.git] / cmake / Platform / BlueGeneQ-static-XL-C.cmake
1
2 #=============================================================================
3 # Copyright 2010 Kitware, Inc.
4 # Copyright 2010 Todd Gamblin <tgamblin@llnl.gov>
5 # Copyright 2012 Julien Bigot <julien.bigot@cea.fr>
6 #
7 # Distributed under the OSI-approved BSD License (the "License");
8 # see accompanying file Copyright.txt for details.
9 #
10 # This software is distributed WITHOUT ANY WARRANTY; without even the
11 # implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
12 # See the License for more information.
13 #=============================================================================
14 # (To distribute this file outside of CMake, substitute the full
15 #  License text for the above reference.)
16
17 include(BlueGeneQ-static)
18 __BlueGeneQ_set_static_flags(XL C)
19 __BlueGeneQ_set_static_flags(XL CXX)
20
21 # This suppression stops the following information message from
22 # almost every source file at -O3:
23 #   1500-036: (I) The NOSTRICT option (default at OPT(3)) has the potential to alter the semantics of a program.  Please refer to documentation on the STRICT/NOSTRICT option for more information.
24 set(COMPILER_SUPPRESSION "-qsuppress=1500-036")
25
26 set(CMAKE_SYSTEM_NAME BlueGeneQ-static CACHE STRING "Cross-compiling for BlueGene/Q" FORCE)
27 # xl.ndebug is appropriate for production calculations. For debugging,
28 # use xl to add back error checks and assertions
29 set(CMAKE_C_COMPILER /bgsys/drivers/ppcfloor/comm/xl.ndebug/bin/mpixlc_r)
30 set(CMAKE_C_FLAGS_RELEASE "-O3 -DNDEBUG ${COMPILER_SUPPRESSION}" CACHE STRING "Compiler optimization flags")
31 set(CMAKE_CXX_COMPILER /bgsys/drivers/ppcfloor/comm/xl.ndebug/bin/mpixlcxx_r)
32 set(CMAKE_CXX_FLAGS_RELEASE "-O3 -DNDEBUG ${COMPILER_SUPPRESSION}" CACHE STRING "Compiler optimization flags")
33
34 mark_as_advanced(CMAKE_XL_CreateExportList) # No idea what spams this