From 3a9e3bcddd1c28016ea6d76525083f3ddb743a66 Mon Sep 17 00:00:00 2001 From: Matt Morehouse Date: Wed, 23 Aug 2017 19:58:07 +0000 Subject: [PATCH] [clang-proto-fuzzer] Fix clang-proto-to-cxx build. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@311592 91177308-0d34-0410-b5e6-96231b3b80d8 --- tools/clang-fuzzer/CMakeLists.txt | 1 + tools/clang-fuzzer/proto-to-cxx/CMakeLists.txt | 1 + 2 files changed, 2 insertions(+) diff --git a/tools/clang-fuzzer/CMakeLists.txt b/tools/clang-fuzzer/CMakeLists.txt index 694dd585c2..82c3b0eb02 100644 --- a/tools/clang-fuzzer/CMakeLists.txt +++ b/tools/clang-fuzzer/CMakeLists.txt @@ -1,5 +1,6 @@ if( LLVM_USE_SANITIZE_COVERAGE ) set(LLVM_LINK_COMPONENTS ${LLVM_TARGETS_TO_BUILD}) + set(CXX_FLAGS_NOFUZZ ${CMAKE_CXX_FLAGS}) set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fsanitize=fuzzer") if(CLANG_ENABLE_PROTO_FUZZER) diff --git a/tools/clang-fuzzer/proto-to-cxx/CMakeLists.txt b/tools/clang-fuzzer/proto-to-cxx/CMakeLists.txt index 1c3c504cef..36235a584b 100644 --- a/tools/clang-fuzzer/proto-to-cxx/CMakeLists.txt +++ b/tools/clang-fuzzer/proto-to-cxx/CMakeLists.txt @@ -1,4 +1,5 @@ set(LLVM_LINK_COMPONENTS ${LLVM_TARGETS_TO_BUILD}) +set(CMAKE_CXX_FLAGS ${CXX_FLAGS_NOFUZZ}) # Hack to bypass LLVM's CMake source checks so we can have both a library and # an executable built from this directory. -- 2.40.0