Changeset 3113
- Timestamp:
- 02/08/17 21:07:11 (8 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/CMakeLists.txt
r3108 r3113 68 68 add_definitions( -DAIPS_DEBUG ) 69 69 endif() 70 set( CMAKE_CXX_FLAGS_DEBUG "-ggdb3 -O0 -fno-omit-frame-pointer" ) 70 set( CMAKE_CXX_FLAGS_DEBUG " -O0" ) 71 if (NOT "${CMAKE_CXX_COMPILER_ID}" STREQUAL "Intel") 72 set( CMAKE_CXX_FLAGS_DEBUG "-ggdb3 -fno-omit-frame-pointer" ) 73 endif( ) 71 74 72 75 # flags for Profile build … … 104 107 # default flags 105 108 if( APPLE ) 106 set( DEFAULT_CXX_FLAGS "-pipe -Wall -Wextra -W cast-align -Wno-comment" )109 set( DEFAULT_CXX_FLAGS "-pipe -Wall -Wextra -Wno-comment" ) 107 110 else () 108 set( DEFAULT_CXX_FLAGS "-pipe -Wall -Wextra -Wno-non-template-friend -Wcast-align -Wno-comment" ) 109 endif() 111 set( DEFAULT_CXX_FLAGS "-pipe -Wall -Wextra -Wno-comment" ) 112 endif() 113 if (NOT "${CMAKE_CXX_COMPILER_ID}" STREQUAL "Intel") 114 set( DEFAULT_CXX_FLAGS "${DEFAULT_CXX_FLAGS} -Wcast-align" ) 115 if (NOT APPLE) 116 set( DEFAULT_CXX_FLAGS "${DEFAULT_CXX_FLAGS} -Wno-non-template-friend" ) 117 endif( ) 118 endif( ) 110 119 111 120 # additional flag for fortran complex div/mul rules. … … 131 140 endif() 132 141 142 if ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "Intel") 143 ## setting intel libraries with e.g. 144 ## 145 ## find_library( INTEL_IRNG irng HINTS ${INTEL_PATH} ) 146 ## 147 ## causes CMAKE to substitute fully qualified paths which makes 148 ## python shared object unrelocatable in the case of libirng.so 149 ## 150 get_filename_component(INTEL_PATH ${CMAKE_CXX_COMPILER} DIRECTORY) 151 set(INTEL_LIB_PATH ${INTEL_PATH}/../lib/intel64) 152 set(INTEL_LIBS -limf -lsvml -lirng -lintlc -lifport -lifcore -liomp5) 153 set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -Wl,-rpath,${INTEL_LIB_PATH}") 154 set(CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} -Wl,-rpath,${INTEL_LIB_PATH}") 155 endif() 156 133 157 find_package( OpenMP ) 134 158 if( OPENMP_FOUND ) 135 set( DEFAULT_CXX_FLAGS "${DEFAULT_CXX_FLAGS} ${OpenMP_CXX_FLAGS}" ) 159 if ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "Intel") 160 set(DEFAULT_CXX_FLAGS "${DEFAULT_CXX_FLAGS} -qopenmp") 161 else( ) 162 set( DEFAULT_CXX_FLAGS "${DEFAULT_CXX_FLAGS} ${OpenMP_CXX_FLAGS}" ) 163 endif( ) 136 164 endif() 137 165 … … 606 634 set( CMAKE_SHARED_LINKER_FLAGS "-Wl,-undefined -Wl,error -framework AppKit" ) 607 635 else() 608 set( CMAKE_SHARED_LINKER_FLAGS " -Wl,-undefined -Wl,error" )636 set( CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} -Wl,-undefined -Wl,error" ) 609 637 endif() 610 638 endif()
Note:
See TracChangeset
for help on using the changeset viewer.