mirror of
https://github.com/reactos/reactos.git
synced 2024-11-01 04:11:30 +00:00
[MKISOFS] Fix Clang check for macOS platforms (#7037)
* [MKISOFS] Fix Clang check for macOS platforms On macOS, CMAKE_C_COMPILER_ID is "AppleClang". While certainly Clang, this does not match the exact string "Clang" that is being checked for, and as a result the warning flags guarded thereby are not passed to the compiler. With this change CMake will recognize both Clang and AppleClang. * Update sdk/tools/mkisofs/CMakeLists.txt
This commit is contained in:
parent
90831e7451
commit
d4719197b2
|
@ -107,7 +107,8 @@ else()
|
||||||
# Silence compilers checking for invalid formatting sequences.
|
# Silence compilers checking for invalid formatting sequences.
|
||||||
target_compile_options(libschily PRIVATE "-Wno-format")
|
target_compile_options(libschily PRIVATE "-Wno-format")
|
||||||
|
|
||||||
if(CMAKE_C_COMPILER_ID STREQUAL "Clang" AND CMAKE_C_COMPILER_VERSION VERSION_GREATER_EQUAL "15")
|
# MATCHES must be used here because on macOS, CMake uses the compiler ID "AppleClang".
|
||||||
|
if(CMAKE_C_COMPILER_ID MATCHES "Clang$" AND CMAKE_C_COMPILER_VERSION VERSION_GREATER_EQUAL "15")
|
||||||
# mkisofs uses K&R-style function definitions to support very old compilers.
|
# mkisofs uses K&R-style function definitions to support very old compilers.
|
||||||
# This causes warnings with modern compilers.
|
# This causes warnings with modern compilers.
|
||||||
target_compile_options(libmdigest PRIVATE "-Wno-deprecated-non-prototype")
|
target_compile_options(libmdigest PRIVATE "-Wno-deprecated-non-prototype")
|
||||||
|
|
Loading…
Reference in a new issue