2016-11-27 18:19:26 +03:00
|
|
|
##############################################################################
|
2020-07-16 14:38:25 +03:00
|
|
|
# OSS-Fuzz
|
2016-11-27 18:19:26 +03:00
|
|
|
##############################################################################
|
2016-08-04 08:24:46 +03:00
|
|
|
|
2020-07-16 14:38:25 +03:00
|
|
|
# The following targets realize the integration to OSS-Fuzz.
|
|
|
|
# See <https://github.com/google/oss-fuzz/blob/master/projects/json/build.sh> for more information.
|
2016-08-04 08:24:46 +03:00
|
|
|
|
2020-07-16 14:38:25 +03:00
|
|
|
# additional flags
|
|
|
|
CXXFLAGS += -std=c++11
|
|
|
|
CPPFLAGS += -I ../single_include
|
2016-12-22 13:09:26 +03:00
|
|
|
|
2017-01-04 00:35:31 +03:00
|
|
|
FUZZER_ENGINE = src/fuzzer-driver_afl.cpp
|
2018-10-24 16:43:37 +03:00
|
|
|
FUZZERS = parse_afl_fuzzer parse_bson_fuzzer parse_cbor_fuzzer parse_msgpack_fuzzer parse_ubjson_fuzzer
|
2018-01-27 20:38:11 +03:00
|
|
|
fuzzers: $(FUZZERS)
|
2017-01-01 23:51:36 +03:00
|
|
|
|
2016-12-22 13:09:26 +03:00
|
|
|
parse_afl_fuzzer:
|
2017-01-04 00:35:31 +03:00
|
|
|
$(CXX) $(CXXFLAGS) $(CPPFLAGS) $(FUZZER_ENGINE) src/fuzzer-parse_json.cpp -o $@
|
2016-12-22 14:08:36 +03:00
|
|
|
|
2018-10-24 16:43:37 +03:00
|
|
|
parse_bson_fuzzer:
|
|
|
|
$(CXX) $(CXXFLAGS) $(CPPFLAGS) $(FUZZER_ENGINE) src/fuzzer-parse_bson.cpp -o $@
|
|
|
|
|
2016-12-22 14:08:36 +03:00
|
|
|
parse_cbor_fuzzer:
|
2017-01-04 00:35:31 +03:00
|
|
|
$(CXX) $(CXXFLAGS) $(CPPFLAGS) $(FUZZER_ENGINE) src/fuzzer-parse_cbor.cpp -o $@
|
2016-12-25 18:18:56 +03:00
|
|
|
|
|
|
|
parse_msgpack_fuzzer:
|
2017-01-04 00:35:31 +03:00
|
|
|
$(CXX) $(CXXFLAGS) $(CPPFLAGS) $(FUZZER_ENGINE) src/fuzzer-parse_msgpack.cpp -o $@
|
2018-01-27 20:38:11 +03:00
|
|
|
|
|
|
|
parse_ubjson_fuzzer:
|
|
|
|
$(CXX) $(CXXFLAGS) $(CPPFLAGS) $(FUZZER_ENGINE) src/fuzzer-parse_ubjson.cpp -o $@
|