summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--CMakeLists.txt6
-rw-r--r--src/core/CMakeLists.txt1
-rw-r--r--src/ctrl/CMakeLists.txt1
-rw-r--r--src/rendering/CMakeLists.txt1
-rw-r--r--src/resources/CMakeLists.txt1
-rw-r--r--src/utils/CMakeLists.txt1
6 files changed, 7 insertions, 4 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 92f16aa..0f4bd69 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -64,14 +64,12 @@ endif()
set(DEFAULT_ARGS
-m64 # Target 64-bit architechture
-Wall -Wextra # All the good default warnings
- -Wfloat-equal
-Wundef
-Wshadow
-Wpointer-arith
-Wcast-align
-Wstrict-prototypes
-Wwrite-strings
- -Wswitch-default
-Wconversion
)
@@ -127,8 +125,8 @@ FetchContent_MakeAvailable(cglm stb)
set(GLAD_HEADER ${CMAKE_BINARY_DIR}/include/glad/gl.h)
## Compilation information
-add_compile_options(${RELEASE_OPTS} ${BUILD_OPTS})
-add_link_options(${RELEASE_OPTS} ${BUILD_OPTS})
+add_compile_options(${RELEASE_OPTS})
+add_link_options(${RELEASE_OPTS})
# The main engine compilation target is defined here
add_subdirectory(src)
diff --git a/src/core/CMakeLists.txt b/src/core/CMakeLists.txt
index d67016b..100506a 100644
--- a/src/core/CMakeLists.txt
+++ b/src/core/CMakeLists.txt
@@ -13,6 +13,7 @@ add_library(daw_core
#set_property(SOURCE src/loop.c APPEND PROPERTY OBJECT_DEPENDS ${GLAD_HEADER})
+target_compile_options(daw_core PUBLIC ${BUILD_OPTS})
target_include_directories(daw_core PRIVATE ${DAW_INCLUDE_DIRS})
target_link_libraries(daw_core PRIVATE cglm)
diff --git a/src/ctrl/CMakeLists.txt b/src/ctrl/CMakeLists.txt
index e7dd0a9..a8525b0 100644
--- a/src/ctrl/CMakeLists.txt
+++ b/src/ctrl/CMakeLists.txt
@@ -6,5 +6,6 @@ add_library(daw_ctrl
src/mouse.c
)
+target_compile_options(daw_ctrl PUBLIC ${BUILD_OPTS})
target_include_directories(daw_ctrl PRIVATE ${DAW_INCLUDE_DIRS})
target_link_libraries(daw_ctrl PRIVATE cglm glfw)
diff --git a/src/rendering/CMakeLists.txt b/src/rendering/CMakeLists.txt
index f19cce0..237f147 100644
--- a/src/rendering/CMakeLists.txt
+++ b/src/rendering/CMakeLists.txt
@@ -21,6 +21,7 @@ add_custom_command(
set_property(SOURCE src/window.c APPEND PROPERTY OBJECT_DEPENDS ${GLAD_HEADER})
set_property(SOURCE src/rendering.c APPEND PROPERTY OBJECT_DEPENDS ${GLAD_HEADER})
+target_compile_options(daw_rendering PUBLIC ${BUILD_OPTS})
target_include_directories(daw_rendering PRIVATE ${DAW_INCLUDE_DIRS})
target_link_libraries(daw_rendering PRIVATE
OpenGL::GL
diff --git a/src/resources/CMakeLists.txt b/src/resources/CMakeLists.txt
index 8fd9413..9934cc1 100644
--- a/src/resources/CMakeLists.txt
+++ b/src/resources/CMakeLists.txt
@@ -13,6 +13,7 @@ add_library(daw_resources
src/model.c
)
+target_compile_options(daw_resources PUBLIC ${BUILD_OPTS})
target_include_directories(daw_resources PRIVATE ${DAW_INCLUDE_DIRS})
target_link_libraries(daw_resources PRIVATE
assimp
diff --git a/src/utils/CMakeLists.txt b/src/utils/CMakeLists.txt
index 64f5586..5e4d0d9 100644
--- a/src/utils/CMakeLists.txt
+++ b/src/utils/CMakeLists.txt
@@ -7,4 +7,5 @@ add_library(daw_utils
src/vector.c
)
+target_compile_options(daw_utils PUBLIC ${BUILD_OPTS})
target_include_directories(daw_utils PRIVATE ${DAW_INCLUDE_DIRS})