From 0c27576bdf6c5738b43f71e80f0557ed080399a6 Mon Sep 17 00:00:00 2001 From: Cindy Liu Date: Fri, 4 Aug 2023 12:56:57 -0700 Subject: [PATCH] Disable libyaml GCC unused-value warning temporarily A Fix is proposed upstream and pending review. --- build_tools/third_party/libyaml/CMakeLists.txt | 3 +++ 1 file changed, 3 insertions(+) diff --git a/build_tools/third_party/libyaml/CMakeLists.txt b/build_tools/third_party/libyaml/CMakeLists.txt index f296963167e3..93eda90b479a 100644 --- a/build_tools/third_party/libyaml/CMakeLists.txt +++ b/build_tools/third_party/libyaml/CMakeLists.txt @@ -41,4 +41,7 @@ external_cc_library( if(MSVC) target_compile_options(yaml_yaml PRIVATE /wd4996) +elseif("${CMAKE_CXX_COMPILER_ID}" STREQUAL "GNU") + # TODO(libyaml#210): Remove this option. + target_compile_options(yaml_yaml PRIVATE "-Wno-unused-value") endif()