mirror of
https://github.com/reactos/reactos.git
synced 2025-07-31 11:02:16 +00:00
[CMAKE] Some options are only supported by GCC, don't use them for clang
These are (so far): -Wno-format-overflow -Wno-nonnull-compare -Wno-old-style-declaration -Wno-unused-but-set-variable
This commit is contained in:
parent
959729f6ee
commit
74ec94e12c
35 changed files with 99 additions and 57 deletions
|
@ -53,8 +53,11 @@ add_importlibs(browseui uxtheme shlwapi shell32 comctl32 gdi32 ole32 oleaut32 us
|
|||
add_pch(browseui precomp.h "${PCH_SKIP_SOURCE}")
|
||||
add_cd_file(TARGET browseui DESTINATION reactos/system32 FOR all)
|
||||
|
||||
if(CMAKE_C_COMPILER_ID STREQUAL "GNU")
|
||||
target_compile_options(browseui PRIVATE -Wno-unused-but-set-variable)
|
||||
endif()
|
||||
|
||||
if(NOT MSVC)
|
||||
target_compile_options(browseui PRIVATE "-Wno-unused-but-set-variable")
|
||||
# Binutils linker bug
|
||||
if(LTCG)
|
||||
add_target_link_flags(browseui "-Wl,--allow-multiple-definition")
|
||||
|
|
|
@ -14,8 +14,8 @@ list(APPEND SOURCE
|
|||
add_library(shellbars OBJECT ${SOURCE})
|
||||
target_link_libraries(shellbars PRIVATE atl_classes)
|
||||
|
||||
if(NOT MSVC)
|
||||
target_compile_options(shellbars PRIVATE "-Wno-unused-but-set-variable")
|
||||
if(CMAKE_C_COMPILER_ID STREQUAL "GNU")
|
||||
target_compile_options(shellbars PRIVATE -Wno-unused-but-set-variable)
|
||||
endif()
|
||||
|
||||
add_pch(shellbars shellbars.h SOURCE)
|
||||
|
|
|
@ -11,8 +11,8 @@ list(APPEND SOURCE
|
|||
add_library(shellfind OBJECT ${SOURCE})
|
||||
target_link_libraries(shellfind PRIVATE atl_classes)
|
||||
|
||||
if(NOT MSVC)
|
||||
target_compile_options(shellfind PRIVATE "-Wno-unused-but-set-variable")
|
||||
if(CMAKE_C_COMPILER_ID STREQUAL "GNU")
|
||||
target_compile_options(shellfind PRIVATE -Wno-unused-but-set-variable)
|
||||
endif()
|
||||
|
||||
add_pch(shellfind shellfind.h SOURCE)
|
||||
|
|
|
@ -33,8 +33,8 @@ add_importlibs(winmm advapi32 user32 msvcrt kernel32 ntdll)
|
|||
add_pch(winmm winemm.h SOURCE)
|
||||
add_cd_file(TARGET winmm DESTINATION reactos/system32 FOR all)
|
||||
|
||||
if(NOT MSVC)
|
||||
target_compile_options(winmm PRIVATE "-Wno-unused-but-set-variable")
|
||||
if(CMAKE_C_COMPILER_ID STREQUAL "GNU")
|
||||
target_compile_options(winmm PRIVATE -Wno-unused-but-set-variable)
|
||||
endif()
|
||||
|
||||
add_subdirectory(midimap)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue