diff --git a/CMakeLists.txt b/CMakeLists.txt index 2e4b78e..c7d1fd9 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -42,10 +42,6 @@ include_directories(${LIBLZMA_INCLUDE_DIRS}) find_package(ZLIB) include_directories(${ZLIB_INCLUDE_DIRS}) -set(CMAKE_CXX_STANDARD 14) -set(CMAKE_CXX_STANDARD_REQUIRED ON) -set(CMAKE_CXX_EXTENSIONS OFF) - include_directories(${PROJECT_SOURCE_DIR}) if (MSVC) diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index 321874c..7b2c7f3 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -24,6 +24,7 @@ target_link_libraries(protobuf-mutator set_target_properties(protobuf-mutator PROPERTIES COMPILE_FLAGS "${NO_FUZZING_FLAGS}" SOVERSION 0) +target_compile_features(protobuf-mutator PRIVATE cxx_std_14) if (LIB_PROTO_MUTATOR_TESTING) protobuf_generate_cpp(PROTO_SRCS PROTO_HDRS diff --git a/src/libfuzzer/CMakeLists.txt b/src/libfuzzer/CMakeLists.txt index 7100ef1..14daf22 100644 --- a/src/libfuzzer/CMakeLists.txt +++ b/src/libfuzzer/CMakeLists.txt @@ -21,6 +21,7 @@ target_link_libraries(protobuf-mutator-libfuzzer set_target_properties(protobuf-mutator-libfuzzer PROPERTIES COMPILE_FLAGS "${NO_FUZZING_FLAGS}" SOVERSION 0) +target_compile_features(protobuf-mutator-libfuzzer PRIVATE cxx_std_14) install(TARGETS protobuf-mutator-libfuzzer EXPORT libprotobuf-mutatorTargets