CMake: use signed char for recastnavigation
External libraries may need char to be signed.
This commit is contained in:
@@ -1050,6 +1050,19 @@ macro(remove_strict_flags_file
|
|||||||
|
|
||||||
endmacro()
|
endmacro()
|
||||||
|
|
||||||
|
# External libs may need 'signed char' to be default.
|
||||||
|
macro(remove_cc_flag_unsigned_char)
|
||||||
|
if(CMAKE_C_COMPILER_ID MATCHES "^(GNU|Clang|Intel)$")
|
||||||
|
remove_cc_flag("-funsigned-char")
|
||||||
|
elseif(MSVC)
|
||||||
|
remove_cc_flag("/J")
|
||||||
|
else()
|
||||||
|
message(WARNING
|
||||||
|
"Compiler '${CMAKE_C_COMPILER_ID}' failed to disable 'unsigned char' flag."
|
||||||
|
"Build files need updating."
|
||||||
|
)
|
||||||
|
endif()
|
||||||
|
endmacro()
|
||||||
|
|
||||||
function(ADD_CHECK_C_COMPILER_FLAG
|
function(ADD_CHECK_C_COMPILER_FLAG
|
||||||
_CFLAGS
|
_CFLAGS
|
||||||
|
2
extern/recastnavigation/CMakeLists.txt
vendored
2
extern/recastnavigation/CMakeLists.txt
vendored
@@ -23,6 +23,8 @@
|
|||||||
#
|
#
|
||||||
# ***** END GPL LICENSE BLOCK *****
|
# ***** END GPL LICENSE BLOCK *****
|
||||||
|
|
||||||
|
remove_cc_flag_unsigned_char()
|
||||||
|
|
||||||
set(INC
|
set(INC
|
||||||
Recast/Include
|
Recast/Include
|
||||||
Detour/Include
|
Detour/Include
|
||||||
|
Reference in New Issue
Block a user