Skip to content

Commit

Permalink
Suppress warnings in externals
Browse files Browse the repository at this point in the history
  • Loading branch information
oktal3700 committed Nov 18, 2023
1 parent 86d0dc1 commit 86cc305
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
2 changes: 1 addition & 1 deletion cmake/rapidjson/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@
# SPDX-License-Identifier: GPL-3.0-or-later OR LicenseRef-swift-pilot-client-1

add_library(externals_rapidjson INTERFACE)
target_include_directories(externals_rapidjson INTERFACE ${PROJECT_SOURCE_DIR}/externals/common/include)
target_include_directories(externals_rapidjson SYSTEM INTERFACE ${PROJECT_SOURCE_DIR}/externals/common/include)
6 changes: 6 additions & 0 deletions src/xswiftbus/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -135,6 +135,12 @@ if(MSVC)
target_compile_definitions(xswiftbus PRIVATE _CRT_SECURE_NO_WARNINGS)
endif()

if(${CMAKE_CXX_COMPILER_ID} STREQUAL GNU)
add_compile_options(-Wno-missing-field-initializers -Wno-stringop-truncation)
elseif(${CMAKE_CXX_COMPILER_ID} MATCHES ".*Clang")
add_compile_options(-Wno-missing-field-initializers)
endif()

if(UNIX AND NOT APPLE)
target_compile_definitions(xswiftbus PUBLIC LIN=1)
elseif(WIN32)
Expand Down

0 comments on commit 86cc305

Please sign in to comment.