diff options
author | Drew DeVault <sir@cmpwn.com> | 2017-10-23 21:48:31 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-10-23 21:48:31 -0400 |
commit | 5551bf92a90e77ee4d0dc14bb4d2fe043be85c66 (patch) | |
tree | f3b737ba214d90f402191c5c982bef61789bb551 | |
parent | Merge pull request #1425 from ggreer/grab-error (diff) | |
parent | Use add_compile_options instead of interpolation (diff) | |
download | sway-5551bf92a90e77ee4d0dc14bb4d2fe043be85c66.tar.gz sway-5551bf92a90e77ee4d0dc14bb4d2fe043be85c66.tar.zst sway-5551bf92a90e77ee4d0dc14bb4d2fe043be85c66.zip |
Merge pull request #1427 from ranisalt/patch-1
Use add_compile_options instead of interpolation
-rw-r--r-- | CMakeLists.txt | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index 95f539e7..b253f1fc 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt | |||
@@ -2,16 +2,12 @@ cmake_minimum_required(VERSION 3.1.0) | |||
2 | 2 | ||
3 | project(sway C) | 3 | project(sway C) |
4 | 4 | ||
5 | set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -g") | 5 | add_compile_options(-g) |
6 | set(CMAKE_C_STANDARD 99) | 6 | set(CMAKE_C_STANDARD 99) |
7 | set(CMAKE_C_EXTENSIONS OFF) | 7 | set(CMAKE_C_EXTENSIONS OFF) |
8 | set(CMAKE_POSITION_INDEPENDENT_CODE ON) | 8 | set(CMAKE_POSITION_INDEPENDENT_CODE ON) |
9 | set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/bin) | 9 | set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/bin) |
10 | set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wall") | 10 | add_compile_options(-Wall -Wextra -Wno-unused-parameter -Wno-unused-result -Werror) |
11 | set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wextra") | ||
12 | set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-unused-parameter") | ||
13 | set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-unused-result") | ||
14 | set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Werror") | ||
15 | 11 | ||
16 | list(INSERT CMAKE_MODULE_PATH 0 | 12 | list(INSERT CMAKE_MODULE_PATH 0 |
17 | ${CMAKE_CURRENT_SOURCE_DIR}/CMake | 13 | ${CMAKE_CURRENT_SOURCE_DIR}/CMake |