/ Check-in [a4a083ed]
Login

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:Add an entry in Makefile.in to build dbfuzz2 using clang-6.0 with -fsanitize=fuzzer,undefined.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA3-256:a4a083ed8cdb106af661d2ee0203e21c576f5c2304419ce603826e4f2851c2e0
User & Date: drh 2018-10-27 16:02:16
Context
2018-10-27
21:06
Improvements to the dbfuzz2.c test module. check-in: d60eff49 user: drh tags: trunk
16:02
Add an entry in Makefile.in to build dbfuzz2 using clang-6.0 with -fsanitize=fuzzer,undefined. check-in: a4a083ed user: drh tags: trunk
00:47
Initial code for a fuzzing tool on database file that works with the -fsanitize=fuzzer option of clang. check-in: 90d12094 user: drh tags: trunk
Changes
Hide Diffs Side-by-Side Diffs Ignore Whitespace Patch

Changes to Makefile.in.

   660    660   
   661    661   sessionfuzz$(TEXE):	$(TOP)/test/sessionfuzz.c sqlite3.c sqlite3.h
   662    662   	$(CC) $(CFLAGS) -I. -o $@ $(TOP)/test/sessionfuzz.c $(TLIBS)
   663    663   
   664    664   dbfuzz$(TEXE):	$(TOP)/test/dbfuzz.c sqlite3.c sqlite3.h
   665    665   	$(LTLINK) -o $@ $(DBFUZZ_OPT) $(TOP)/test/dbfuzz.c sqlite3.c $(TLIBS)
   666    666   
          667  +DBFUZZ2_OPTS = \
          668  +  -DSQLITE_THREADSAFE=0 \
          669  +  -DSQLITE_OMIT_LOAD_EXTENSION \
          670  +  -DSQLITE_ENABLE_DESERIALIZE \
          671  +  -DSQLITE_DEBUG \
          672  +  -DSQLITE_ENABLE_DBSTAT_VTAB \
          673  +  -DSQLITE_ENABLE_RTREE \
          674  +  -DSQLITE_ENABLE_FTS4 \
          675  +  -DSQLITE_EANBLE_FTS5
          676  +
          677  +dbfuzz2:	$(TOP)/test/dbfuzz2.c sqlite3.c sqlite3.h
          678  +	clang-6.0 -I. -g -Os -fsanitize=fuzzer,undefined -o dbfuzz2 \
          679  +		$(DBFUZZ2_OPTS) $(TOP)/test/dbfuzz2.c sqlite3.c
          680  +	mkdir -p dbfuzz2-dir
          681  +	cp $(TOP)/test/dbfuzz2-seed* dbfuzz2-dir
          682  +
   667    683   mptester$(TEXE):	sqlite3.lo $(TOP)/mptest/mptest.c
   668    684   	$(LTLINK) -o $@ -I. $(TOP)/mptest/mptest.c sqlite3.lo \
   669    685   		$(TLIBS) -rpath "$(libdir)"
   670    686   
   671    687   MPTEST1=./mptester$(TEXE) mptest.db $(TOP)/mptest/crash01.test --repeat 20
   672    688   MPTEST2=./mptester$(TEXE) mptest.db $(TOP)/mptest/multiwrite01.test --repeat 20
   673    689   mptest:	mptester$(TEXE)