feat: Introduce warning suppression option and update CMake presets
- Added YAZE_SUPPRESS_WARNINGS option to suppress compiler warnings for cleaner build output. - Updated CMakeLists.txt to apply warning suppression based on the new option. - Reorganized CMakePresets.json to simplify preset names and enhance clarity, including new presets for quiet and verbose builds. - Created documentation for the new CMake preset system, detailing usage and features.
This commit is contained in:
@@ -47,11 +47,13 @@ target_link_libraries(yaze_canvas PUBLIC
|
||||
SDL2::SDL2
|
||||
)
|
||||
|
||||
# Compiler-specific options
|
||||
if(MSVC)
|
||||
target_compile_options(yaze_canvas PRIVATE /W4)
|
||||
else()
|
||||
target_compile_options(yaze_canvas PRIVATE -Wall -Wextra -Wpedantic)
|
||||
# Compiler-specific options (respect global warning settings)
|
||||
if(NOT YAZE_SUPPRESS_WARNINGS)
|
||||
if(MSVC)
|
||||
target_compile_options(yaze_canvas PRIVATE /W4)
|
||||
else()
|
||||
target_compile_options(yaze_canvas PRIVATE -Wall -Wextra -Wpedantic)
|
||||
endif()
|
||||
endif()
|
||||
|
||||
# Add canvas to parent GUI library
|
||||
|
||||
Reference in New Issue
Block a user