16 x%.o: ../../mercurial/thirdparty/xdiff/x%.c ../../mercurial/thirdparty/xdiff/*.h |
16 x%.o: ../../mercurial/thirdparty/xdiff/x%.c ../../mercurial/thirdparty/xdiff/*.h |
17 clang -g -O1 -fsanitize=fuzzer-no-link,address -c \ |
17 clang -g -O1 -fsanitize=fuzzer-no-link,address -c \ |
18 -o $@ \ |
18 -o $@ \ |
19 $< |
19 $< |
20 |
20 |
21 xdiff: xdiff.cc xdiffi.o xemit.o xmerge.o xprepare.o xutils.o |
21 xdiff: xdiff.cc xdiffi.o xprepare.o xutils.o |
22 clang -DHG_FUZZER_INCLUDE_MAIN=1 -g -O1 -fsanitize=fuzzer-no-link,address \ |
22 clang -DHG_FUZZER_INCLUDE_MAIN=1 -g -O1 -fsanitize=fuzzer-no-link,address \ |
23 -I../../mercurial xdiff.cc \ |
23 -I../../mercurial xdiff.cc \ |
24 xdiffi.o xemit.o xmerge.o xprepare.o xutils.o -o xdiff |
24 xdiffi.o xprepare.o xutils.o -o xdiff |
25 |
25 |
26 fuzz-x%.o: ../../mercurial/thirdparty/xdiff/x%.c ../../mercurial/thirdparty/xdiff/*.h |
26 fuzz-x%.o: ../../mercurial/thirdparty/xdiff/x%.c ../../mercurial/thirdparty/xdiff/*.h |
27 $$CC $$CFLAGS -c \ |
27 $$CC $$CFLAGS -c \ |
28 -o $@ \ |
28 -o $@ \ |
29 $< |
29 $< |
30 |
30 |
31 xdiff_fuzzer: xdiff.cc fuzz-xdiffi.o fuzz-xemit.o fuzz-xmerge.o fuzz-xprepare.o fuzz-xutils.o |
31 xdiff_fuzzer: xdiff.cc fuzz-xdiffi.o fuzz-xprepare.o fuzz-xutils.o |
32 $$CXX $$CXXFLAGS -std=c++11 -I../../mercurial xdiff.cc \ |
32 $$CXX $$CXXFLAGS -std=c++11 -I../../mercurial xdiff.cc \ |
33 fuzz-xdiffi.o fuzz-xemit.o fuzz-xmerge.o fuzz-xprepare.o fuzz-xutils.o \ |
33 fuzz-xdiffi.o fuzz-xprepare.o fuzz-xutils.o \ |
34 -lFuzzingEngine -o $$OUT/xdiff_fuzzer |
34 -lFuzzingEngine -o $$OUT/xdiff_fuzzer |
35 |
35 |
36 all: bdiff xdiff |
36 all: bdiff xdiff |
37 |
37 |
38 oss-fuzz: bdiff_fuzzer xdiff_fuzzer |
38 oss-fuzz: bdiff_fuzzer xdiff_fuzzer |