summaryrefslogtreecommitdiffstats
path: root/.clusterfuzzlite/build.sh
diff options
context:
space:
mode:
Diffstat (limited to '')
-rwxr-xr-x.clusterfuzzlite/build.sh16
1 files changed, 16 insertions, 0 deletions
diff --git a/.clusterfuzzlite/build.sh b/.clusterfuzzlite/build.sh
new file mode 100755
index 0000000..0ac681c
--- /dev/null
+++ b/.clusterfuzzlite/build.sh
@@ -0,0 +1,16 @@
+#!/bin/bash -eu
+
+autoreconf -i
+./configure --enable-lib-only
+make -j$(nproc)
+
+$CXX $CXXFLAGS -std=c++17 -Ilib/includes -Ilib -I. -DHAVE_CONFIG_H \
+ fuzz/decode_frame.cc -o $OUT/decode_frame \
+ $LIB_FUZZING_ENGINE lib/.libs/libngtcp2.a
+
+$CXX $CXXFLAGS -std=c++17 -Ilib/includes -Ilib -I. -DHAVE_CONFIG_H \
+ fuzz/ksl.cc -o $OUT/ksl \
+ $LIB_FUZZING_ENGINE lib/.libs/libngtcp2.a
+
+zip -j $OUT/decode_frame_seed_corpus.zip fuzz/corpus/decode_frame/*
+zip -j $OUT/ksl_seed_corpus.zip fuzz/corpus/ksl/*