mirror of
https://github.com/reactos/reactos.git
synced 2025-05-04 18:31:40 +00:00
[CMAKE] Add memcmp to libntoskrnl for both clang and clang-cl
This commit is contained in:
parent
03506b90e0
commit
5176f580e5
2 changed files with 6 additions and 2 deletions
|
@ -28,7 +28,7 @@ endif()
|
|||
|
||||
add_asm_files(ntoskrnl_asm ${NTOSKRNL_ASM_SOURCE})
|
||||
|
||||
if (GCC AND CLANG)
|
||||
if(CMAKE_C_COMPILER_ID STREQUAL "Clang")
|
||||
# Clang optimises strcmp calls to memcmp.
|
||||
target_sources(libntoskrnl PRIVATE $<TARGET_OBJECTS:memcmp>)
|
||||
endif()
|
||||
|
|
|
@ -1,6 +1,10 @@
|
|||
|
||||
if(CMAKE_BUILD_TYPE STREQUAL "Release")
|
||||
add_compile_options(/Ox /Ob2 /Ot /Oy /GT)
|
||||
add_compile_options(/Ox /Ob2 /Ot /Oy)
|
||||
# Avoid spam in clang-cl as it doesn't support /GT
|
||||
if(CMAKE_C_COMPILER_ID STREQUAL "MSVC")
|
||||
add_compile_options(/GT)
|
||||
endif()
|
||||
elseif(OPTIMIZE STREQUAL "1")
|
||||
add_compile_options(/O1)
|
||||
elseif(OPTIMIZE STREQUAL "2")
|
||||
|
|
Loading…
Reference in a new issue