Skip to content

Commit

Permalink
Ignore case of CMAKE_BUILD_TYPE in CompileOptions
Browse files Browse the repository at this point in the history
  • Loading branch information
mav-intel committed Dec 19, 2023
1 parent 44df6e0 commit a3bf65e
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion cmake/CompileOptions.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,8 @@ else()
add_compile_options("-Wformat-security")
add_compile_options("-Werror=format-security")
if(NOT MINGW)
if(NOT CMAKE_BUILD_TYPE MATCHES Debug)
string(TOLOWER ${CMAKE_BUILD_TYPE} CMAKE_BUILD_TYPE)
if(NOT CMAKE_BUILD_TYPE MATCHES debug)
add_definitions("-D_FORTIFY_SOURCE=2")
endif()
endif()
Expand Down

0 comments on commit a3bf65e

Please sign in to comment.