ENH: more compiler flags
This commit is contained in:
parent
ed72b56512
commit
066d5259c0
|
@ -0,0 +1,12 @@
|
|||
SET (CMAKE_C_FLAGS_INIT "")
|
||||
SET (CMAKE_C_FLAGS_DEBUG_INIT "-g")
|
||||
SET (CMAKE_C_FLAGS_MINSIZEREL_INIT "-Os -DNDEBUG")
|
||||
SET (CMAKE_C_FLAGS_RELEASE_INIT "-O3 -DNDEBUG")
|
||||
SET (CMAKE_C_FLAGS_RELWITHDEBINFO_INIT "-O2 -g")
|
||||
|
||||
SET (CMAKE_CXX_FLAGS_INIT "")
|
||||
SET (CMAKE_CXX_FLAGS_DEBUG_INIT "-g")
|
||||
SET (CMAKE_CXX_FLAGS_MINSIZEREL_INIT "-Os -DNDEBUG")
|
||||
SET (CMAKE_CXX_FLAGS_RELEASE_INIT "-O3 -DNDEBUG")
|
||||
SET (CMAKE_CXX_FLAGS_RELWITHDEBINFO_INIT "-O2 -g")
|
||||
|
|
@ -24,6 +24,12 @@ IF(CMAKE_SYSTEM MATCHES "SunOS-5*.")
|
|||
SET(CMAKE_SHARED_LIBRARY_RUNTIME_C_FLAG "-Wl,-R")
|
||||
SET(CMAKE_SHARED_LIBRARY_RUNTIME_C_FLAG_SEP ":")
|
||||
SET(CMAKE_SHARED_LIBRARY_SONAME_C_FLAG "-Wl,-h")
|
||||
ELSE(CMAKE_COMPILER_IS_GNUCC)
|
||||
SET (CMAKE_C_FLAGS_INIT "")
|
||||
SET (CMAKE_C_FLAGS_DEBUG_INIT "-g")
|
||||
SET (CMAKE_C_FLAGS_MINSIZEREL_INIT "-O3 -DNDEBUG")
|
||||
SET (CMAKE_C_FLAGS_RELEASE_INIT "-O2 -DNDEBUG")
|
||||
SET (CMAKE_C_FLAGS_RELWITHDEBINFO_INIT "-O2")
|
||||
ENDIF(CMAKE_COMPILER_IS_GNUCC)
|
||||
IF(CMAKE_COMPILER_IS_GNUCXX)
|
||||
SET(CMAKE_SHARED_LIBRARY_CXX_FLAGS "-fPIC")
|
||||
|
@ -31,6 +37,12 @@ IF(CMAKE_SYSTEM MATCHES "SunOS-5*.")
|
|||
SET(CMAKE_SHARED_LIBRARY_RUNTIME_CXX_FLAG "-Wl,-R")
|
||||
SET(CMAKE_SHARED_LIBRARY_RUNTIME_CXX_FLAG_SEP ":")
|
||||
SET(CMAKE_SHARED_LIBRARY_SONAME_CXX_FLAG "-Wl,-h")
|
||||
ELSE(CMAKE_COMPILER_IS_GNUCXX)
|
||||
SET (CMAKE_CXX_FLAGS_INIT "")
|
||||
SET (CMAKE_CXX_FLAGS_DEBUG_INIT "-g")
|
||||
SET (CMAKE_CXX_FLAGS_MINSIZEREL_INIT "-O3 -DNDEBUG")
|
||||
SET (CMAKE_CXX_FLAGS_RELEASE_INIT "-O2 -DNDEBUG")
|
||||
SET (CMAKE_CXX_FLAGS_RELWITHDEBINFO_INIT "-O2")
|
||||
ENDIF(CMAKE_COMPILER_IS_GNUCXX)
|
||||
ENDIF(CMAKE_SYSTEM MATCHES "SunOS-5*.")
|
||||
|
||||
|
|
Loading…
Reference in New Issue