5 # This makefile is suppose to be configured automatically using the
6 # autoconf. But if that does not work for you, you can configure
7 # the makefile manually. Just set the parameters below to values that
8 # work well for your system.
10 # If the configure script does not work out-of-the-box, you might
11 # be able to get it to work by giving it some hints. See the comment
12 # at the beginning of configure.in for additional information.
15 # The toplevel directory of the source tree. This is the directory
16 # that contains this "Makefile.in" and the "configure.in" script.
20 # C Compiler and options for use in building executables that
21 # will run on the platform that is doing the build.
23 BCC
= @BUILD_CC@ @BUILD_CFLAGS@
25 # TCC is the C Compile and options for use in building executables that
26 # will run on the target platform. (BCC and TCC are usually the
27 # same unless your are cross-compiling.) Separate CC and CFLAGS macros
28 # are provide so that these aspects of the build process can be changed
29 # on the "make" command-line. Ex: "make CC=clang CFLAGS=-fsanitize=undefined"
32 CFLAGS
= @CPPFLAGS@ @CFLAGS@
33 TCC
= ${CC} ${CFLAGS} -I.
-I
${TOP}/src
-I
${TOP}/ext
/rtree
-I
${TOP}/ext
/icu
34 TCC
+= -I
${TOP}/ext
/fts3
-I
${TOP}/ext
/async
-I
${TOP}/ext
/session
36 # Define this for the autoconf-based build, so that the code knows it can
37 # include the generated config.h
39 TCC
+= -D_HAVE_SQLITE_CONFIG_H
-DBUILD_sqlite
41 # Define -DNDEBUG to compile without debugging (i.e., for production usage)
42 # Omitting the define will cause extra debugging code to be inserted and
43 # includes extra comments when "EXPLAIN stmt" is used.
47 # Compiler options needed for programs that use the TCL library.
49 TCC
+= @TCL_INCLUDE_SPEC@
51 # The library that programs using TCL must link against.
53 LIBTCL
= @TCL_LIB_SPEC@
55 # Compiler options needed for programs that use the readline() library.
57 READLINE_FLAGS
= -DHAVE_READLINE
=@TARGET_HAVE_READLINE@ @TARGET_READLINE_INC@
58 READLINE_FLAGS
+= -DHAVE_EDITLINE
=@TARGET_HAVE_EDITLINE@
60 # The library that programs using readline() must link against.
62 LIBREADLINE
= @TARGET_READLINE_LIBS@
64 # Should the database engine be compiled threadsafe
66 TCC
+= -DSQLITE_THREADSAFE
=@SQLITE_THREADSAFE@
68 # Any target libraries which libsqlite must be linked against
70 TLIBS
= @LIBS@
$(LIBS
)
72 # Flags controlling use of the in memory btree implementation
74 # SQLITE_TEMP_STORE is 0 to force temporary tables to be in a file, 1 to
75 # default to file, 2 to default to memory, and 3 to force temporary
76 # tables to always be in memory.
78 TEMP_STORE
= -DSQLITE_TEMP_STORE
=@TEMP_STORE@
80 # Enable/disable loadable extensions, and other optional features
81 # based on configuration. (-DSQLITE_OMIT*, -DSQLITE_ENABLE*).
82 # The same set of OMIT and ENABLE flags should be passed to the
83 # LEMON parser generator and the mkkeywordhash tool as well.
84 OPT_FEATURE_FLAGS
= @OPT_FEATURE_FLAGS@
86 TCC
+= $(OPT_FEATURE_FLAGS
)
88 # Add in any optional parameters specified on the make commane line
89 # ie. make "OPTS=-DSQLITE_ENABLE_FOO=1 -DSQLITE_OMIT_FOO=1".
92 # Add in compile-time options for some libraries used by extensions
95 # Version numbers and release number for the SQLite being compiled.
98 VERSION_NUMBER
= @VERSION_NUMBER@
101 # Filename extensions
103 BEXE
= @BUILD_EXEEXT@
104 TEXE
= @TARGET_EXEEXT@
106 # The following variable is "1" if the configure script was able to locate
107 # the tclConfig.sh file. It is an empty string otherwise. When this
108 # variable is "1", the TCL extension library (libtclsqlite3.so) is built
111 HAVE_TCL
= @HAVE_TCL@
113 # This is the command to use for tclsh - normally just "tclsh", but we may
114 # know the specific version we want to use
116 TCLSH_CMD
= @TCLSH_CMD@
118 # Where do we want to install the tcl plugin
120 TCLLIBDIR
= @TCLLIBDIR@
122 # The suffix used on shared libraries. Ex: ".dll", ".so", ".dylib"
124 SHLIB_SUFFIX
= @TCL_SHLIB_SUFFIX@
126 # If gcov support was enabled by the configure script, add the appropriate
127 # flags here. It's not always as easy as just having the user add the right
128 # CFLAGS / LDFLAGS, because libtool wants to use CFLAGS when linking, which
129 # causes build errors with -fprofile-arcs -ftest-coverage with some GCCs.
130 # Supposedly GCC does the right thing if you use --coverage, but in
131 # practice it still fails. See:
133 # http://www.mail-archive.com/debian-gcc@lists.debian.org/msg26197.html
137 GCOV_CFLAGS1
= -DSQLITE_COVERAGE_TEST
=1 -fprofile-arcs
-ftest-coverage
138 GCOV_LDFLAGS1
= -lgcov
139 USE_GCOV
= @USE_GCOV@
140 LTCOMPILE_EXTRAS
+= $(GCOV_CFLAGS
$(USE_GCOV
))
141 LTLINK_EXTRAS
+= $(GCOV_LDFLAGS
$(USE_GCOV
))
144 # The directory into which to store package information for
146 # Some standard variables and programs
149 exec_prefix = @
exec_prefix@
151 pkgconfigdir
= $(libdir)/pkgconfig
153 includedir = @
includedir@
156 ALLOWRELEASE
= @ALLOWRELEASE@
158 # libtool compile/link/install
159 LTCOMPILE
= $(LIBTOOL
) --mode
=compile
--tag
=CC
$(TCC
) $(LTCOMPILE_EXTRAS
)
160 LTLINK
= $(LIBTOOL
) --mode
=link
$(TCC
) $(LTCOMPILE_EXTRAS
) @LDFLAGS@
$(LTLINK_EXTRAS
)
161 LTINSTALL
= $(LIBTOOL
) --mode
=install $(INSTALL
)
163 # You should not have to change anything below this line
164 ###############################################################################
166 USE_AMALGAMATION
= @USE_AMALGAMATION@
168 # Object files for the SQLite library (non-amalgamation).
170 LIBOBJS0
= alter.lo analyze.lo attach.lo auth.lo \
171 backup.lo bitvec.lo btmutex.lo btree.lo build.lo \
172 callback.lo complete.lo ctime.lo \
173 date.lo dbpage.lo dbstat.lo delete.lo \
174 expr.lo fault.lo fkey.lo \
175 fts3.lo fts3_aux.lo fts3_expr.lo fts3_hash.lo fts3_icu.lo \
176 fts3_porter.lo fts3_snippet.lo fts3_tokenizer.lo fts3_tokenizer1.lo \
177 fts3_tokenize_vtab.lo \
178 fts3_unicode.lo fts3_unicode2.lo fts3_write.lo \
180 func.lo global.lo hash.lo \
181 icu.lo insert.lo json1.lo legacy.lo loadext.lo \
182 main.lo malloc.lo mem0.lo mem1.lo mem2.lo mem3.lo mem5.lo \
184 mutex.lo mutex_noop.lo mutex_unix.lo mutex_w32.lo \
185 notify.lo opcodes.lo os.lo os_unix.lo os_win.lo \
186 pager.lo parse.lo pcache.lo pcache1.lo pragma.lo prepare.lo printf.lo \
187 random.lo resolve.lo rowset.lo rtree.lo \
188 sqlite3session.lo select.lo sqlite3rbu.lo status.lo stmt.lo \
189 table.lo threads.lo tokenize.lo treeview.lo trigger.lo \
190 update.lo util.lo vacuum.lo \
191 vdbe.lo vdbeapi.lo vdbeaux.lo vdbeblob.lo vdbemem.lo vdbesort.lo \
192 vdbetrace.lo wal.lo walker.lo where.lo wherecode.lo whereexpr.lo \
195 # Object files for the amalgamation.
197 LIBOBJS1
= sqlite3.lo
199 # Determine the real value of LIBOBJ based on the 'configure' script
201 LIBOBJ
= $(LIBOBJS
$(USE_AMALGAMATION
))
204 # All of the source code files.
208 $(TOP
)/src
/analyze.c \
209 $(TOP
)/src
/attach.c \
211 $(TOP
)/src
/backup.c \
212 $(TOP
)/src
/bitvec.c \
213 $(TOP
)/src
/btmutex.c \
216 $(TOP
)/src
/btreeInt.h \
218 $(TOP
)/src
/callback.c \
219 $(TOP
)/src
/complete.c \
222 $(TOP
)/src
/dbpage.c \
223 $(TOP
)/src
/dbstat.c \
224 $(TOP
)/src
/delete.c \
229 $(TOP
)/src
/global.c \
232 $(TOP
)/src
/hwtime.h \
233 $(TOP
)/src
/insert.c \
234 $(TOP
)/src
/legacy.c \
235 $(TOP
)/src
/loadext.c \
237 $(TOP
)/src
/malloc.c \
243 $(TOP
)/src
/memjournal.c \
247 $(TOP
)/src
/mutex_noop.c \
248 $(TOP
)/src
/mutex_unix.c \
249 $(TOP
)/src
/mutex_w32.c \
250 $(TOP
)/src
/notify.c \
253 $(TOP
)/src
/os_common.h \
254 $(TOP
)/src
/os_setup.h \
255 $(TOP
)/src
/os_unix.c \
256 $(TOP
)/src
/os_win.c \
257 $(TOP
)/src
/os_win.h \
261 $(TOP
)/src
/pcache.c \
262 $(TOP
)/src
/pcache.h \
263 $(TOP
)/src
/pcache1.c \
264 $(TOP
)/src
/pragma.c \
265 $(TOP
)/src
/pragma.h \
266 $(TOP
)/src
/prepare.c \
267 $(TOP
)/src
/printf.c \
268 $(TOP
)/src
/random.c \
269 $(TOP
)/src
/resolve.c \
270 $(TOP
)/src
/rowset.c \
271 $(TOP
)/src
/select.c \
272 $(TOP
)/src
/status.c \
273 $(TOP
)/src
/shell.c.in \
274 $(TOP
)/src
/sqlite.h.in \
275 $(TOP
)/src
/sqlite3ext.h \
276 $(TOP
)/src
/sqliteInt.h \
277 $(TOP
)/src
/sqliteLimit.h \
279 $(TOP
)/src
/tclsqlite.c \
280 $(TOP
)/src
/threads.c \
281 $(TOP
)/src
/tokenize.c \
282 $(TOP
)/src
/treeview.c \
283 $(TOP
)/src
/trigger.c \
285 $(TOP
)/src
/update.c \
287 $(TOP
)/src
/vacuum.c \
290 $(TOP
)/src
/vdbeapi.c \
291 $(TOP
)/src
/vdbeaux.c \
292 $(TOP
)/src
/vdbeblob.c \
293 $(TOP
)/src
/vdbemem.c \
294 $(TOP
)/src
/vdbesort.c \
295 $(TOP
)/src
/vdbetrace.c \
296 $(TOP
)/src
/vdbeInt.h \
298 $(TOP
)/src
/vxworks.h \
301 $(TOP
)/src
/walker.c \
303 $(TOP
)/src
/wherecode.c \
304 $(TOP
)/src
/whereexpr.c \
305 $(TOP
)/src
/whereInt.h
307 # Source code for extensions
310 $(TOP
)/ext
/fts1
/fts1.c \
311 $(TOP
)/ext
/fts1
/fts1.h \
312 $(TOP
)/ext
/fts1
/fts1_hash.c \
313 $(TOP
)/ext
/fts1
/fts1_hash.h \
314 $(TOP
)/ext
/fts1
/fts1_porter.c \
315 $(TOP
)/ext
/fts1
/fts1_tokenizer.h \
316 $(TOP
)/ext
/fts1
/fts1_tokenizer1.c
318 $(TOP
)/ext
/fts2
/fts2.c \
319 $(TOP
)/ext
/fts2
/fts2.h \
320 $(TOP
)/ext
/fts2
/fts2_hash.c \
321 $(TOP
)/ext
/fts2
/fts2_hash.h \
322 $(TOP
)/ext
/fts2
/fts2_icu.c \
323 $(TOP
)/ext
/fts2
/fts2_porter.c \
324 $(TOP
)/ext
/fts2
/fts2_tokenizer.h \
325 $(TOP
)/ext
/fts2
/fts2_tokenizer.c \
326 $(TOP
)/ext
/fts2
/fts2_tokenizer1.c
328 $(TOP
)/ext
/fts3
/fts3.c \
329 $(TOP
)/ext
/fts3
/fts3.h \
330 $(TOP
)/ext
/fts3
/fts3Int.h \
331 $(TOP
)/ext
/fts3
/fts3_aux.c \
332 $(TOP
)/ext
/fts3
/fts3_expr.c \
333 $(TOP
)/ext
/fts3
/fts3_hash.c \
334 $(TOP
)/ext
/fts3
/fts3_hash.h \
335 $(TOP
)/ext
/fts3
/fts3_icu.c \
336 $(TOP
)/ext
/fts3
/fts3_porter.c \
337 $(TOP
)/ext
/fts3
/fts3_snippet.c \
338 $(TOP
)/ext
/fts3
/fts3_tokenizer.h \
339 $(TOP
)/ext
/fts3
/fts3_tokenizer.c \
340 $(TOP
)/ext
/fts3
/fts3_tokenizer1.c \
341 $(TOP
)/ext
/fts3
/fts3_tokenize_vtab.c \
342 $(TOP
)/ext
/fts3
/fts3_unicode.c \
343 $(TOP
)/ext
/fts3
/fts3_unicode2.c \
344 $(TOP
)/ext
/fts3
/fts3_write.c
346 $(TOP
)/ext
/icu
/sqliteicu.h \
349 $(TOP
)/ext
/rtree
/rtree.h \
350 $(TOP
)/ext
/rtree
/rtree.c
352 $(TOP
)/ext
/session
/sqlite3session.c \
353 $(TOP
)/ext
/session
/sqlite3session.h
355 $(TOP
)/ext
/rbu
/sqlite3rbu.h \
356 $(TOP
)/ext
/rbu
/sqlite3rbu.c
358 $(TOP
)/ext
/misc
/json1.c \
359 $(TOP
)/ext
/misc
/stmt.c
361 # Generated source code files
373 # Source code to the test files.
385 $(TOP
)/src
/test_autoext.c \
386 $(TOP
)/src
/test_async.c \
387 $(TOP
)/src
/test_backup.c \
388 $(TOP
)/src
/test_bestindex.c \
389 $(TOP
)/src
/test_blob.c \
390 $(TOP
)/src
/test_btree.c \
391 $(TOP
)/src
/test_config.c \
392 $(TOP
)/src
/test_delete.c \
393 $(TOP
)/src
/test_demovfs.c \
394 $(TOP
)/src
/test_devsym.c \
395 $(TOP
)/src
/test_fs.c \
396 $(TOP
)/src
/test_func.c \
397 $(TOP
)/src
/test_hexio.c \
398 $(TOP
)/src
/test_init.c \
399 $(TOP
)/src
/test_intarray.c \
400 $(TOP
)/src
/test_journal.c \
401 $(TOP
)/src
/test_malloc.c \
402 $(TOP
)/src
/test_md5.c \
403 $(TOP
)/src
/test_multiplex.c \
404 $(TOP
)/src
/test_mutex.c \
405 $(TOP
)/src
/test_onefile.c \
406 $(TOP
)/src
/test_osinst.c \
407 $(TOP
)/src
/test_pcache.c \
408 $(TOP
)/src
/test_quota.c \
409 $(TOP
)/src
/test_rtree.c \
410 $(TOP
)/src
/test_schema.c \
411 $(TOP
)/src
/test_server.c \
412 $(TOP
)/src
/test_superlock.c \
413 $(TOP
)/src
/test_syscall.c \
414 $(TOP
)/src
/test_tclsh.c \
415 $(TOP
)/src
/test_tclvar.c \
416 $(TOP
)/src
/test_thread.c \
417 $(TOP
)/src
/test_vfs.c \
418 $(TOP
)/src
/test_windirent.c \
419 $(TOP
)/src
/test_wsd.c \
420 $(TOP
)/ext
/fts3
/fts3_term.c \
421 $(TOP
)/ext
/fts3
/fts3_test.c \
422 $(TOP
)/ext
/session
/test_session.c \
423 $(TOP
)/ext
/rbu
/test_rbu.c
425 # Statically linked extensions
428 $(TOP
)/ext
/expert
/sqlite3expert.c \
429 $(TOP
)/ext
/expert
/test_expert.c \
430 $(TOP
)/ext
/misc
/amatch.c \
431 $(TOP
)/ext
/misc
/carray.c \
432 $(TOP
)/ext
/misc
/closure.c \
433 $(TOP
)/ext
/misc
/csv.c \
434 $(TOP
)/ext
/misc
/eval.c \
435 $(TOP
)/ext
/misc
/fileio.c \
436 $(TOP
)/ext
/misc
/fuzzer.c \
437 $(TOP
)/ext
/fts5
/fts5_tcl.c \
438 $(TOP
)/ext
/fts5
/fts5_test_mi.c \
439 $(TOP
)/ext
/fts5
/fts5_test_tok.c \
440 $(TOP
)/ext
/misc
/ieee754.c \
441 $(TOP
)/ext
/misc
/mmapwarm.c \
442 $(TOP
)/ext
/misc
/nextchar.c \
443 $(TOP
)/ext
/misc
/percentile.c \
444 $(TOP
)/ext
/misc
/regexp.c \
445 $(TOP
)/ext
/misc
/remember.c \
446 $(TOP
)/ext
/misc
/series.c \
447 $(TOP
)/ext
/misc
/spellfix.c \
448 $(TOP
)/ext
/misc
/totype.c \
449 $(TOP
)/ext
/misc
/unionvtab.c \
450 $(TOP
)/ext
/misc
/wholenumber.c \
451 $(TOP
)/ext
/misc
/zipfile.c
453 # Source code to the library files needed by the test fixture
456 $(TOP
)/src
/attach.c \
457 $(TOP
)/src
/backup.c \
458 $(TOP
)/src
/bitvec.c \
463 $(TOP
)/src
/dbpage.c \
464 $(TOP
)/src
/dbstat.c \
467 $(TOP
)/src
/insert.c \
472 $(TOP
)/src
/os_unix.c \
473 $(TOP
)/src
/os_win.c \
475 $(TOP
)/src
/pragma.c \
476 $(TOP
)/src
/prepare.c \
477 $(TOP
)/src
/printf.c \
478 $(TOP
)/src
/random.c \
479 $(TOP
)/src
/pcache.c \
480 $(TOP
)/src
/pcache1.c \
481 $(TOP
)/src
/select.c \
482 $(TOP
)/src
/tokenize.c \
485 $(TOP
)/src
/vdbeapi.c \
486 $(TOP
)/src
/vdbeaux.c \
488 $(TOP
)/src
/vdbemem.c \
489 $(TOP
)/src
/vdbetrace.c \
491 $(TOP
)/src
/wherecode.c \
492 $(TOP
)/src
/whereexpr.c \
494 $(TOP
)/ext
/fts3
/fts3.c \
495 $(TOP
)/ext
/fts3
/fts3_aux.c \
496 $(TOP
)/ext
/fts3
/fts3_expr.c \
497 $(TOP
)/ext
/fts3
/fts3_term.c \
498 $(TOP
)/ext
/fts3
/fts3_tokenizer.c \
499 $(TOP
)/ext
/fts3
/fts3_write.c \
500 $(TOP
)/ext
/async
/sqlite3async.c \
501 $(TOP
)/ext
/session
/sqlite3session.c \
502 $(TOP
)/ext
/misc
/stmt.c
504 # Header files used by all library source files.
508 $(TOP
)/src
/btreeInt.h \
510 $(TOP
)/src
/hwtime.h \
516 $(TOP
)/src
/os_common.h \
517 $(TOP
)/src
/os_setup.h \
518 $(TOP
)/src
/os_win.h \
520 $(TOP
)/src
/pcache.h \
522 $(TOP
)/src
/pragma.h \
524 $(TOP
)/src
/sqlite3ext.h \
525 $(TOP
)/src
/sqliteInt.h \
526 $(TOP
)/src
/sqliteLimit.h \
528 $(TOP
)/src
/vdbeInt.h \
529 $(TOP
)/src
/vxworks.h \
530 $(TOP
)/src
/whereInt.h \
533 # Header files used by extensions
536 $(TOP
)/ext
/fts1
/fts1.h \
537 $(TOP
)/ext
/fts1
/fts1_hash.h \
538 $(TOP
)/ext
/fts1
/fts1_tokenizer.h
540 $(TOP
)/ext
/fts2
/fts2.h \
541 $(TOP
)/ext
/fts2
/fts2_hash.h \
542 $(TOP
)/ext
/fts2
/fts2_tokenizer.h
544 $(TOP
)/ext
/fts3
/fts3.h \
545 $(TOP
)/ext
/fts3
/fts3Int.h \
546 $(TOP
)/ext
/fts3
/fts3_hash.h \
547 $(TOP
)/ext
/fts3
/fts3_tokenizer.h
549 $(TOP
)/ext
/rtree
/rtree.h
551 $(TOP
)/ext
/icu
/sqliteicu.h
553 $(TOP
)/ext
/rtree
/sqlite3rtree.h
555 # executables needed for testing
560 sqlite3_analyzer
$(TEXE
) \
564 # Databases containing fuzzer test cases
567 $(TOP
)/test/fuzzdata1.db \
568 $(TOP
)/test/fuzzdata2.db \
569 $(TOP
)/test/fuzzdata3.db \
570 $(TOP
)/test/fuzzdata4.db \
571 $(TOP
)/test/fuzzdata5.db
573 # Standard options to testfixture
575 TESTOPTS
= --verbose
=file
--output
=test-out.txt
577 # Extra compiler options for various shell tools
579 SHELL_OPT
= -DSQLITE_ENABLE_JSON1
-DSQLITE_ENABLE_FTS4
580 # SHELL_OPT += -DSQLITE_ENABLE_FTS5
581 SHELL_OPT
+= -DSQLITE_ENABLE_EXPLAIN_COMMENTS
582 SHELL_OPT
+= -DSQLITE_ENABLE_UNKNOWN_SQL_FUNCTION
583 SHELL_OPT
+= -DSQLITE_ENABLE_STMTVTAB
584 SHELL_OPT
+= -DSQLITE_ENABLE_DBPAGE_VTAB
585 SHELL_OPT
+= -DSQLITE_ENABLE_DBSTAT_VTAB
586 SHELL_OPT
+= -DSQLITE_ENABLE_OFFSET_SQL_FUNC
587 SHELL_OPT
+= -DSQLITE_INTROSPECTION_PRAGMAS
588 FUZZERSHELL_OPT
= -DSQLITE_ENABLE_JSON1
589 FUZZCHECK_OPT
= -DSQLITE_ENABLE_JSON1
-DSQLITE_ENABLE_MEMSYS5
-DSQLITE_OSS_FUZZ
590 FUZZCHECK_OPT
+= -DSQLITE_MAX_MEMORY
=50000000
591 FUZZCHECK_SRC
= $(TOP
)/test/fuzzcheck.c
$(TOP
)/test/ossfuzz.c
594 # This is the default Makefile target. The objects listed here
595 # are what get build when you type just "make" with no arguments.
597 all: sqlite3.h libsqlite3.la sqlite3
$(TEXE
) $(HAVE_TCL
:1=libtclsqlite3.la
)
599 Makefile
: $(TOP
)/Makefile.in
602 sqlite3.
pc: $(TOP
)/sqlite3.
pc.in
605 libsqlite3.la
: $(LIBOBJ
)
606 $(LTLINK
) -no-undefined
-o
$@
$(LIBOBJ
) $(TLIBS
) \
607 ${ALLOWRELEASE} -rpath
"$(libdir)" -version-info
"8:6:8"
609 libtclsqlite3.la
: tclsqlite.lo libsqlite3.la
610 $(LTLINK
) -no-undefined
-o
$@ tclsqlite.lo \
611 libsqlite3.la @TCL_STUB_LIB_SPEC@
$(TLIBS
) \
612 -rpath
"$(TCLLIBDIR)" \
613 -version-info
"8:6:8" \
616 sqlite3
$(TEXE
): shell.c sqlite3.c
617 $(LTLINK
) $(READLINE_FLAGS
) $(SHELL_OPT
) -o
$@ \
619 $(LIBREADLINE
) $(TLIBS
) -rpath
"$(libdir)"
621 sqldiff
$(TEXE
): $(TOP
)/tool
/sqldiff.c sqlite3.lo sqlite3.h
622 $(LTLINK
) -o
$@
$(TOP
)/tool
/sqldiff.c sqlite3.lo
$(TLIBS
)
624 dbhash
$(TEXE
): $(TOP
)/tool
/dbhash.c sqlite3.lo sqlite3.h
625 $(LTLINK
) -o
$@
$(TOP
)/tool
/dbhash.c sqlite3.lo
$(TLIBS
)
627 scrub
$(TEXE
): $(TOP
)/ext
/misc
/scrub.c sqlite3.lo
628 $(LTLINK
) -o
$@
-I.
-DSCRUB_STANDALONE \
629 $(TOP
)/ext
/misc
/scrub.c sqlite3.lo
$(TLIBS
)
631 srcck1
$(BEXE
): $(TOP
)/tool
/srcck1.c
632 $(BCC
) -o srcck1
$(BEXE
) $(TOP
)/tool
/srcck1.c
634 sourcetest
: srcck1
$(BEXE
) sqlite3.c
637 fuzzershell
$(TEXE
): $(TOP
)/tool
/fuzzershell.c sqlite3.c sqlite3.h
638 $(LTLINK
) -o
$@
$(FUZZERSHELL_OPT
) \
639 $(TOP
)/tool
/fuzzershell.c sqlite3.c
$(TLIBS
)
641 fuzzcheck
$(TEXE
): $(FUZZCHECK_SRC
) sqlite3.c sqlite3.h
642 $(LTLINK
) -o
$@
$(FUZZCHECK_OPT
) $(FUZZCHECK_SRC
) sqlite3.c
$(TLIBS
)
644 ossshell
$(TEXE
): $(TOP
)/test/ossfuzz.c
$(TOP
)/test/ossshell.c sqlite3.c sqlite3.h
645 $(LTLINK
) -o
$@
$(FUZZCHECK_OPT
) $(TOP
)/test/ossshell.c \
646 $(TOP
)/test/ossfuzz.c sqlite3.c
$(TLIBS
)
648 dbfuzz
$(TEXE
): $(TOP
)/test/dbfuzz.c sqlite3.c sqlite3.h
649 $(LTLINK
) -o
$@
$(DBFUZZ_OPT
) $(TOP
)/test/dbfuzz.c sqlite3.c
$(TLIBS
)
651 mptester
$(TEXE
): sqlite3.lo
$(TOP
)/mptest
/mptest.c
652 $(LTLINK
) -o
$@
-I.
$(TOP
)/mptest
/mptest.c sqlite3.lo \
653 $(TLIBS
) -rpath
"$(libdir)"
655 MPTEST1
=.
/mptester
$(TEXE
) mptest.db
$(TOP
)/mptest
/crash01.
test --repeat
20
656 MPTEST2
=.
/mptester
$(TEXE
) mptest.db
$(TOP
)/mptest
/multiwrite01.
test --repeat
20
657 mptest
: mptester
$(TEXE
)
659 $(MPTEST1
) --journalmode DELETE
660 $(MPTEST2
) --journalmode WAL
661 $(MPTEST1
) --journalmode WAL
662 $(MPTEST2
) --journalmode PERSIST
663 $(MPTEST1
) --journalmode PERSIST
664 $(MPTEST2
) --journalmode TRUNCATE
665 $(MPTEST1
) --journalmode TRUNCATE
666 $(MPTEST2
) --journalmode DELETE
669 # This target creates a directory named "tsrc" and fills it with
670 # copies of all of the C source code and header files needed to
671 # build on the target system. Some of the C source code and header
672 # files are automatically generated. This target takes care of
673 # all that automatic generation.
675 .target_source
: $(SRC
) $(TOP
)/tool
/vdbe-compress.tcl fts5.c
679 rm tsrc
/sqlite.h.in tsrc
/parse.y
680 $(TCLSH_CMD
) $(TOP
)/tool
/vdbe-compress.tcl
$(OPTS
) <tsrc
/vdbe.c
>vdbe.new
681 mv vdbe.new tsrc
/vdbe.c
682 cp fts5.c fts5.h tsrc
685 sqlite3.c
: .target_source
$(TOP
)/tool
/mksqlite3c.tcl
686 $(TCLSH_CMD
) $(TOP
)/tool
/mksqlite3c.tcl
687 cp tsrc
/sqlite3ext.h .
688 cp
$(TOP
)/ext
/session
/sqlite3session.h .
690 sqlite3ext.h
: .target_source
691 cp tsrc
/sqlite3ext.h .
693 tclsqlite3.c
: sqlite3.c
694 echo
'#ifndef USE_SYSTEM_SQLITE' >tclsqlite3.c
695 cat sqlite3.c
>>tclsqlite3.c
696 echo
'#endif /* USE_SYSTEM_SQLITE */' >>tclsqlite3.c
697 cat
$(TOP
)/src
/tclsqlite.c
>>tclsqlite3.c
699 sqlite3-all.c
: sqlite3.c
$(TOP
)/tool
/split-sqlite3c.tcl
700 $(TCLSH_CMD
) $(TOP
)/tool
/split-sqlite3c.tcl
702 # Rule to build the amalgamation
704 sqlite3.lo
: sqlite3.c
705 $(LTCOMPILE
) $(TEMP_STORE
) -c sqlite3.c
707 # Rules to build the LEMON compiler generator
709 lemon
$(BEXE
): $(TOP
)/tool
/lemon.c
$(TOP
)/tool
/lempar.c
710 $(BCC
) -o
$@
$(TOP
)/tool
/lemon.c
711 cp
$(TOP
)/tool
/lempar.c .
713 # Rules to build the program that generates the source-id
715 mksourceid
$(BEXE
): $(TOP
)/tool
/mksourceid.c
716 $(BCC
) -o
$@
$(TOP
)/tool
/mksourceid.c
718 # Rules to build individual *.o files from generated *.c files. This
724 parse.lo
: parse.c
$(HDR
)
725 $(LTCOMPILE
) $(TEMP_STORE
) -c parse.c
727 opcodes.lo
: opcodes.c
728 $(LTCOMPILE
) $(TEMP_STORE
) -c opcodes.c
730 # Rules to build individual *.o files from files in the src directory.
732 alter.lo
: $(TOP
)/src
/alter.c
$(HDR
)
733 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/alter.c
735 analyze.lo
: $(TOP
)/src
/analyze.c
$(HDR
)
736 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/analyze.c
738 attach.lo
: $(TOP
)/src
/attach.c
$(HDR
)
739 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/attach.c
741 auth.lo
: $(TOP
)/src
/auth.c
$(HDR
)
742 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/auth.c
744 backup.lo
: $(TOP
)/src
/backup.c
$(HDR
)
745 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/backup.c
747 bitvec.lo
: $(TOP
)/src
/bitvec.c
$(HDR
)
748 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/bitvec.c
750 btmutex.lo
: $(TOP
)/src
/btmutex.c
$(HDR
)
751 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/btmutex.c
753 btree.lo
: $(TOP
)/src
/btree.c
$(HDR
) $(TOP
)/src
/pager.h
754 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/btree.c
756 build.lo
: $(TOP
)/src
/build.c
$(HDR
)
757 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/build.c
759 callback.lo
: $(TOP
)/src
/callback.c
$(HDR
)
760 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/callback.c
762 complete.lo
: $(TOP
)/src
/complete.c
$(HDR
)
763 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/complete.c
765 ctime.lo
: $(TOP
)/src
/ctime.c
$(HDR
)
766 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/ctime.c
768 date.lo
: $(TOP
)/src
/date.c
$(HDR
)
769 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/date.c
771 dbpage.lo
: $(TOP
)/src
/dbpage.c
$(HDR
)
772 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/dbpage.c
774 dbstat.lo
: $(TOP
)/src
/dbstat.c
$(HDR
)
775 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/dbstat.c
777 delete.lo
: $(TOP
)/src
/delete.c
$(HDR
)
778 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/delete.c
780 expr.lo
: $(TOP
)/src
/expr.c
$(HDR
)
781 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/expr.c
783 fault.lo
: $(TOP
)/src
/fault.c
$(HDR
)
784 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/fault.c
786 fkey.lo
: $(TOP
)/src
/fkey.c
$(HDR
)
787 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/fkey.c
789 func.lo
: $(TOP
)/src
/func.c
$(HDR
)
790 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/func.c
792 global.lo
: $(TOP
)/src
/global.c
$(HDR
)
793 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/global.c
795 hash.lo
: $(TOP
)/src
/hash.c
$(HDR
)
796 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/hash.c
798 insert.lo
: $(TOP
)/src
/insert.c
$(HDR
)
799 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/insert.c
801 legacy.lo
: $(TOP
)/src
/legacy.c
$(HDR
)
802 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/legacy.c
804 loadext.lo
: $(TOP
)/src
/loadext.c
$(HDR
)
805 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/loadext.c
807 main.lo
: $(TOP
)/src
/main.c
$(HDR
)
808 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/main.c
810 malloc.lo
: $(TOP
)/src
/malloc.c
$(HDR
)
811 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/malloc.c
813 mem0.lo
: $(TOP
)/src
/mem0.c
$(HDR
)
814 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/mem0.c
816 mem1.lo
: $(TOP
)/src
/mem1.c
$(HDR
)
817 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/mem1.c
819 mem2.lo
: $(TOP
)/src
/mem2.c
$(HDR
)
820 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/mem2.c
822 mem3.lo
: $(TOP
)/src
/mem3.c
$(HDR
)
823 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/mem3.c
825 mem5.lo
: $(TOP
)/src
/mem5.c
$(HDR
)
826 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/mem5.c
828 memjournal.lo
: $(TOP
)/src
/memjournal.c
$(HDR
)
829 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/memjournal.c
831 mutex.lo
: $(TOP
)/src
/mutex.c
$(HDR
)
832 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/mutex.c
834 mutex_noop.lo
: $(TOP
)/src
/mutex_noop.c
$(HDR
)
835 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/mutex_noop.c
837 mutex_unix.lo
: $(TOP
)/src
/mutex_unix.c
$(HDR
)
838 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/mutex_unix.c
840 mutex_w32.lo
: $(TOP
)/src
/mutex_w32.c
$(HDR
)
841 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/mutex_w32.c
843 notify.lo
: $(TOP
)/src
/notify.c
$(HDR
)
844 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/notify.c
846 pager.lo
: $(TOP
)/src
/pager.c
$(HDR
) $(TOP
)/src
/pager.h
847 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/pager.c
849 pcache.lo
: $(TOP
)/src
/pcache.c
$(HDR
) $(TOP
)/src
/pcache.h
850 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/pcache.c
852 pcache1.lo
: $(TOP
)/src
/pcache1.c
$(HDR
) $(TOP
)/src
/pcache.h
853 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/pcache1.c
855 os.lo
: $(TOP
)/src
/os.c
$(HDR
)
856 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/os.c
858 os_unix.lo
: $(TOP
)/src
/os_unix.c
$(HDR
)
859 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/os_unix.c
861 os_win.lo
: $(TOP
)/src
/os_win.c
$(HDR
)
862 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/os_win.c
864 pragma.lo
: $(TOP
)/src
/pragma.c
$(HDR
)
865 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/pragma.c
867 prepare.lo
: $(TOP
)/src
/prepare.c
$(HDR
)
868 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/prepare.c
870 printf.lo
: $(TOP
)/src
/printf.c
$(HDR
)
871 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/printf.c
873 random.lo
: $(TOP
)/src
/random.c
$(HDR
)
874 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/random.c
876 resolve.lo
: $(TOP
)/src
/resolve.c
$(HDR
)
877 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/resolve.c
879 rowset.lo
: $(TOP
)/src
/rowset.c
$(HDR
)
880 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/rowset.c
882 select.lo
: $(TOP
)/src
/select.c
$(HDR
)
883 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/select.c
885 status.lo
: $(TOP
)/src
/status.c
$(HDR
)
886 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/status.c
888 table.lo
: $(TOP
)/src
/table.c
$(HDR
)
889 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/table.c
891 threads.lo
: $(TOP
)/src
/threads.c
$(HDR
)
892 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/threads.c
894 tokenize.lo
: $(TOP
)/src
/tokenize.c keywordhash.h
$(HDR
)
895 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/tokenize.c
897 treeview.lo
: $(TOP
)/src
/treeview.c
$(HDR
)
898 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/treeview.c
900 trigger.lo
: $(TOP
)/src
/trigger.c
$(HDR
)
901 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/trigger.c
903 update.lo
: $(TOP
)/src
/update.c
$(HDR
)
904 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/update.c
906 utf.lo
: $(TOP
)/src
/utf.c
$(HDR
)
907 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/utf.c
909 util.lo
: $(TOP
)/src
/util.c
$(HDR
)
910 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/util.c
912 vacuum.lo
: $(TOP
)/src
/vacuum.c
$(HDR
)
913 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/vacuum.c
915 vdbe.lo
: $(TOP
)/src
/vdbe.c
$(HDR
)
916 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/vdbe.c
918 vdbeapi.lo
: $(TOP
)/src
/vdbeapi.c
$(HDR
)
919 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/vdbeapi.c
921 vdbeaux.lo
: $(TOP
)/src
/vdbeaux.c
$(HDR
)
922 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/vdbeaux.c
924 vdbeblob.lo
: $(TOP
)/src
/vdbeblob.c
$(HDR
)
925 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/vdbeblob.c
927 vdbemem.lo
: $(TOP
)/src
/vdbemem.c
$(HDR
)
928 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/vdbemem.c
930 vdbesort.lo
: $(TOP
)/src
/vdbesort.c
$(HDR
)
931 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/vdbesort.c
933 vdbetrace.lo
: $(TOP
)/src
/vdbetrace.c
$(HDR
)
934 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/vdbetrace.c
936 vtab.lo
: $(TOP
)/src
/vtab.c
$(HDR
)
937 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/vtab.c
939 wal.lo
: $(TOP
)/src
/wal.c
$(HDR
)
940 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/wal.c
942 walker.lo
: $(TOP
)/src
/walker.c
$(HDR
)
943 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/walker.c
945 where.lo
: $(TOP
)/src
/where.c
$(HDR
)
946 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/where.c
948 wherecode.lo
: $(TOP
)/src
/wherecode.c
$(HDR
)
949 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/wherecode.c
951 whereexpr.lo
: $(TOP
)/src
/whereexpr.c
$(HDR
)
952 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/whereexpr.c
954 tclsqlite.lo
: $(TOP
)/src
/tclsqlite.c
$(HDR
)
955 $(LTCOMPILE
) -DUSE_TCL_STUBS
=1 -c
$(TOP
)/src
/tclsqlite.c
957 tclsqlite-shell.lo
: $(TOP
)/src
/tclsqlite.c
$(HDR
)
958 $(LTCOMPILE
) -DTCLSH
-o
$@
-c
$(TOP
)/src
/tclsqlite.c
960 tclsqlite-stubs.lo
: $(TOP
)/src
/tclsqlite.c
$(HDR
)
961 $(LTCOMPILE
) -DUSE_TCL_STUBS
=1 -o
$@
-c
$(TOP
)/src
/tclsqlite.c
963 tclsqlite3
$(TEXE
): tclsqlite-shell.lo libsqlite3.la
964 $(LTLINK
) -o
$@ tclsqlite-shell.lo \
965 libsqlite3.la
$(LIBTCL
)
967 # Rules to build opcodes.c and opcodes.h
969 opcodes.c
: opcodes.h
$(TOP
)/tool
/mkopcodec.tcl
970 $(TCLSH_CMD
) $(TOP
)/tool
/mkopcodec.tcl opcodes.h
>opcodes.c
972 opcodes.h
: parse.h
$(TOP
)/src
/vdbe.c
$(TOP
)/tool
/mkopcodeh.tcl
973 cat parse.h
$(TOP
)/src
/vdbe.c |
$(TCLSH_CMD
) $(TOP
)/tool
/mkopcodeh.tcl
>opcodes.h
975 # Rules to build parse.c and parse.h - the outputs of lemon.
979 parse.c
: $(TOP
)/src
/parse.y lemon
$(BEXE
) $(TOP
)/tool
/addopcodes.tcl
980 cp
$(TOP
)/src
/parse.y .
982 .
/lemon
$(BEXE
) $(OPT_FEATURE_FLAGS
) $(OPTS
) parse.y
983 mv parse.h parse.h.temp
984 $(TCLSH_CMD
) $(TOP
)/tool
/addopcodes.tcl parse.h.temp
>parse.h
986 sqlite3.h
: $(TOP
)/src
/sqlite.h.in
$(TOP
)/manifest mksourceid
$(BEXE
) $(TOP
)/VERSION
987 $(TCLSH_CMD
) $(TOP
)/tool
/mksqlite3h.tcl
$(TOP
) >sqlite3.h
989 keywordhash.h
: $(TOP
)/tool
/mkkeywordhash.c
990 $(BCC
) -o mkkeywordhash
$(BEXE
) $(OPT_FEATURE_FLAGS
) $(OPTS
) $(TOP
)/tool
/mkkeywordhash.c
991 .
/mkkeywordhash
$(BEXE
) >keywordhash.h
993 # Source files that go into making shell.c
995 $(TOP
)/src
/shell.c.in \
996 $(TOP
)/ext
/misc
/shathree.c \
997 $(TOP
)/ext
/misc
/fileio.c \
998 $(TOP
)/ext
/misc
/completion.c \
999 $(TOP
)/ext
/misc
/sqlar.c \
1000 $(TOP
)/ext
/expert
/sqlite3expert.c \
1001 $(TOP
)/ext
/expert
/sqlite3expert.h \
1002 $(TOP
)/ext
/misc
/zipfile.c \
1003 $(TOP
)/src
/test_windirent.c
1005 shell.c
: $(SHELL_SRC
) $(TOP
)/tool
/mkshellc.tcl
1006 $(TCLSH_CMD
) $(TOP
)/tool
/mkshellc.tcl
>shell.c
1011 # Rules to build the extension objects.
1013 icu.lo
: $(TOP
)/ext
/icu
/icu.c
$(HDR
) $(EXTHDR
)
1014 $(LTCOMPILE
) -DSQLITE_CORE
-c
$(TOP
)/ext
/icu
/icu.c
1016 fts2.lo
: $(TOP
)/ext
/fts2
/fts2.c
$(HDR
) $(EXTHDR
)
1017 $(LTCOMPILE
) -DSQLITE_CORE
-c
$(TOP
)/ext
/fts2
/fts2.c
1019 fts2_hash.lo
: $(TOP
)/ext
/fts2
/fts2_hash.c
$(HDR
) $(EXTHDR
)
1020 $(LTCOMPILE
) -DSQLITE_CORE
-c
$(TOP
)/ext
/fts2
/fts2_hash.c
1022 fts2_icu.lo
: $(TOP
)/ext
/fts2
/fts2_icu.c
$(HDR
) $(EXTHDR
)
1023 $(LTCOMPILE
) -DSQLITE_CORE
-c
$(TOP
)/ext
/fts2
/fts2_icu.c
1025 fts2_porter.lo
: $(TOP
)/ext
/fts2
/fts2_porter.c
$(HDR
) $(EXTHDR
)
1026 $(LTCOMPILE
) -DSQLITE_CORE
-c
$(TOP
)/ext
/fts2
/fts2_porter.c
1028 fts2_tokenizer.lo
: $(TOP
)/ext
/fts2
/fts2_tokenizer.c
$(HDR
) $(EXTHDR
)
1029 $(LTCOMPILE
) -DSQLITE_CORE
-c
$(TOP
)/ext
/fts2
/fts2_tokenizer.c
1031 fts2_tokenizer1.lo
: $(TOP
)/ext
/fts2
/fts2_tokenizer1.c
$(HDR
) $(EXTHDR
)
1032 $(LTCOMPILE
) -DSQLITE_CORE
-c
$(TOP
)/ext
/fts2
/fts2_tokenizer1.c
1034 fts3.lo
: $(TOP
)/ext
/fts3
/fts3.c
$(HDR
) $(EXTHDR
)
1035 $(LTCOMPILE
) -DSQLITE_CORE
-c
$(TOP
)/ext
/fts3
/fts3.c
1037 fts3_aux.lo
: $(TOP
)/ext
/fts3
/fts3_aux.c
$(HDR
) $(EXTHDR
)
1038 $(LTCOMPILE
) -DSQLITE_CORE
-c
$(TOP
)/ext
/fts3
/fts3_aux.c
1040 fts3_expr.lo
: $(TOP
)/ext
/fts3
/fts3_expr.c
$(HDR
) $(EXTHDR
)
1041 $(LTCOMPILE
) -DSQLITE_CORE
-c
$(TOP
)/ext
/fts3
/fts3_expr.c
1043 fts3_hash.lo
: $(TOP
)/ext
/fts3
/fts3_hash.c
$(HDR
) $(EXTHDR
)
1044 $(LTCOMPILE
) -DSQLITE_CORE
-c
$(TOP
)/ext
/fts3
/fts3_hash.c
1046 fts3_icu.lo
: $(TOP
)/ext
/fts3
/fts3_icu.c
$(HDR
) $(EXTHDR
)
1047 $(LTCOMPILE
) -DSQLITE_CORE
-c
$(TOP
)/ext
/fts3
/fts3_icu.c
1049 fts3_porter.lo
: $(TOP
)/ext
/fts3
/fts3_porter.c
$(HDR
) $(EXTHDR
)
1050 $(LTCOMPILE
) -DSQLITE_CORE
-c
$(TOP
)/ext
/fts3
/fts3_porter.c
1052 fts3_snippet.lo
: $(TOP
)/ext
/fts3
/fts3_snippet.c
$(HDR
) $(EXTHDR
)
1053 $(LTCOMPILE
) -DSQLITE_CORE
-c
$(TOP
)/ext
/fts3
/fts3_snippet.c
1055 fts3_tokenizer.lo
: $(TOP
)/ext
/fts3
/fts3_tokenizer.c
$(HDR
) $(EXTHDR
)
1056 $(LTCOMPILE
) -DSQLITE_CORE
-c
$(TOP
)/ext
/fts3
/fts3_tokenizer.c
1058 fts3_tokenizer1.lo
: $(TOP
)/ext
/fts3
/fts3_tokenizer1.c
$(HDR
) $(EXTHDR
)
1059 $(LTCOMPILE
) -DSQLITE_CORE
-c
$(TOP
)/ext
/fts3
/fts3_tokenizer1.c
1061 fts3_tokenize_vtab.lo
: $(TOP
)/ext
/fts3
/fts3_tokenize_vtab.c
$(HDR
) $(EXTHDR
)
1062 $(LTCOMPILE
) -DSQLITE_CORE
-c
$(TOP
)/ext
/fts3
/fts3_tokenize_vtab.c
1064 fts3_unicode.lo
: $(TOP
)/ext
/fts3
/fts3_unicode.c
$(HDR
) $(EXTHDR
)
1065 $(LTCOMPILE
) -DSQLITE_CORE
-c
$(TOP
)/ext
/fts3
/fts3_unicode.c
1067 fts3_unicode2.lo
: $(TOP
)/ext
/fts3
/fts3_unicode2.c
$(HDR
) $(EXTHDR
)
1068 $(LTCOMPILE
) -DSQLITE_CORE
-c
$(TOP
)/ext
/fts3
/fts3_unicode2.c
1070 fts3_write.lo
: $(TOP
)/ext
/fts3
/fts3_write.c
$(HDR
) $(EXTHDR
)
1071 $(LTCOMPILE
) -DSQLITE_CORE
-c
$(TOP
)/ext
/fts3
/fts3_write.c
1073 rtree.lo
: $(TOP
)/ext
/rtree
/rtree.c
$(HDR
) $(EXTHDR
)
1074 $(LTCOMPILE
) -DSQLITE_CORE
-c
$(TOP
)/ext
/rtree
/rtree.c
1076 sqlite3session.lo
: $(TOP
)/ext
/session
/sqlite3session.c
$(HDR
) $(EXTHDR
)
1077 $(LTCOMPILE
) -DSQLITE_CORE
-c
$(TOP
)/ext
/session
/sqlite3session.c
1079 json1.lo
: $(TOP
)/ext
/misc
/json1.c
1080 $(LTCOMPILE
) -DSQLITE_CORE
-c
$(TOP
)/ext
/misc
/json1.c
1082 stmt.lo
: $(TOP
)/ext
/misc
/stmt.c
1083 $(LTCOMPILE
) -DSQLITE_CORE
-c
$(TOP
)/ext
/misc
/stmt.c
1088 $(TOP
)/ext
/fts5
/fts5.h \
1089 $(TOP
)/ext
/fts5
/fts5Int.h \
1090 $(TOP
)/ext
/fts5
/fts5_aux.c \
1091 $(TOP
)/ext
/fts5
/fts5_buffer.c \
1092 $(TOP
)/ext
/fts5
/fts5_main.c \
1093 $(TOP
)/ext
/fts5
/fts5_config.c \
1094 $(TOP
)/ext
/fts5
/fts5_expr.c \
1095 $(TOP
)/ext
/fts5
/fts5_hash.c \
1096 $(TOP
)/ext
/fts5
/fts5_index.c \
1097 fts5parse.c fts5parse.h \
1098 $(TOP
)/ext
/fts5
/fts5_storage.c \
1099 $(TOP
)/ext
/fts5
/fts5_tokenize.c \
1100 $(TOP
)/ext
/fts5
/fts5_unicode2.c \
1101 $(TOP
)/ext
/fts5
/fts5_varint.c \
1102 $(TOP
)/ext
/fts5
/fts5_vocab.c \
1104 fts5parse.c
: $(TOP
)/ext
/fts5
/fts5parse.y lemon
1105 cp
$(TOP
)/ext
/fts5
/fts5parse.y .
1107 .
/lemon
$(BEXE
) $(OPTS
) fts5parse.y
1109 fts5parse.h
: fts5parse.c
1112 $(TCLSH_CMD
) $(TOP
)/ext
/fts5
/tool
/mkfts5c.tcl
1113 cp
$(TOP
)/ext
/fts5
/fts5.h .
1115 fts5.lo
: fts5.c
$(HDR
) $(EXTHDR
)
1116 $(LTCOMPILE
) -DSQLITE_CORE
-c fts5.c
1118 sqlite3rbu.lo
: $(TOP
)/ext
/rbu
/sqlite3rbu.c
$(HDR
) $(EXTHDR
)
1119 $(LTCOMPILE
) -DSQLITE_CORE
-c
$(TOP
)/ext
/rbu
/sqlite3rbu.c
1122 # Rules to build the 'testfixture' application.
1124 # If using the amalgamation, use sqlite3.c directly to build the test
1125 # fixture. Otherwise link against libsqlite3.la. (This distinction is
1126 # necessary because the test fixture requires non-API symbols which are
1127 # hidden when the library is built via the amalgamation).
1129 TESTFIXTURE_FLAGS
= -DSQLITE_TEST
=1 -DSQLITE_CRASH_TEST
=1
1130 TESTFIXTURE_FLAGS
+= -DTCLSH_INIT_PROC
=sqlite3TestInit
1131 TESTFIXTURE_FLAGS
+= -DSQLITE_SERVER
=1 -DSQLITE_PRIVATE
="" -DSQLITE_CORE
1132 TESTFIXTURE_FLAGS
+= -DBUILD_sqlite
1133 TESTFIXTURE_FLAGS
+= -DSQLITE_SERIES_CONSTRAINT_VERIFY
=1
1134 TESTFIXTURE_FLAGS
+= -DSQLITE_DEFAULT_PAGE_SIZE
=1024
1135 TESTFIXTURE_FLAGS
+= -DSQLITE_ENABLE_STMTVTAB
1136 TESTFIXTURE_FLAGS
+= -DSQLITE_ENABLE_DBPAGE_VTAB
1138 TESTFIXTURE_SRC0
= $(TESTSRC2
) libsqlite3.la
1139 TESTFIXTURE_SRC1
= sqlite3.c
1140 TESTFIXTURE_SRC
= $(TESTSRC
) $(TOP
)/src
/tclsqlite.c
1141 TESTFIXTURE_SRC
+= $(TESTFIXTURE_SRC
$(USE_AMALGAMATION
))
1143 testfixture
$(TEXE
): $(TESTFIXTURE_SRC
)
1144 $(LTLINK
) -DSQLITE_NO_SYNC
=1 $(TEMP_STORE
) $(TESTFIXTURE_FLAGS
) \
1145 -o
$@
$(TESTFIXTURE_SRC
) $(LIBTCL
) $(TLIBS
)
1147 # A very detailed test running most or all test cases
1148 fulltest
: $(TESTPROGS
) fuzztest
1149 .
/testfixture
$(TEXE
) $(TOP
)/test/all.
test $(TESTOPTS
)
1151 # Really really long testing
1152 soaktest
: $(TESTPROGS
)
1153 .
/testfixture
$(TEXE
) $(TOP
)/test/all.
test -soak
=1 $(TESTOPTS
)
1155 # Do extra testing but not everything.
1156 fulltestonly
: $(TESTPROGS
) fuzztest
1157 .
/testfixture
$(TEXE
) $(TOP
)/test/full.
test
1160 fuzztest
: fuzzcheck
$(TEXE
) $(FUZZDATA
)
1161 .
/fuzzcheck
$(TEXE
) $(FUZZDATA
)
1163 fastfuzztest
: fuzzcheck
$(TEXE
) $(FUZZDATA
)
1164 .
/fuzzcheck
$(TEXE
) --limit-mem
100M
$(FUZZDATA
)
1166 valgrindfuzz
: fuzzcheck
$(TEXT
) $(FUZZDATA
)
1167 valgrind .
/fuzzcheck
$(TEXE
) --cell-size-check
--limit-mem
10M
--timeout
600 $(FUZZDATA
)
1169 # The veryquick.test TCL tests.
1171 tcltest
: .
/testfixture
$(TEXE
)
1172 .
/testfixture
$(TEXE
) $(TOP
)/test/veryquick.
test $(TESTOPTS
)
1174 # Minimal testing that runs in less than 3 minutes
1176 quicktest
: .
/testfixture
$(TEXE
)
1177 .
/testfixture
$(TEXE
) $(TOP
)/test/extraquick.
test $(TESTOPTS
)
1179 # This is the common case. Run many tests that do not take too long,
1180 # including fuzzcheck, sqlite3_analyzer, and sqldiff tests.
1182 test: fastfuzztest sourcetest
$(TESTPROGS
) tcltest
1184 # Run a test using valgrind. This can take a really long time
1185 # because valgrind is so much slower than a native machine.
1187 valgrindtest
: $(TESTPROGS
) valgrindfuzz
1188 OMIT_MISUSE
=1 valgrind
-v .
/testfixture
$(TEXE
) $(TOP
)/test/permutations.
test valgrind
$(TESTOPTS
)
1190 # A very fast test that checks basic sanity. The name comes from
1191 # the 60s-era electronics testing: "Turn it on and see if smoke
1194 smoketest
: $(TESTPROGS
) fuzzcheck
$(TEXE
)
1195 .
/testfixture
$(TEXE
) $(TOP
)/test/main.
test $(TESTOPTS
)
1197 sqlite3_analyzer.c
: sqlite3.c
$(TOP
)/src
/tclsqlite.c
$(TOP
)/tool
/spaceanal.tcl
$(TOP
)/tool
/mkccode.tcl
$(TOP
)/tool
/sqlite3_analyzer.c.in
1198 $(TCLSH_CMD
) $(TOP
)/tool
/mkccode.tcl
$(TOP
)/tool
/sqlite3_analyzer.c.in
>sqlite3_analyzer.c
1200 sqlite3_analyzer
$(TEXE
): sqlite3_analyzer.c
1201 $(LTLINK
) sqlite3_analyzer.c
-o
$@
$(LIBTCL
) $(TLIBS
)
1203 sqlite3_expert
$(TEXE
): $(TOP
)/ext
/expert
/sqlite3expert.h
$(TOP
)/ext
/expert
/sqlite3expert.c
$(TOP
)/ext
/expert
/expert.c sqlite3.c
1204 $(LTLINK
) $(TOP
)/ext
/expert
/sqlite3expert.h
$(TOP
)/ext
/expert
/sqlite3expert.c
$(TOP
)/ext
/expert
/expert.c sqlite3.c
-o sqlite3_expert
$(TLIBS
)
1207 $(TOP
)/tool
/mkccode.tcl \
1209 $(TOP
)/src
/tclsqlite.c \
1210 $(TOP
)/ext
/repair
/sqlite3_checker.tcl \
1211 $(TOP
)/ext
/repair
/checkindex.c \
1212 $(TOP
)/ext
/repair
/checkfreelist.c \
1213 $(TOP
)/ext
/misc
/btreeinfo.c \
1214 $(TOP
)/ext
/repair
/sqlite3_checker.c.in
1216 sqlite3_checker.c
: $(CHECKER_DEPS
)
1217 $(TCLSH_CMD
) $(TOP
)/tool
/mkccode.tcl
$(TOP
)/ext
/repair
/sqlite3_checker.c.in
>$@
1219 sqlite3_checker
$(TEXE
): sqlite3_checker.c
1220 $(LTLINK
) sqlite3_checker.c
-o
$@
$(LIBTCL
) $(TLIBS
)
1222 dbdump
$(TEXE
): $(TOP
)/ext
/misc
/dbdump.c sqlite3.lo
1223 $(LTLINK
) -DDBDUMP_STANDALONE
-o
$@ \
1224 $(TOP
)/ext
/misc
/dbdump.c sqlite3.lo
$(TLIBS
)
1226 showdb
$(TEXE
): $(TOP
)/tool
/showdb.c sqlite3.lo
1227 $(LTLINK
) -o
$@
$(TOP
)/tool
/showdb.c sqlite3.lo
$(TLIBS
)
1229 showstat4
$(TEXE
): $(TOP
)/tool
/showstat4.c sqlite3.lo
1230 $(LTLINK
) -o
$@
$(TOP
)/tool
/showstat4.c sqlite3.lo
$(TLIBS
)
1232 showjournal
$(TEXE
): $(TOP
)/tool
/showjournal.c sqlite3.lo
1233 $(LTLINK
) -o
$@
$(TOP
)/tool
/showjournal.c sqlite3.lo
$(TLIBS
)
1235 showwal
$(TEXE
): $(TOP
)/tool
/showwal.c sqlite3.lo
1236 $(LTLINK
) -o
$@
$(TOP
)/tool
/showwal.c sqlite3.lo
$(TLIBS
)
1238 showshm
$(TEXE
): $(TOP
)/tool
/showshm.c
1239 $(LTLINK
) -o
$@
$(TOP
)/tool
/showshm.c
1241 changeset
$(TEXE
): $(TOP
)/ext
/session
/changeset.c sqlite3.lo
1242 $(LTLINK
) -o
$@
$(TOP
)/ext
/session
/changeset.c sqlite3.lo
$(TLIBS
)
1244 rollback-test
$(TEXE
): $(TOP
)/tool
/rollback-test.c sqlite3.lo
1245 $(LTLINK
) -o
$@
$(TOP
)/tool
/rollback-test.c sqlite3.lo
$(TLIBS
)
1247 LogEst
$(TEXE
): $(TOP
)/tool
/logest.c sqlite3.h
1248 $(LTLINK
) -I.
-o
$@
$(TOP
)/tool
/logest.c
1250 wordcount
$(TEXE
): $(TOP
)/test/wordcount.c sqlite3.lo
1251 $(LTLINK
) -o
$@
$(TOP
)/test/wordcount.c sqlite3.lo
$(TLIBS
)
1253 speedtest1
$(TEXE
): $(TOP
)/test/speedtest1.c sqlite3.c
1254 $(LTLINK
) $(ST_OPT
) -o
$@
$(TOP
)/test/speedtest1.c sqlite3.c
$(TLIBS
)
1256 KV_OPT
+= -DSQLITE_DIRECT_OVERFLOW_READ
1258 kvtest
$(TEXE
): $(TOP
)/test/kvtest.c sqlite3.c
1259 $(LTLINK
) $(KV_OPT
) -o
$@
$(TOP
)/test/kvtest.c sqlite3.c
$(TLIBS
)
1261 rbu
$(EXE
): $(TOP
)/ext
/rbu
/rbu.c
$(TOP
)/ext
/rbu
/sqlite3rbu.c sqlite3.lo
1262 $(LTLINK
) -I.
-o
$@
$(TOP
)/ext
/rbu
/rbu.c sqlite3.lo
$(TLIBS
)
1264 loadfts
$(EXE
): $(TOP
)/tool
/loadfts.c libsqlite3.la
1265 $(LTLINK
) $(TOP
)/tool
/loadfts.c libsqlite3.la
-o
$@
$(TLIBS
)
1267 # This target will fail if the SQLite amalgamation contains any exported
1268 # symbols that do not begin with "sqlite3_". It is run as part of the
1269 # releasetest.tcl script.
1271 VALIDIDS
=' sqlite3(changeset|changegroup|session)?_'
1272 checksymbols
: sqlite3.lo
1273 nm
-g
--defined-only sqlite3.lo | egrep
-v
$(VALIDIDS
); test $$?
-ne
0
1274 echo
'0 errors out of 1 tests'
1276 # Build the amalgamation-autoconf package. The amalamgation-tarball target builds
1277 # a tarball named for the version number. Ex: sqlite-autoconf-3110000.tar.gz.
1278 # The snapshot-tarball target builds a tarball named by the SHA1 hash
1280 amalgamation-tarball
: sqlite3.c
1281 TOP
=$(TOP
) sh
$(TOP
)/tool
/mkautoconfamal.sh
--normal
1283 snapshot-tarball
: sqlite3.c
1284 TOP
=$(TOP
) sh
$(TOP
)/tool
/mkautoconfamal.sh
--snapshot
1286 # The next two rules are used to support the "threadtest" target. Building
1287 # threadtest runs a few thread-safety tests that are implemented in C. This
1288 # target is invoked by the releasetest.tcl script.
1290 THREADTEST3_SRC
= $(TOP
)/test/threadtest3.c \
1291 $(TOP
)/test/tt3_checkpoint.c \
1292 $(TOP
)/test/tt3_index.c \
1293 $(TOP
)/test/tt3_vacuum.c \
1294 $(TOP
)/test/tt3_stress.c \
1295 $(TOP
)/test/tt3_lookaside1.c
1297 threadtest3
$(TEXE
): sqlite3.lo
$(THREADTEST3_SRC
)
1298 $(LTLINK
) $(TOP
)/test/threadtest3.c
$(TOP
)/src
/test_multiplex.c sqlite3.lo
-o
$@
$(TLIBS
)
1300 threadtest
: threadtest3
$(TEXE
)
1301 .
/threadtest3
$(TEXE
)
1304 $(TCLSH_CMD
) $(TOP
)/test/releasetest.tcl
1306 # Standard install and cleanup targets
1308 lib_install
: libsqlite3.la
1309 $(INSTALL
) -d
$(DESTDIR
)$(libdir)
1310 $(LTINSTALL
) libsqlite3.la
$(DESTDIR
)$(libdir)
1312 install: sqlite3
$(TEXE
) lib_install sqlite3.h sqlite3.
pc ${HAVE_TCL
:1=tcl_install
}
1313 $(INSTALL
) -d
$(DESTDIR
)$(bindir)
1314 $(LTINSTALL
) sqlite3
$(TEXE
) $(DESTDIR
)$(bindir)
1315 $(INSTALL
) -d
$(DESTDIR
)$(includedir)
1316 $(INSTALL
) -m
0644 sqlite3.h
$(DESTDIR
)$(includedir)
1317 $(INSTALL
) -m
0644 $(TOP
)/src
/sqlite3ext.h
$(DESTDIR
)$(includedir)
1318 $(INSTALL
) -d
$(DESTDIR
)$(pkgconfigdir
)
1319 $(INSTALL
) -m
0644 sqlite3.
pc $(DESTDIR
)$(pkgconfigdir
)
1322 echo
'package ifneeded sqlite3 $(RELEASE) [list load $(TCLLIBDIR)/libtclsqlite3$(SHLIB_SUFFIX) sqlite3]' > $@
1323 tcl_install
: lib_install libtclsqlite3.la pkgIndex.tcl
1324 $(INSTALL
) -d
$(DESTDIR
)$(TCLLIBDIR
)
1325 $(LTINSTALL
) libtclsqlite3.la
$(DESTDIR
)$(TCLLIBDIR
)
1326 rm -f
$(DESTDIR
)$(TCLLIBDIR
)/libtclsqlite3.la
$(DESTDIR
)$(TCLLIBDIR
)/libtclsqlite3.a
1327 $(INSTALL
) -m
0644 pkgIndex.tcl
$(DESTDIR
)$(TCLLIBDIR
)
1330 rm -f
*.lo
*.la
*.o sqlite3
$(TEXE
) libsqlite3.la
1331 rm -f sqlite3.h opcodes.
*
1333 rm -f lemon
$(BEXE
) lempar.c parse.
* sqlite
*.
tar.gz
1334 rm -f mkkeywordhash
$(BEXE
) keywordhash.h
1335 rm -f
*.da
*.bb
*.bbg gmon.out
1336 rm -rf tsrc .target_source
1337 rm -f tclsqlite3
$(TEXE
)
1338 rm -f testfixture
$(TEXE
) test.db
1339 rm -f LogEst
$(TEXE
) fts3view
$(TEXE
) rollback-test
$(TEXE
) showdb
$(TEXE
)
1340 rm -f showjournal
$(TEXE
) showstat4
$(TEXE
) showwal
$(TEXE
) speedtest1
$(TEXE
)
1341 rm -f wordcount
$(TEXE
) changeset
$(TEXE
)
1342 rm -f sqlite3.dll sqlite3.lib sqlite3.exp sqlite3.def
1345 rm -f
shell.c sqlite3ext.h
1346 rm -f sqlite3_analyzer
$(TEXE
) sqlite3_analyzer.c
1347 rm -f sqlite-
*-output.vsix
1348 rm -f mptester mptester.exe
1350 rm -f srcck1 srcck1.exe
1351 rm -f fuzzershell fuzzershell.exe
1352 rm -f fuzzcheck fuzzcheck.exe
1353 rm -f sqldiff sqldiff.exe
1354 rm -f dbhash dbhash.exe
1355 rm -f fts5.
* fts5parse.
*
1358 rm -f config.h config.log config.status libtool Makefile sqlite3.
pc
1365 REAL_LIBOBJ
= $(LIBOBJ
:%.lo
=.libs
/%.o
)
1367 $(REAL_LIBOBJ
): $(LIBOBJ
)
1369 sqlite3.def
: $(REAL_LIBOBJ
)
1370 echo
'EXPORTS' >sqlite3.def
1371 nm
$(REAL_LIBOBJ
) | grep
' T ' | grep
' _sqlite3_' \
1372 | sed
's/^.* _//' >>sqlite3.def
1374 sqlite3.dll
: $(REAL_LIBOBJ
) sqlite3.def
1375 $(TCC
) -shared
-o
$@ sqlite3.def \
1376 -Wl
,"--strip-all" $(REAL_LIBOBJ
)