From 4431a34a65c1720c8a5f14e4263bb314ea883b3c Mon Sep 17 00:00:00 2001 From: DavidKorczynski Date: Thu, 2 Sep 2021 19:13:55 +0100 Subject: [PATCH] kamailio: updated build script for new fuzzer. (#6387) --- projects/kamailio/build.sh | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/projects/kamailio/build.sh b/projects/kamailio/build.sh index 2b7c3735b..5d94cec47 100755 --- a/projects/kamailio/build.sh +++ b/projects/kamailio/build.sh @@ -22,7 +22,8 @@ export LD_EXTRA_OPTS="${CFLAGS}" sed -i 's/int main(/int main2(/g' ./src/main.c -make || true +export MEMPKG=sys +make Q=verbose || true cd src mkdir objects && find . -name "*.o" -exec cp {} ./objects/ \; ar -r libkamilio.a ./objects/*.o @@ -30,3 +31,7 @@ cd ../ $CC $CFLAGS $LIB_FUZZING_ENGINE ./misc/fuzz/fuzz_uri.c -o $OUT/fuzz_uri \ -DFAST_LOCK -D__CPU_i386 ./src/libkamilio.a \ -I./src/ -I./src/core/parser -ldl -lresolv -lm + +$CC $CFLAGS $LIB_FUZZING_ENGINE ./misc/fuzz/fuzz_parse_msg.c -o $OUT/fuzz_parse_msg \ + -DFAST_LOCK -D__CPU_i386 ./src/libkamilio.a \ + -I./src/ -I./src/core/parser -ldl -lresolv -lm