diff options
| author | Marc Jeanmougin <marc@jeanmougin.fr> | 2017-10-28 16:46:05 +0000 |
|---|---|---|
| committer | Marc Jeanmougin <marc@jeanmougin.fr> | 2017-10-28 16:47:33 +0000 |
| commit | 7e6670263c3a42dfe70a4e97009f25259d7f6a4c (patch) | |
| tree | 161dfdd25f64c860307748ee613ba66a9d419436 | |
| parent | Merge branch 'master' of https://gitlab.com/inkscape/inkscape (diff) | |
| download | inkscape-7e6670263c3a42dfe70a4e97009f25259d7f6a4c.tar.gz inkscape-7e6670263c3a42dfe70a4e97009f25259d7f6a4c.zip | |
simpler structure -- compilers and flags have to be given externally
| -rw-r--r-- | CMakeLists.txt | 14 | ||||
| -rw-r--r-- | testfiles/CMakeLists.txt | 9 | ||||
| -rw-r--r-- | testfiles/fuzzer.dict (renamed from testfiles/fuzz-dict) | 0 |
3 files changed, 6 insertions, 17 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index 3293e872b..b01956876 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -106,6 +106,7 @@ option(WITH_NLS "Compile with Native Language Support (using gettext)" ON) option(WITH_YAML "Compile with YAML support (enables xverbs)" ON) option(WITH_FUZZ "Compile for fuzzing purpose (use 'make fuzz' only)" OFF) +mark_as_advanced(WITH_FUZZ) option(ENABLE_BINRELOC "Enable relocatable binaries" OFF) @@ -155,19 +156,6 @@ endif() # ----------------------------------------------------------------------------- -# Fuzzing -# ----------------------------------------------------------------------------- - -mark_as_advanced(WITH_FUZZ) -if(WITH_FUZZ) - add_definitions("-fsanitize=address"#,undefined,signed-integer-overflow - "-fsanitize-coverage=edge,trace-pc-guard,indirect-calls,trace-cmp,trace-div,trace-gep" - "-fno-omit-frame-pointer") - set(CMAKE_C_COMPILER /usr/bin/clang) - set(CMAKE_CXX_COMPILER /usr/bin/clang++) -endif() - -# ----------------------------------------------------------------------------- # Relocatable Binary # ----------------------------------------------------------------------------- diff --git a/testfiles/CMakeLists.txt b/testfiles/CMakeLists.txt index 5dba0258b..923898fc3 100644 --- a/testfiles/CMakeLists.txt +++ b/testfiles/CMakeLists.txt @@ -34,8 +34,9 @@ add_subdirectory(rendering_tests) if(WITH_FUZZ) add_executable(fuzz fuzzer.cpp) - target_link_libraries(fuzz inkscape_base -lFuzzer "-fsanitize=address" - "-fsanitize-coverage=edge,trace-pc-guard,indirect-calls,trace-cmp,trace-div,trace-gep" - "-fno-omit-frame-pointer") - + if(EXISTS ${LIB_FUZZING_ENGINE}) + target_link_libraries(fuzz inkscape_base -lFuzzingEngine) + else() + target_link_libraries(fuzz inkscape_base -lFuzzer) + endif() endif() diff --git a/testfiles/fuzz-dict b/testfiles/fuzzer.dict index 7eee0d0a0..7eee0d0a0 100644 --- a/testfiles/fuzz-dict +++ b/testfiles/fuzzer.dict |
