diff options
author | Brent Cook <busterb@gmail.com> | 2018-11-09 18:29:06 -0600 |
---|---|---|
committer | Brent Cook <busterb@gmail.com> | 2018-11-09 18:29:06 -0600 |
commit | e7d11baaae1ff9a4f4061c9ea9bf66cb4a452b33 (patch) | |
tree | c342b82a6bafebf8b5a3666d128b19e0be796254 /CMakeLists.txt | |
parent | f5ec56f4c572e1f0806c4a1d480fa71982f219e2 (diff) | |
download | portable-e7d11baaae1ff9a4f4061c9ea9bf66cb4a452b33.tar.gz portable-e7d11baaae1ff9a4f4061c9ea9bf66cb4a452b33.tar.bz2 portable-e7d11baaae1ff9a4f4061c9ea9bf66cb4a452b33.zip |
enable optimizations for all cmake builds
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r-- | CMakeLists.txt | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index 8fde8cf..caf55c1 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt | |||
@@ -66,19 +66,21 @@ if(WIN32) | |||
66 | set(BUILD_NC false) | 66 | set(BUILD_NC false) |
67 | endif() | 67 | endif() |
68 | 68 | ||
69 | set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -O2 -Wall -g") | ||
70 | |||
69 | if(CMAKE_SYSTEM_NAME MATCHES "HP-UX") | 71 | if(CMAKE_SYSTEM_NAME MATCHES "HP-UX") |
70 | if(CMAKE_C_COMPILER MATCHES "gcc") | 72 | if(CMAKE_C_COMPILER MATCHES "gcc") |
71 | set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wall -std=gnu99 -fno-strict-aliasing") | 73 | set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -std=gnu99 -fno-strict-aliasing") |
72 | set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -mlp64") | 74 | set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -mlp64") |
73 | else() | 75 | else() |
74 | set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -g -O2 +DD64 +Otype_safety=off") | 76 | set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} +DD64 +Otype_safety=off") |
75 | endif() | 77 | endif() |
76 | set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -D_XOPEN_SOURCE=600 -D__STRICT_ALIGNMENT") | 78 | set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -D_XOPEN_SOURCE=600 -D__STRICT_ALIGNMENT") |
77 | set(PLATFORM_LIBS ${PLATFORM_LIBS} pthread) | 79 | set(PLATFORM_LIBS ${PLATFORM_LIBS} pthread) |
78 | endif() | 80 | endif() |
79 | 81 | ||
80 | if(CMAKE_SYSTEM_NAME MATCHES "SunOS") | 82 | if(CMAKE_SYSTEM_NAME MATCHES "SunOS") |
81 | set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wall -std=gnu99 -fno-strict-aliasing") | 83 | set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -std=gnu99 -fno-strict-aliasing") |
82 | set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -D__EXTENSIONS__") | 84 | set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -D__EXTENSIONS__") |
83 | set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -D_XOPEN_SOURCE=600") | 85 | set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -D_XOPEN_SOURCE=600") |
84 | set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -DBSD_COMP") | 86 | set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -DBSD_COMP") |