Ticket #32716: patch-upstream-clang-detection.diff
File patch-upstream-clang-detection.diff, 1011 bytes (added by mojca (Mojca Miklavec), 12 years ago) |
---|
-
cmake/Modules/Geant4LibraryBuildOptions.cmake
old new endif() 171 171 # 172 172 if(CMAKE_COMPILER_IS_GNUCXX) 173 173 set(GEANT4_COMPILER "g++") 174 elseif(CMAKE_CXX_COMPILER_ID MATCHES "Clang") 175 set(GEANT4_COMPILER "clang") 174 176 elseif(MSVC) 175 177 set(GEANT4_COMPILER "VC") 176 178 elseif(CMAKE_CXX_COMPILER MATCHES "icpc.*|icc.*") -
cmake/Modules/Geant4MakeRules_cxx.cmake
old new message(STATUS "setting default compiler flags for CXX") 9 9 #------------------------------------------------------------------------------ 10 10 # GNU C++ Compiler on all(?) platforms 11 11 # 12 if(CMAKE_COMPILER_IS_GNUCXX )12 if(CMAKE_COMPILER_IS_GNUCXX OR CMAKE_CXX_COMPILER_ID MATCHES "Clang") 13 13 set(CMAKE_CXX_FLAGS_INIT "-W -Wall -ansi -pedantic -Wno-non-virtual-dtor -Wno-long-long -Wwrite-strings -Wpointer-arith -Woverloaded-virtual -pipe") 14 14 set(CMAKE_CXX_FLAGS_DEBUG_INIT "-g") 15 15 set(CMAKE_CXX_FLAGS_RELEASE_INIT "-O2 -DNDEBUG")