diff options
author | Robert Löhning <robert.loehning@qt.io> | 2021-05-27 21:29:39 +0200 |
---|---|---|
committer | Robert Löhning <robert.loehning@qt.io> | 2021-05-31 16:44:06 +0200 |
commit | 8b691ce24572f4709213d880c478e444feafe3fb (patch) | |
tree | aff91156cf5d1a9f7bd2eb6fc062455e864b03f8 /tests/libfuzzer/corelib/serialization/qxmlstream | |
parent | 4b0b87b5c2173ee70eacfdd7cea08aea8a5164c8 (diff) |
Fuzzing: Add CMake project files for fuzz targets
Change-Id: Ied44bfd2c83d5590066146187a7333b677ceb179
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
Diffstat (limited to 'tests/libfuzzer/corelib/serialization/qxmlstream')
-rw-r--r-- | tests/libfuzzer/corelib/serialization/qxmlstream/qxmlstreamreader/readnext/CMakeLists.txt | 27 |
1 files changed, 27 insertions, 0 deletions
diff --git a/tests/libfuzzer/corelib/serialization/qxmlstream/qxmlstreamreader/readnext/CMakeLists.txt b/tests/libfuzzer/corelib/serialization/qxmlstream/qxmlstreamreader/readnext/CMakeLists.txt new file mode 100644 index 0000000000..aa9b550ed3 --- /dev/null +++ b/tests/libfuzzer/corelib/serialization/qxmlstream/qxmlstreamreader/readnext/CMakeLists.txt @@ -0,0 +1,27 @@ +cmake_minimum_required(VERSION 3.14) +project(readnext LANGUAGES CXX) + +set(CMAKE_INCLUDE_CURRENT_DIR ON) + +set(CMAKE_AUTOMOC ON) +set(CMAKE_AUTORCC ON) +set(CMAKE_AUTOUIC ON) + +find_package(Qt6 COMPONENTS Core) + +qt_add_executable(readnext + main.cpp +) + +target_link_libraries(readnext PUBLIC + Qt::Core +) +if(DEFINED ENV{LIB_FUZZING_ENGINE}) + target_link_libraries(readnext PRIVATE + $ENV{LIB_FUZZING_ENGINE} + ) +else() + target_link_libraries(readnext PRIVATE + -fsanitize=fuzzer + ) +endif() |