updates to compatibilty and contribution sections in readme per issue #300
[sqlcipher.git] / Makefile.in
blob1c5e204f82a2e2692f9e6367c77ac68b080e9988
1 #!/usr/make
3 # Makefile for SQLITE
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.
18 TOP = @abs_srcdir@
21 # C Compiler and options for use in building executables that
22 # will run on the platform that is doing the build.
24 BCC = @BUILD_CC@ @BUILD_CFLAGS@
26 # TCC is the C Compile and options for use in building executables that
27 # will run on the target platform. (BCC and TCC are usually the
28 # same unless your are cross-compiling.) Separate CC and CFLAGS macros
29 # are provide so that these aspects of the build process can be changed
30 # on the "make" command-line. Ex: "make CC=clang CFLAGS=-fsanitize=undefined"
32 CC = @CC@
33 CFLAGS = @CPPFLAGS@ @CFLAGS@
34 TCC = ${CC} ${CFLAGS} -I. -I${TOP}/src -I${TOP}/ext/rtree -I${TOP}/ext/icu
35 TCC += -I${TOP}/ext/fts3 -I${TOP}/ext/async -I${TOP}/ext/session
36 TCC += -I${TOP}/ext/userauth
38 # Define this for the autoconf-based build, so that the code knows it can
39 # include the generated config.h
41 TCC += -D_HAVE_SQLITE_CONFIG_H -DBUILD_sqlite
43 # Define -DNDEBUG to compile without debugging (i.e., for production usage)
44 # Omitting the define will cause extra debugging code to be inserted and
45 # includes extra comments when "EXPLAIN stmt" is used.
47 TCC += @TARGET_DEBUG@
49 # Compiler options needed for programs that use the TCL library.
51 TCC += @TCL_INCLUDE_SPEC@
53 # The library that programs using TCL must link against.
55 LIBTCL = @TCL_LIB_SPEC@
57 # Compiler options needed for programs that use the readline() library.
59 READLINE_FLAGS = -DHAVE_READLINE=@TARGET_HAVE_READLINE@ @TARGET_READLINE_INC@
60 READLINE_FLAGS += -DHAVE_EDITLINE=@TARGET_HAVE_EDITLINE@
62 # The library that programs using readline() must link against.
64 LIBREADLINE = @TARGET_READLINE_LIBS@
66 # Should the database engine be compiled threadsafe
68 TCC += -DSQLITE_THREADSAFE=@SQLITE_THREADSAFE@
70 # Any target libraries which libsqlite must be linked against
72 TLIBS = @LIBS@ $(LIBS)
74 # Flags controlling use of the in memory btree implementation
76 # SQLITE_TEMP_STORE is 0 to force temporary tables to be in a file, 1 to
77 # default to file, 2 to default to memory, and 3 to force temporary
78 # tables to always be in memory.
80 TEMP_STORE = -DSQLITE_TEMP_STORE=@TEMP_STORE@
82 # Enable/disable loadable extensions, and other optional features
83 # based on configuration. (-DSQLITE_OMIT*, -DSQLITE_ENABLE*).
84 # The same set of OMIT and ENABLE flags should be passed to the
85 # LEMON parser generator and the mkkeywordhash tool as well.
86 OPT_FEATURE_FLAGS = @OPT_FEATURE_FLAGS@
88 TCC += $(OPT_FEATURE_FLAGS)
90 # Add in any optional parameters specified on the make commane line
91 # ie. make "OPTS=-DSQLITE_ENABLE_FOO=1 -DSQLITE_OMIT_FOO=1".
92 TCC += $(OPTS)
94 # Add in compile-time options for some libraries used by extensions
95 TCC += @HAVE_ZLIB@
97 # Version numbers and release number for the SQLite being compiled.
99 VERSION = @VERSION@
100 VERSION_NUMBER = @VERSION_NUMBER@
101 RELEASE = @RELEASE@
103 # Filename extensions
105 BEXE = @BUILD_EXEEXT@
106 TEXE = @TARGET_EXEEXT@
108 # The following variable is "1" if the configure script was able to locate
109 # the tclConfig.sh file. It is an empty string otherwise. When this
110 # variable is "1", the TCL extension library (libtclsqlite3.so) is built
111 # and installed.
113 HAVE_TCL = @HAVE_TCL@
115 # This is the command to use for tclsh - normally just "tclsh", but we may
116 # know the specific version we want to use
118 TCLSH_CMD = @TCLSH_CMD@
120 # Where do we want to install the tcl plugin
122 TCLLIBDIR = @TCLLIBDIR@
124 # The suffix used on shared libraries. Ex: ".dll", ".so", ".dylib"
126 SHLIB_SUFFIX = @TCL_SHLIB_SUFFIX@
128 # If gcov support was enabled by the configure script, add the appropriate
129 # flags here. It's not always as easy as just having the user add the right
130 # CFLAGS / LDFLAGS, because libtool wants to use CFLAGS when linking, which
131 # causes build errors with -fprofile-arcs -ftest-coverage with some GCCs.
132 # Supposedly GCC does the right thing if you use --coverage, but in
133 # practice it still fails. See:
135 # http://www.mail-archive.com/debian-gcc@lists.debian.org/msg26197.html
137 # for more info.
139 GCOV_CFLAGS1 = -DSQLITE_COVERAGE_TEST=1 -fprofile-arcs -ftest-coverage
140 GCOV_LDFLAGS1 = -lgcov
141 USE_GCOV = @USE_GCOV@
142 LTCOMPILE_EXTRAS += $(GCOV_CFLAGS$(USE_GCOV))
143 LTLINK_EXTRAS += $(GCOV_LDFLAGS$(USE_GCOV))
145 # BEGIN CRYPTO
146 CRYPTOLIBOBJ = \
147 crypto.lo \
148 crypto_impl.lo \
149 crypto_openssl.lo \
150 crypto_libtomcrypt.lo \
151 crypto_cc.lo
153 CRYPTOSRC = \
154 $(TOP)/src/crypto.h \
155 $(TOP)/src/sqlcipher.h \
156 $(TOP)/src/crypto.c \
157 $(TOP)/src/crypto_impl.c \
158 $(TOP)/src/crypto_libtomcrypt.c \
159 $(TOP)/src/crypto_openssl.c \
160 $(TOP)/src/crypto_cc.c
162 # END CRYPTO
164 # The directory into which to store package information for
166 # Some standard variables and programs
168 prefix = @prefix@
169 exec_prefix = @exec_prefix@
170 libdir = @libdir@
171 pkgconfigdir = $(libdir)/pkgconfig
172 bindir = @bindir@
173 includedir = @includedir@/sqlcipher
174 INSTALL = @INSTALL@
175 LIBTOOL = ./libtool
176 ALLOWRELEASE = @ALLOWRELEASE@
178 # libtool compile/link/install
179 LTCOMPILE = $(LIBTOOL) --mode=compile --tag=CC $(TCC) $(LTCOMPILE_EXTRAS)
180 LTLINK = $(LIBTOOL) --mode=link $(TCC) $(LTCOMPILE_EXTRAS) @LDFLAGS@ $(LTLINK_EXTRAS)
181 LTINSTALL = $(LIBTOOL) --mode=install $(INSTALL)
183 # You should not have to change anything below this line
184 ###############################################################################
186 USE_AMALGAMATION = @USE_AMALGAMATION@
188 # Object files for the SQLite library (non-amalgamation).
190 LIBOBJS0 = alter.lo analyze.lo attach.lo auth.lo \
191 backup.lo bitvec.lo btmutex.lo btree.lo build.lo \
192 callback.lo complete.lo ctime.lo \
193 date.lo dbpage.lo dbstat.lo delete.lo \
194 expr.lo fault.lo fkey.lo \
195 fts3.lo fts3_aux.lo fts3_expr.lo fts3_hash.lo fts3_icu.lo \
196 fts3_porter.lo fts3_snippet.lo fts3_tokenizer.lo fts3_tokenizer1.lo \
197 fts3_tokenize_vtab.lo \
198 fts3_unicode.lo fts3_unicode2.lo fts3_write.lo \
199 fts5.lo \
200 func.lo global.lo hash.lo \
201 icu.lo insert.lo json1.lo legacy.lo loadext.lo \
202 main.lo malloc.lo mem0.lo mem1.lo mem2.lo mem3.lo mem5.lo \
203 memdb.lo memjournal.lo \
204 mutex.lo mutex_noop.lo mutex_unix.lo mutex_w32.lo \
205 notify.lo opcodes.lo os.lo os_unix.lo os_win.lo \
206 pager.lo parse.lo pcache.lo pcache1.lo pragma.lo prepare.lo printf.lo \
207 random.lo resolve.lo rowset.lo rtree.lo \
208 sqlite3session.lo select.lo sqlite3rbu.lo status.lo stmt.lo \
209 table.lo threads.lo tokenize.lo treeview.lo trigger.lo \
210 update.lo userauth.lo upsert.lo util.lo vacuum.lo \
211 vdbe.lo vdbeapi.lo vdbeaux.lo vdbeblob.lo vdbemem.lo vdbesort.lo \
212 vdbetrace.lo wal.lo walker.lo where.lo wherecode.lo whereexpr.lo \
213 window.lo utf.lo vtab.lo $(CRYPTOLIBOBJ)
215 # Object files for the amalgamation.
217 LIBOBJS1 = sqlite3.lo
219 # Determine the real value of LIBOBJ based on the 'configure' script
221 LIBOBJ = $(LIBOBJS$(USE_AMALGAMATION))
224 # All of the source code files.
226 SRC = \
227 $(CRYPTOSRC) \
228 $(TOP)/src/alter.c \
229 $(TOP)/src/analyze.c \
230 $(TOP)/src/attach.c \
231 $(TOP)/src/auth.c \
232 $(TOP)/src/backup.c \
233 $(TOP)/src/bitvec.c \
234 $(TOP)/src/btmutex.c \
235 $(TOP)/src/btree.c \
236 $(TOP)/src/btree.h \
237 $(TOP)/src/btreeInt.h \
238 $(TOP)/src/build.c \
239 $(TOP)/src/callback.c \
240 $(TOP)/src/complete.c \
241 $(TOP)/src/ctime.c \
242 $(TOP)/src/date.c \
243 $(TOP)/src/dbpage.c \
244 $(TOP)/src/dbstat.c \
245 $(TOP)/src/delete.c \
246 $(TOP)/src/expr.c \
247 $(TOP)/src/fault.c \
248 $(TOP)/src/fkey.c \
249 $(TOP)/src/func.c \
250 $(TOP)/src/global.c \
251 $(TOP)/src/hash.c \
252 $(TOP)/src/hash.h \
253 $(TOP)/src/hwtime.h \
254 $(TOP)/src/insert.c \
255 $(TOP)/src/legacy.c \
256 $(TOP)/src/loadext.c \
257 $(TOP)/src/main.c \
258 $(TOP)/src/malloc.c \
259 $(TOP)/src/mem0.c \
260 $(TOP)/src/mem1.c \
261 $(TOP)/src/mem2.c \
262 $(TOP)/src/mem3.c \
263 $(TOP)/src/mem5.c \
264 $(TOP)/src/memdb.c \
265 $(TOP)/src/memjournal.c \
266 $(TOP)/src/msvc.h \
267 $(TOP)/src/mutex.c \
268 $(TOP)/src/mutex.h \
269 $(TOP)/src/mutex_noop.c \
270 $(TOP)/src/mutex_unix.c \
271 $(TOP)/src/mutex_w32.c \
272 $(TOP)/src/notify.c \
273 $(TOP)/src/os.c \
274 $(TOP)/src/os.h \
275 $(TOP)/src/os_common.h \
276 $(TOP)/src/os_setup.h \
277 $(TOP)/src/os_unix.c \
278 $(TOP)/src/os_win.c \
279 $(TOP)/src/os_win.h \
280 $(TOP)/src/pager.c \
281 $(TOP)/src/pager.h \
282 $(TOP)/src/parse.y \
283 $(TOP)/src/pcache.c \
284 $(TOP)/src/pcache.h \
285 $(TOP)/src/pcache1.c \
286 $(TOP)/src/pragma.c \
287 $(TOP)/src/pragma.h \
288 $(TOP)/src/prepare.c \
289 $(TOP)/src/printf.c \
290 $(TOP)/src/random.c \
291 $(TOP)/src/resolve.c \
292 $(TOP)/src/rowset.c \
293 $(TOP)/src/select.c \
294 $(TOP)/src/status.c \
295 $(TOP)/src/shell.c.in \
296 $(TOP)/src/sqlite.h.in \
297 $(TOP)/src/sqlite3ext.h \
298 $(TOP)/src/sqliteInt.h \
299 $(TOP)/src/sqliteLimit.h \
300 $(TOP)/src/table.c \
301 $(TOP)/src/tclsqlite.c \
302 $(TOP)/src/threads.c \
303 $(TOP)/src/tokenize.c \
304 $(TOP)/src/treeview.c \
305 $(TOP)/src/trigger.c \
306 $(TOP)/src/utf.c \
307 $(TOP)/src/update.c \
308 $(TOP)/src/upsert.c \
309 $(TOP)/src/util.c \
310 $(TOP)/src/vacuum.c \
311 $(TOP)/src/vdbe.c \
312 $(TOP)/src/vdbe.h \
313 $(TOP)/src/vdbeapi.c \
314 $(TOP)/src/vdbeaux.c \
315 $(TOP)/src/vdbeblob.c \
316 $(TOP)/src/vdbemem.c \
317 $(TOP)/src/vdbesort.c \
318 $(TOP)/src/vdbetrace.c \
319 $(TOP)/src/vdbeInt.h \
320 $(TOP)/src/vtab.c \
321 $(TOP)/src/vxworks.h \
322 $(TOP)/src/wal.c \
323 $(TOP)/src/wal.h \
324 $(TOP)/src/walker.c \
325 $(TOP)/src/where.c \
326 $(TOP)/src/wherecode.c \
327 $(TOP)/src/whereexpr.c \
328 $(TOP)/src/whereInt.h \
329 $(TOP)/src/window.c
331 # Source code for extensions
333 SRC += \
334 $(TOP)/ext/fts1/fts1.c \
335 $(TOP)/ext/fts1/fts1.h \
336 $(TOP)/ext/fts1/fts1_hash.c \
337 $(TOP)/ext/fts1/fts1_hash.h \
338 $(TOP)/ext/fts1/fts1_porter.c \
339 $(TOP)/ext/fts1/fts1_tokenizer.h \
340 $(TOP)/ext/fts1/fts1_tokenizer1.c
341 SRC += \
342 $(TOP)/ext/fts2/fts2.c \
343 $(TOP)/ext/fts2/fts2.h \
344 $(TOP)/ext/fts2/fts2_hash.c \
345 $(TOP)/ext/fts2/fts2_hash.h \
346 $(TOP)/ext/fts2/fts2_icu.c \
347 $(TOP)/ext/fts2/fts2_porter.c \
348 $(TOP)/ext/fts2/fts2_tokenizer.h \
349 $(TOP)/ext/fts2/fts2_tokenizer.c \
350 $(TOP)/ext/fts2/fts2_tokenizer1.c
351 SRC += \
352 $(TOP)/ext/fts3/fts3.c \
353 $(TOP)/ext/fts3/fts3.h \
354 $(TOP)/ext/fts3/fts3Int.h \
355 $(TOP)/ext/fts3/fts3_aux.c \
356 $(TOP)/ext/fts3/fts3_expr.c \
357 $(TOP)/ext/fts3/fts3_hash.c \
358 $(TOP)/ext/fts3/fts3_hash.h \
359 $(TOP)/ext/fts3/fts3_icu.c \
360 $(TOP)/ext/fts3/fts3_porter.c \
361 $(TOP)/ext/fts3/fts3_snippet.c \
362 $(TOP)/ext/fts3/fts3_tokenizer.h \
363 $(TOP)/ext/fts3/fts3_tokenizer.c \
364 $(TOP)/ext/fts3/fts3_tokenizer1.c \
365 $(TOP)/ext/fts3/fts3_tokenize_vtab.c \
366 $(TOP)/ext/fts3/fts3_unicode.c \
367 $(TOP)/ext/fts3/fts3_unicode2.c \
368 $(TOP)/ext/fts3/fts3_write.c
369 SRC += \
370 $(TOP)/ext/icu/sqliteicu.h \
371 $(TOP)/ext/icu/icu.c
372 SRC += \
373 $(TOP)/ext/rtree/rtree.h \
374 $(TOP)/ext/rtree/rtree.c \
375 $(TOP)/ext/rtree/geopoly.c
376 SRC += \
377 $(TOP)/ext/session/sqlite3session.c \
378 $(TOP)/ext/session/sqlite3session.h
379 SRC += \
380 $(TOP)/ext/userauth/userauth.c \
381 $(TOP)/ext/userauth/sqlite3userauth.h
382 SRC += \
383 $(TOP)/ext/rbu/sqlite3rbu.h \
384 $(TOP)/ext/rbu/sqlite3rbu.c
385 SRC += \
386 $(TOP)/ext/misc/json1.c \
387 $(TOP)/ext/misc/stmt.c
389 # Generated source code files
391 SRC += \
392 keywordhash.h \
393 opcodes.c \
394 opcodes.h \
395 parse.c \
396 parse.h \
397 config.h \
398 shell.c \
399 sqlite3.h
401 # Source code to the test files.
403 TESTSRC = \
404 $(TOP)/src/test1.c \
405 $(TOP)/src/test2.c \
406 $(TOP)/src/test3.c \
407 $(TOP)/src/test4.c \
408 $(TOP)/src/test5.c \
409 $(TOP)/src/test6.c \
410 $(TOP)/src/test7.c \
411 $(TOP)/src/test8.c \
412 $(TOP)/src/test9.c \
413 $(TOP)/src/test_autoext.c \
414 $(TOP)/src/test_async.c \
415 $(TOP)/src/test_backup.c \
416 $(TOP)/src/test_bestindex.c \
417 $(TOP)/src/test_blob.c \
418 $(TOP)/src/test_btree.c \
419 $(TOP)/src/test_config.c \
420 $(TOP)/src/test_delete.c \
421 $(TOP)/src/test_demovfs.c \
422 $(TOP)/src/test_devsym.c \
423 $(TOP)/src/test_fs.c \
424 $(TOP)/src/test_func.c \
425 $(TOP)/src/test_hexio.c \
426 $(TOP)/src/test_init.c \
427 $(TOP)/src/test_intarray.c \
428 $(TOP)/src/test_journal.c \
429 $(TOP)/src/test_malloc.c \
430 $(TOP)/src/test_md5.c \
431 $(TOP)/src/test_multiplex.c \
432 $(TOP)/src/test_mutex.c \
433 $(TOP)/src/test_onefile.c \
434 $(TOP)/src/test_osinst.c \
435 $(TOP)/src/test_pcache.c \
436 $(TOP)/src/test_quota.c \
437 $(TOP)/src/test_rtree.c \
438 $(TOP)/src/test_schema.c \
439 $(TOP)/src/test_server.c \
440 $(TOP)/src/test_superlock.c \
441 $(TOP)/src/test_syscall.c \
442 $(TOP)/src/test_tclsh.c \
443 $(TOP)/src/test_tclvar.c \
444 $(TOP)/src/test_thread.c \
445 $(TOP)/src/test_vfs.c \
446 $(TOP)/src/test_windirent.c \
447 $(TOP)/src/test_window.c \
448 $(TOP)/src/test_wsd.c \
449 $(TOP)/ext/fts3/fts3_term.c \
450 $(TOP)/ext/fts3/fts3_test.c \
451 $(TOP)/ext/session/test_session.c \
452 $(TOP)/ext/rbu/test_rbu.c
454 # Statically linked extensions
456 TESTSRC += \
457 $(TOP)/ext/expert/sqlite3expert.c \
458 $(TOP)/ext/expert/test_expert.c \
459 $(TOP)/ext/misc/amatch.c \
460 $(TOP)/ext/misc/carray.c \
461 $(TOP)/ext/misc/closure.c \
462 $(TOP)/ext/misc/csv.c \
463 $(TOP)/ext/misc/eval.c \
464 $(TOP)/ext/misc/explain.c \
465 $(TOP)/ext/misc/fileio.c \
466 $(TOP)/ext/misc/fuzzer.c \
467 $(TOP)/ext/fts5/fts5_tcl.c \
468 $(TOP)/ext/fts5/fts5_test_mi.c \
469 $(TOP)/ext/fts5/fts5_test_tok.c \
470 $(TOP)/ext/misc/ieee754.c \
471 $(TOP)/ext/misc/mmapwarm.c \
472 $(TOP)/ext/misc/nextchar.c \
473 $(TOP)/ext/misc/normalize.c \
474 $(TOP)/ext/misc/percentile.c \
475 $(TOP)/ext/misc/regexp.c \
476 $(TOP)/ext/misc/remember.c \
477 $(TOP)/ext/misc/series.c \
478 $(TOP)/ext/misc/spellfix.c \
479 $(TOP)/ext/misc/totype.c \
480 $(TOP)/ext/misc/unionvtab.c \
481 $(TOP)/ext/misc/wholenumber.c \
482 $(TOP)/ext/misc/zipfile.c \
483 $(TOP)/ext/userauth/userauth.c
485 # Source code to the library files needed by the test fixture
487 TESTSRC2 = \
488 $(TOP)/src/attach.c \
489 $(TOP)/src/backup.c \
490 $(TOP)/src/bitvec.c \
491 $(TOP)/src/btree.c \
492 $(TOP)/src/build.c \
493 $(TOP)/src/ctime.c \
494 $(TOP)/src/date.c \
495 $(TOP)/src/dbpage.c \
496 $(TOP)/src/dbstat.c \
497 $(TOP)/src/expr.c \
498 $(TOP)/src/func.c \
499 $(TOP)/src/global.c \
500 $(TOP)/src/insert.c \
501 $(TOP)/src/wal.c \
502 $(TOP)/src/main.c \
503 $(TOP)/src/mem5.c \
504 $(TOP)/src/os.c \
505 $(TOP)/src/os_unix.c \
506 $(TOP)/src/os_win.c \
507 $(TOP)/src/pager.c \
508 $(TOP)/src/pragma.c \
509 $(TOP)/src/prepare.c \
510 $(TOP)/src/printf.c \
511 $(TOP)/src/random.c \
512 $(TOP)/src/pcache.c \
513 $(TOP)/src/pcache1.c \
514 $(TOP)/src/select.c \
515 $(TOP)/src/tokenize.c \
516 $(TOP)/src/utf.c \
517 $(TOP)/src/util.c \
518 $(TOP)/src/vdbeapi.c \
519 $(TOP)/src/vdbeaux.c \
520 $(TOP)/src/vdbe.c \
521 $(TOP)/src/vdbemem.c \
522 $(TOP)/src/vdbetrace.c \
523 $(TOP)/src/where.c \
524 $(TOP)/src/wherecode.c \
525 $(TOP)/src/whereexpr.c \
526 $(TOP)/src/window.c \
527 parse.c \
528 $(TOP)/ext/fts3/fts3.c \
529 $(TOP)/ext/fts3/fts3_aux.c \
530 $(TOP)/ext/fts3/fts3_expr.c \
531 $(TOP)/ext/fts3/fts3_term.c \
532 $(TOP)/ext/fts3/fts3_tokenizer.c \
533 $(TOP)/ext/fts3/fts3_write.c \
534 $(TOP)/ext/async/sqlite3async.c \
535 $(TOP)/ext/session/sqlite3session.c \
536 $(TOP)/ext/misc/stmt.c
538 # Header files used by all library source files.
540 HDR = \
541 $(TOP)/src/btree.h \
542 $(TOP)/src/btreeInt.h \
543 $(TOP)/src/hash.h \
544 $(TOP)/src/hwtime.h \
545 keywordhash.h \
546 $(TOP)/src/msvc.h \
547 $(TOP)/src/mutex.h \
548 opcodes.h \
549 $(TOP)/src/os.h \
550 $(TOP)/src/os_common.h \
551 $(TOP)/src/os_setup.h \
552 $(TOP)/src/os_win.h \
553 $(TOP)/src/pager.h \
554 $(TOP)/src/pcache.h \
555 parse.h \
556 $(TOP)/src/pragma.h \
557 sqlite3.h \
558 $(TOP)/src/sqlite3ext.h \
559 $(TOP)/src/sqliteInt.h \
560 $(TOP)/src/sqliteLimit.h \
561 $(TOP)/src/vdbe.h \
562 $(TOP)/src/vdbeInt.h \
563 $(TOP)/src/vxworks.h \
564 $(TOP)/src/whereInt.h \
565 config.h
567 # Header files used by extensions
569 EXTHDR += \
570 $(TOP)/ext/fts1/fts1.h \
571 $(TOP)/ext/fts1/fts1_hash.h \
572 $(TOP)/ext/fts1/fts1_tokenizer.h
573 EXTHDR += \
574 $(TOP)/ext/fts2/fts2.h \
575 $(TOP)/ext/fts2/fts2_hash.h \
576 $(TOP)/ext/fts2/fts2_tokenizer.h
577 EXTHDR += \
578 $(TOP)/ext/fts3/fts3.h \
579 $(TOP)/ext/fts3/fts3Int.h \
580 $(TOP)/ext/fts3/fts3_hash.h \
581 $(TOP)/ext/fts3/fts3_tokenizer.h
582 EXTHDR += \
583 $(TOP)/ext/rtree/rtree.h \
584 $(TOP)/ext/rtree/geopoly.c
585 EXTHDR += \
586 $(TOP)/ext/icu/sqliteicu.h
587 EXTHDR += \
588 $(TOP)/ext/rtree/sqlite3rtree.h
589 EXTHDR += \
590 $(TOP)/ext/userauth/sqlite3userauth.h
592 # executables needed for testing
594 TESTPROGS = \
595 testfixture$(TEXE) \
596 sqlite3$(TEXE) \
597 sqlite3_analyzer$(TEXE) \
598 sqldiff$(TEXE) \
599 dbhash$(TEXE) \
600 sqltclsh$(TEXE)
602 # Databases containing fuzzer test cases
604 FUZZDATA = \
605 $(TOP)/test/fuzzdata1.db \
606 $(TOP)/test/fuzzdata2.db \
607 $(TOP)/test/fuzzdata3.db \
608 $(TOP)/test/fuzzdata4.db \
609 $(TOP)/test/fuzzdata5.db \
610 $(TOP)/test/fuzzdata6.db \
611 $(TOP)/test/fuzzdata7.db
613 # Standard options to testfixture
615 TESTOPTS = --verbose=file --output=test-out.txt
617 # Extra compiler options for various shell tools
619 SHELL_OPT = -DSQLITE_ENABLE_JSON1 -DSQLITE_ENABLE_FTS4
620 #SHELL_OPT += -DSQLITE_ENABLE_FTS5
621 SHELL_OPT += -DSQLITE_ENABLE_RTREE
622 SHELL_OPT += -DSQLITE_ENABLE_EXPLAIN_COMMENTS
623 SHELL_OPT += -DSQLITE_ENABLE_UNKNOWN_SQL_FUNCTION
624 SHELL_OPT += -DSQLITE_ENABLE_STMTVTAB
625 SHELL_OPT += -DSQLITE_ENABLE_DBPAGE_VTAB
626 SHELL_OPT += -DSQLITE_ENABLE_DBSTAT_VTAB
627 SHELL_OPT += -DSQLITE_ENABLE_OFFSET_SQL_FUNC
628 SHELL_OPT += -DSQLITE_ENABLE_DESERIALIZE
629 SHELL_OPT += -DSQLITE_INTROSPECTION_PRAGMAS
630 FUZZERSHELL_OPT = -DSQLITE_ENABLE_JSON1
631 FUZZCHECK_OPT = -DSQLITE_ENABLE_JSON1 -DSQLITE_ENABLE_MEMSYS5 -DSQLITE_OSS_FUZZ
632 FUZZCHECK_OPT += -DSQLITE_MAX_MEMORY=50000000
633 FUZZCHECK_OPT += -DSQLITE_PRINTF_PRECISION_LIMIT=1000
634 FUZZCHECK_SRC = $(TOP)/test/fuzzcheck.c $(TOP)/test/ossfuzz.c
635 DBFUZZ_OPT =
637 # This is the default Makefile target. The objects listed here
638 # are what get build when you type just "make" with no arguments.
640 all: sqlite3.h libsqlcipher.la sqlcipher$(TEXE) $(HAVE_TCL:1=libtclsqlite3.la)
642 Makefile: $(TOP)/Makefile.in
643 ./config.status
645 sqlcipher.pc: $(TOP)/sqlcipher.pc.in
646 ./config.status
648 libsqlcipher.la: $(LIBOBJ)
649 $(LTLINK) -no-undefined -o $@ $(LIBOBJ) $(TLIBS) \
650 ${ALLOWRELEASE} -rpath "$(libdir)" -version-info "8:6:8"
652 libtclsqlite3.la: tclsqlite.lo libsqlcipher.la
653 $(LTLINK) -no-undefined -o $@ tclsqlite.lo \
654 libsqlcipher.la @TCL_STUB_LIB_SPEC@ $(TLIBS) \
655 -rpath "$(TCLLIBDIR)" \
656 -version-info "8:6:8" \
657 -avoid-version
659 sqlcipher$(TEXE): shell.c sqlite3.c
660 $(LTLINK) $(READLINE_FLAGS) $(SHELL_OPT) -o $@ \
661 shell.c sqlite3.c \
662 $(LIBREADLINE) $(TLIBS) -rpath "$(libdir)"
664 sqldiff$(TEXE): $(TOP)/tool/sqldiff.c sqlite3.lo sqlite3.h
665 $(LTLINK) -o $@ $(TOP)/tool/sqldiff.c sqlite3.lo $(TLIBS)
667 dbhash$(TEXE): $(TOP)/tool/dbhash.c sqlite3.lo sqlite3.h
668 $(LTLINK) -o $@ $(TOP)/tool/dbhash.c sqlite3.lo $(TLIBS)
670 scrub$(TEXE): $(TOP)/ext/misc/scrub.c sqlite3.lo
671 $(LTLINK) -o $@ -I. -DSCRUB_STANDALONE \
672 $(TOP)/ext/misc/scrub.c sqlite3.lo $(TLIBS)
674 srcck1$(BEXE): $(TOP)/tool/srcck1.c
675 $(BCC) -o srcck1$(BEXE) $(TOP)/tool/srcck1.c
677 sourcetest: srcck1$(BEXE) sqlite3.c
678 ./srcck1 sqlite3.c
680 fuzzershell$(TEXE): $(TOP)/tool/fuzzershell.c sqlite3.c sqlite3.h
681 $(LTLINK) -o $@ $(FUZZERSHELL_OPT) \
682 $(TOP)/tool/fuzzershell.c sqlite3.c $(TLIBS)
684 fuzzcheck$(TEXE): $(FUZZCHECK_SRC) sqlite3.c sqlite3.h
685 $(LTLINK) -o $@ $(FUZZCHECK_OPT) $(FUZZCHECK_SRC) sqlite3.c $(TLIBS)
687 ossshell$(TEXE): $(TOP)/test/ossfuzz.c $(TOP)/test/ossshell.c sqlite3.c sqlite3.h
688 $(LTLINK) -o $@ $(FUZZCHECK_OPT) $(TOP)/test/ossshell.c \
689 $(TOP)/test/ossfuzz.c sqlite3.c $(TLIBS)
691 sessionfuzz$(TEXE): $(TOP)/test/sessionfuzz.c sqlite3.c sqlite3.h
692 $(CC) $(CFLAGS) -I. -o $@ $(TOP)/test/sessionfuzz.c $(TLIBS)
694 dbfuzz$(TEXE): $(TOP)/test/dbfuzz.c sqlite3.c sqlite3.h
695 $(LTLINK) -o $@ $(DBFUZZ_OPT) $(TOP)/test/dbfuzz.c sqlite3.c $(TLIBS)
697 DBFUZZ2_OPTS = \
698 -DSQLITE_THREADSAFE=0 \
699 -DSQLITE_OMIT_LOAD_EXTENSION \
700 -DSQLITE_ENABLE_DESERIALIZE \
701 -DSQLITE_DEBUG \
702 -DSQLITE_ENABLE_DBSTAT_VTAB \
703 -DSQLITE_ENABLE_RTREE \
704 -DSQLITE_ENABLE_FTS4 \
705 -DSQLITE_EANBLE_FTS5
707 dbfuzz2: $(TOP)/test/dbfuzz2.c sqlite3.c sqlite3.h
708 clang-6.0 -I. -g -O0 -fsanitize=fuzzer,undefined,address -o dbfuzz2 \
709 $(DBFUZZ2_OPTS) $(TOP)/test/dbfuzz2.c sqlite3.c
710 mkdir -p dbfuzz2-dir
711 cp $(TOP)/test/dbfuzz2-seed* dbfuzz2-dir
713 mptester$(TEXE): sqlite3.lo $(TOP)/mptest/mptest.c
714 $(LTLINK) -o $@ -I. $(TOP)/mptest/mptest.c sqlite3.lo \
715 $(TLIBS) -rpath "$(libdir)"
717 MPTEST1=./mptester$(TEXE) mptest.db $(TOP)/mptest/crash01.test --repeat 20
718 MPTEST2=./mptester$(TEXE) mptest.db $(TOP)/mptest/multiwrite01.test --repeat 20
719 mptest: mptester$(TEXE)
720 rm -f mptest.db
721 $(MPTEST1) --journalmode DELETE
722 $(MPTEST2) --journalmode WAL
723 $(MPTEST1) --journalmode WAL
724 $(MPTEST2) --journalmode PERSIST
725 $(MPTEST1) --journalmode PERSIST
726 $(MPTEST2) --journalmode TRUNCATE
727 $(MPTEST1) --journalmode TRUNCATE
728 $(MPTEST2) --journalmode DELETE
731 # This target creates a directory named "tsrc" and fills it with
732 # copies of all of the C source code and header files needed to
733 # build on the target system. Some of the C source code and header
734 # files are automatically generated. This target takes care of
735 # all that automatic generation.
737 .target_source: $(SRC) $(TOP)/tool/vdbe-compress.tcl fts5.c
738 rm -rf tsrc
739 mkdir tsrc
740 cp -f $(SRC) tsrc
741 rm tsrc/sqlite.h.in tsrc/parse.y
742 $(TCLSH_CMD) $(TOP)/tool/vdbe-compress.tcl $(OPTS) <tsrc/vdbe.c >vdbe.new
743 mv vdbe.new tsrc/vdbe.c
744 cp fts5.c fts5.h tsrc
745 touch .target_source
747 sqlite3.c: .target_source $(TOP)/tool/mksqlite3c.tcl
748 $(TCLSH_CMD) $(TOP)/tool/mksqlite3c.tcl
749 cp tsrc/sqlite3ext.h .
750 cp $(TOP)/ext/session/sqlite3session.h .
752 sqlite3ext.h: .target_source
753 cp tsrc/sqlite3ext.h .
755 tclsqlite3.c: sqlite3.c
756 echo '#ifndef USE_SYSTEM_SQLITE' >tclsqlite3.c
757 cat sqlite3.c >>tclsqlite3.c
758 echo '#endif /* USE_SYSTEM_SQLITE */' >>tclsqlite3.c
759 cat $(TOP)/src/tclsqlite.c >>tclsqlite3.c
761 sqlite3-all.c: sqlite3.c $(TOP)/tool/split-sqlite3c.tcl
762 $(TCLSH_CMD) $(TOP)/tool/split-sqlite3c.tcl
764 # Rule to build the amalgamation
766 sqlite3.lo: sqlite3.c
767 $(LTCOMPILE) $(TEMP_STORE) -c sqlite3.c
769 # Rules to build the LEMON compiler generator
771 lemon$(BEXE): $(TOP)/tool/lemon.c $(TOP)/tool/lempar.c
772 $(BCC) -o $@ $(TOP)/tool/lemon.c
773 cp $(TOP)/tool/lempar.c .
775 # Rules to build the program that generates the source-id
777 mksourceid$(BEXE): $(TOP)/tool/mksourceid.c
778 $(BCC) -o $@ $(TOP)/tool/mksourceid.c
780 # Rules to build individual *.o files from generated *.c files. This
781 # applies to:
783 # parse.o
784 # opcodes.o
786 parse.lo: parse.c $(HDR)
787 $(LTCOMPILE) $(TEMP_STORE) -c parse.c
789 opcodes.lo: opcodes.c
790 $(LTCOMPILE) $(TEMP_STORE) -c opcodes.c
792 # BEGIN CRYPTO
793 crypto.lo: $(TOP)/src/crypto.c $(HDR)
794 $(LTCOMPILE) -c $(TOP)/src/crypto.c
795 crypto_impl.lo: $(TOP)/src/crypto_impl.c $(HDR)
796 $(LTCOMPILE) -c $(TOP)/src/crypto_impl.c
797 crypto_openssl.lo: $(TOP)/src/crypto_openssl.c $(HDR)
798 $(LTCOMPILE) -c $(TOP)/src/crypto_openssl.c
799 crypto_libtomcrypt.lo: $(TOP)/src/crypto_libtomcrypt.c $(HDR)
800 $(LTCOMPILE) -c $(TOP)/src/crypto_libtomcrypt.c
801 crypto_cc.lo: $(TOP)/src/crypto_cc.c $(HDR)
802 $(LTCOMPILE) -c $(TOP)/src/crypto_cc.c
803 # END CRYPTO
805 # Rules to build individual *.o files from files in the src directory.
807 alter.lo: $(TOP)/src/alter.c $(HDR)
808 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/alter.c
810 analyze.lo: $(TOP)/src/analyze.c $(HDR)
811 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/analyze.c
813 attach.lo: $(TOP)/src/attach.c $(HDR)
814 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/attach.c
816 auth.lo: $(TOP)/src/auth.c $(HDR)
817 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/auth.c
819 backup.lo: $(TOP)/src/backup.c $(HDR)
820 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/backup.c
822 bitvec.lo: $(TOP)/src/bitvec.c $(HDR)
823 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/bitvec.c
825 btmutex.lo: $(TOP)/src/btmutex.c $(HDR)
826 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/btmutex.c
828 btree.lo: $(TOP)/src/btree.c $(HDR) $(TOP)/src/pager.h
829 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/btree.c
831 build.lo: $(TOP)/src/build.c $(HDR)
832 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/build.c
834 callback.lo: $(TOP)/src/callback.c $(HDR)
835 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/callback.c
837 complete.lo: $(TOP)/src/complete.c $(HDR)
838 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/complete.c
840 ctime.lo: $(TOP)/src/ctime.c $(HDR)
841 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/ctime.c
843 date.lo: $(TOP)/src/date.c $(HDR)
844 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/date.c
846 dbpage.lo: $(TOP)/src/dbpage.c $(HDR)
847 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/dbpage.c
849 dbstat.lo: $(TOP)/src/dbstat.c $(HDR)
850 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/dbstat.c
852 delete.lo: $(TOP)/src/delete.c $(HDR)
853 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/delete.c
855 expr.lo: $(TOP)/src/expr.c $(HDR)
856 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/expr.c
858 fault.lo: $(TOP)/src/fault.c $(HDR)
859 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/fault.c
861 fkey.lo: $(TOP)/src/fkey.c $(HDR)
862 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/fkey.c
864 func.lo: $(TOP)/src/func.c $(HDR)
865 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/func.c
867 global.lo: $(TOP)/src/global.c $(HDR)
868 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/global.c
870 hash.lo: $(TOP)/src/hash.c $(HDR)
871 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/hash.c
873 insert.lo: $(TOP)/src/insert.c $(HDR)
874 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/insert.c
876 legacy.lo: $(TOP)/src/legacy.c $(HDR)
877 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/legacy.c
879 loadext.lo: $(TOP)/src/loadext.c $(HDR)
880 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/loadext.c
882 main.lo: $(TOP)/src/main.c $(HDR)
883 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/main.c
885 malloc.lo: $(TOP)/src/malloc.c $(HDR)
886 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/malloc.c
888 mem0.lo: $(TOP)/src/mem0.c $(HDR)
889 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/mem0.c
891 mem1.lo: $(TOP)/src/mem1.c $(HDR)
892 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/mem1.c
894 mem2.lo: $(TOP)/src/mem2.c $(HDR)
895 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/mem2.c
897 mem3.lo: $(TOP)/src/mem3.c $(HDR)
898 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/mem3.c
900 mem5.lo: $(TOP)/src/mem5.c $(HDR)
901 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/mem5.c
903 memdb.lo: $(TOP)/src/memdb.c $(HDR)
904 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/memdb.c
906 memjournal.lo: $(TOP)/src/memjournal.c $(HDR)
907 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/memjournal.c
909 mutex.lo: $(TOP)/src/mutex.c $(HDR)
910 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/mutex.c
912 mutex_noop.lo: $(TOP)/src/mutex_noop.c $(HDR)
913 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/mutex_noop.c
915 mutex_unix.lo: $(TOP)/src/mutex_unix.c $(HDR)
916 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/mutex_unix.c
918 mutex_w32.lo: $(TOP)/src/mutex_w32.c $(HDR)
919 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/mutex_w32.c
921 notify.lo: $(TOP)/src/notify.c $(HDR)
922 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/notify.c
924 pager.lo: $(TOP)/src/pager.c $(HDR) $(TOP)/src/pager.h
925 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/pager.c
927 pcache.lo: $(TOP)/src/pcache.c $(HDR) $(TOP)/src/pcache.h
928 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/pcache.c
930 pcache1.lo: $(TOP)/src/pcache1.c $(HDR) $(TOP)/src/pcache.h
931 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/pcache1.c
933 os.lo: $(TOP)/src/os.c $(HDR)
934 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/os.c
936 os_unix.lo: $(TOP)/src/os_unix.c $(HDR)
937 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/os_unix.c
939 os_win.lo: $(TOP)/src/os_win.c $(HDR)
940 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/os_win.c
942 pragma.lo: $(TOP)/src/pragma.c $(HDR)
943 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/pragma.c
945 prepare.lo: $(TOP)/src/prepare.c $(HDR)
946 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/prepare.c
948 printf.lo: $(TOP)/src/printf.c $(HDR)
949 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/printf.c
951 random.lo: $(TOP)/src/random.c $(HDR)
952 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/random.c
954 resolve.lo: $(TOP)/src/resolve.c $(HDR)
955 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/resolve.c
957 rowset.lo: $(TOP)/src/rowset.c $(HDR)
958 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/rowset.c
960 select.lo: $(TOP)/src/select.c $(HDR)
961 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/select.c
963 status.lo: $(TOP)/src/status.c $(HDR)
964 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/status.c
966 table.lo: $(TOP)/src/table.c $(HDR)
967 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/table.c
969 threads.lo: $(TOP)/src/threads.c $(HDR)
970 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/threads.c
972 tokenize.lo: $(TOP)/src/tokenize.c keywordhash.h $(HDR)
973 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/tokenize.c
975 treeview.lo: $(TOP)/src/treeview.c $(HDR)
976 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/treeview.c
978 trigger.lo: $(TOP)/src/trigger.c $(HDR)
979 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/trigger.c
981 update.lo: $(TOP)/src/update.c $(HDR)
982 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/update.c
984 upsert.lo: $(TOP)/src/upsert.c $(HDR)
985 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/upsert.c
987 utf.lo: $(TOP)/src/utf.c $(HDR)
988 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/utf.c
990 util.lo: $(TOP)/src/util.c $(HDR)
991 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/util.c
993 vacuum.lo: $(TOP)/src/vacuum.c $(HDR)
994 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/vacuum.c
996 vdbe.lo: $(TOP)/src/vdbe.c $(HDR)
997 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/vdbe.c
999 vdbeapi.lo: $(TOP)/src/vdbeapi.c $(HDR)
1000 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/vdbeapi.c
1002 vdbeaux.lo: $(TOP)/src/vdbeaux.c $(HDR)
1003 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/vdbeaux.c
1005 vdbeblob.lo: $(TOP)/src/vdbeblob.c $(HDR)
1006 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/vdbeblob.c
1008 vdbemem.lo: $(TOP)/src/vdbemem.c $(HDR)
1009 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/vdbemem.c
1011 vdbesort.lo: $(TOP)/src/vdbesort.c $(HDR)
1012 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/vdbesort.c
1014 vdbetrace.lo: $(TOP)/src/vdbetrace.c $(HDR)
1015 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/vdbetrace.c
1017 vtab.lo: $(TOP)/src/vtab.c $(HDR)
1018 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/vtab.c
1020 wal.lo: $(TOP)/src/wal.c $(HDR)
1021 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/wal.c
1023 walker.lo: $(TOP)/src/walker.c $(HDR)
1024 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/walker.c
1026 where.lo: $(TOP)/src/where.c $(HDR)
1027 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/where.c
1029 wherecode.lo: $(TOP)/src/wherecode.c $(HDR)
1030 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/wherecode.c
1032 whereexpr.lo: $(TOP)/src/whereexpr.c $(HDR)
1033 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/whereexpr.c
1035 window.lo: $(TOP)/src/window.c $(HDR)
1036 $(LTCOMPILE) $(TEMP_STORE) -c $(TOP)/src/window.c
1038 tclsqlite.lo: $(TOP)/src/tclsqlite.c $(HDR)
1039 $(LTCOMPILE) -DUSE_TCL_STUBS=1 -c $(TOP)/src/tclsqlite.c
1041 tclsqlite-shell.lo: $(TOP)/src/tclsqlite.c $(HDR)
1042 $(LTCOMPILE) -DTCLSH -o $@ -c $(TOP)/src/tclsqlite.c
1044 tclsqlite-stubs.lo: $(TOP)/src/tclsqlite.c $(HDR)
1045 $(LTCOMPILE) -DUSE_TCL_STUBS=1 -o $@ -c $(TOP)/src/tclsqlite.c
1047 tclsqlcipher$(TEXE): tclsqlite-shell.lo libsqlcipher.la
1048 $(LTLINK) -o $@ tclsqlite-shell.lo \
1049 libsqlcipher.la $(LIBTCL)
1051 # Rules to build opcodes.c and opcodes.h
1053 opcodes.c: opcodes.h $(TOP)/tool/mkopcodec.tcl
1054 $(TCLSH_CMD) $(TOP)/tool/mkopcodec.tcl opcodes.h >opcodes.c
1056 opcodes.h: parse.h $(TOP)/src/vdbe.c $(TOP)/tool/mkopcodeh.tcl
1057 cat parse.h $(TOP)/src/vdbe.c | $(TCLSH_CMD) $(TOP)/tool/mkopcodeh.tcl >opcodes.h
1059 # Rules to build parse.c and parse.h - the outputs of lemon.
1061 parse.h: parse.c
1063 parse.c: $(TOP)/src/parse.y lemon$(BEXE) $(TOP)/tool/addopcodes.tcl
1064 cp $(TOP)/src/parse.y .
1065 rm -f parse.h
1066 ./lemon$(BEXE) $(OPT_FEATURE_FLAGS) $(OPTS) parse.y
1067 mv parse.h parse.h.temp
1068 $(TCLSH_CMD) $(TOP)/tool/addopcodes.tcl parse.h.temp >parse.h
1070 sqlite3.h: $(TOP)/src/sqlite.h.in $(TOP)/manifest mksourceid$(BEXE) $(TOP)/VERSION
1071 $(TCLSH_CMD) $(TOP)/tool/mksqlite3h.tcl $(TOP) >sqlite3.h
1073 keywordhash.h: $(TOP)/tool/mkkeywordhash.c
1074 $(BCC) -o mkkeywordhash$(BEXE) $(OPT_FEATURE_FLAGS) $(OPTS) $(TOP)/tool/mkkeywordhash.c
1075 ./mkkeywordhash$(BEXE) >keywordhash.h
1077 # Source files that go into making shell.c
1078 SHELL_SRC = \
1079 $(TOP)/src/shell.c.in \
1080 $(TOP)/ext/misc/appendvfs.c \
1081 $(TOP)/ext/misc/shathree.c \
1082 $(TOP)/ext/misc/fileio.c \
1083 $(TOP)/ext/misc/completion.c \
1084 $(TOP)/ext/misc/sqlar.c \
1085 $(TOP)/ext/expert/sqlite3expert.c \
1086 $(TOP)/ext/expert/sqlite3expert.h \
1087 $(TOP)/ext/misc/zipfile.c \
1088 $(TOP)/src/test_windirent.c
1090 shell.c: $(SHELL_SRC) $(TOP)/tool/mkshellc.tcl
1091 $(TCLSH_CMD) $(TOP)/tool/mkshellc.tcl >shell.c
1096 # Rules to build the extension objects.
1098 icu.lo: $(TOP)/ext/icu/icu.c $(HDR) $(EXTHDR)
1099 $(LTCOMPILE) -DSQLITE_CORE -c $(TOP)/ext/icu/icu.c
1101 fts2.lo: $(TOP)/ext/fts2/fts2.c $(HDR) $(EXTHDR)
1102 $(LTCOMPILE) -DSQLITE_CORE -c $(TOP)/ext/fts2/fts2.c
1104 fts2_hash.lo: $(TOP)/ext/fts2/fts2_hash.c $(HDR) $(EXTHDR)
1105 $(LTCOMPILE) -DSQLITE_CORE -c $(TOP)/ext/fts2/fts2_hash.c
1107 fts2_icu.lo: $(TOP)/ext/fts2/fts2_icu.c $(HDR) $(EXTHDR)
1108 $(LTCOMPILE) -DSQLITE_CORE -c $(TOP)/ext/fts2/fts2_icu.c
1110 fts2_porter.lo: $(TOP)/ext/fts2/fts2_porter.c $(HDR) $(EXTHDR)
1111 $(LTCOMPILE) -DSQLITE_CORE -c $(TOP)/ext/fts2/fts2_porter.c
1113 fts2_tokenizer.lo: $(TOP)/ext/fts2/fts2_tokenizer.c $(HDR) $(EXTHDR)
1114 $(LTCOMPILE) -DSQLITE_CORE -c $(TOP)/ext/fts2/fts2_tokenizer.c
1116 fts2_tokenizer1.lo: $(TOP)/ext/fts2/fts2_tokenizer1.c $(HDR) $(EXTHDR)
1117 $(LTCOMPILE) -DSQLITE_CORE -c $(TOP)/ext/fts2/fts2_tokenizer1.c
1119 fts3.lo: $(TOP)/ext/fts3/fts3.c $(HDR) $(EXTHDR)
1120 $(LTCOMPILE) -DSQLITE_CORE -c $(TOP)/ext/fts3/fts3.c
1122 fts3_aux.lo: $(TOP)/ext/fts3/fts3_aux.c $(HDR) $(EXTHDR)
1123 $(LTCOMPILE) -DSQLITE_CORE -c $(TOP)/ext/fts3/fts3_aux.c
1125 fts3_expr.lo: $(TOP)/ext/fts3/fts3_expr.c $(HDR) $(EXTHDR)
1126 $(LTCOMPILE) -DSQLITE_CORE -c $(TOP)/ext/fts3/fts3_expr.c
1128 fts3_hash.lo: $(TOP)/ext/fts3/fts3_hash.c $(HDR) $(EXTHDR)
1129 $(LTCOMPILE) -DSQLITE_CORE -c $(TOP)/ext/fts3/fts3_hash.c
1131 fts3_icu.lo: $(TOP)/ext/fts3/fts3_icu.c $(HDR) $(EXTHDR)
1132 $(LTCOMPILE) -DSQLITE_CORE -c $(TOP)/ext/fts3/fts3_icu.c
1134 fts3_porter.lo: $(TOP)/ext/fts3/fts3_porter.c $(HDR) $(EXTHDR)
1135 $(LTCOMPILE) -DSQLITE_CORE -c $(TOP)/ext/fts3/fts3_porter.c
1137 fts3_snippet.lo: $(TOP)/ext/fts3/fts3_snippet.c $(HDR) $(EXTHDR)
1138 $(LTCOMPILE) -DSQLITE_CORE -c $(TOP)/ext/fts3/fts3_snippet.c
1140 fts3_tokenizer.lo: $(TOP)/ext/fts3/fts3_tokenizer.c $(HDR) $(EXTHDR)
1141 $(LTCOMPILE) -DSQLITE_CORE -c $(TOP)/ext/fts3/fts3_tokenizer.c
1143 fts3_tokenizer1.lo: $(TOP)/ext/fts3/fts3_tokenizer1.c $(HDR) $(EXTHDR)
1144 $(LTCOMPILE) -DSQLITE_CORE -c $(TOP)/ext/fts3/fts3_tokenizer1.c
1146 fts3_tokenize_vtab.lo: $(TOP)/ext/fts3/fts3_tokenize_vtab.c $(HDR) $(EXTHDR)
1147 $(LTCOMPILE) -DSQLITE_CORE -c $(TOP)/ext/fts3/fts3_tokenize_vtab.c
1149 fts3_unicode.lo: $(TOP)/ext/fts3/fts3_unicode.c $(HDR) $(EXTHDR)
1150 $(LTCOMPILE) -DSQLITE_CORE -c $(TOP)/ext/fts3/fts3_unicode.c
1152 fts3_unicode2.lo: $(TOP)/ext/fts3/fts3_unicode2.c $(HDR) $(EXTHDR)
1153 $(LTCOMPILE) -DSQLITE_CORE -c $(TOP)/ext/fts3/fts3_unicode2.c
1155 fts3_write.lo: $(TOP)/ext/fts3/fts3_write.c $(HDR) $(EXTHDR)
1156 $(LTCOMPILE) -DSQLITE_CORE -c $(TOP)/ext/fts3/fts3_write.c
1158 rtree.lo: $(TOP)/ext/rtree/rtree.c $(HDR) $(EXTHDR)
1159 $(LTCOMPILE) -DSQLITE_CORE -c $(TOP)/ext/rtree/rtree.c
1161 sqlite3session.lo: $(TOP)/ext/userauth/userauth.c $(HDR) $(EXTHDR)
1162 $(LTCOMPILE) -DSQLITE_CORE -c $(TOP)/ext/userauth/userauth.c
1164 userauth.lo: $(TOP)/ext/session/sqlite3session.c $(HDR) $(EXTHDR)
1165 $(LTCOMPILE) -DSQLITE_CORE -c $(TOP)/ext/session/sqlite3session.c
1167 json1.lo: $(TOP)/ext/misc/json1.c
1168 $(LTCOMPILE) -DSQLITE_CORE -c $(TOP)/ext/misc/json1.c
1170 stmt.lo: $(TOP)/ext/misc/stmt.c
1171 $(LTCOMPILE) -DSQLITE_CORE -c $(TOP)/ext/misc/stmt.c
1173 # FTS5 things
1175 FTS5_SRC = \
1176 $(TOP)/ext/fts5/fts5.h \
1177 $(TOP)/ext/fts5/fts5Int.h \
1178 $(TOP)/ext/fts5/fts5_aux.c \
1179 $(TOP)/ext/fts5/fts5_buffer.c \
1180 $(TOP)/ext/fts5/fts5_main.c \
1181 $(TOP)/ext/fts5/fts5_config.c \
1182 $(TOP)/ext/fts5/fts5_expr.c \
1183 $(TOP)/ext/fts5/fts5_hash.c \
1184 $(TOP)/ext/fts5/fts5_index.c \
1185 fts5parse.c fts5parse.h \
1186 $(TOP)/ext/fts5/fts5_storage.c \
1187 $(TOP)/ext/fts5/fts5_tokenize.c \
1188 $(TOP)/ext/fts5/fts5_unicode2.c \
1189 $(TOP)/ext/fts5/fts5_varint.c \
1190 $(TOP)/ext/fts5/fts5_vocab.c \
1192 fts5parse.c: $(TOP)/ext/fts5/fts5parse.y lemon
1193 cp $(TOP)/ext/fts5/fts5parse.y .
1194 rm -f fts5parse.h
1195 ./lemon$(BEXE) $(OPTS) fts5parse.y
1197 fts5parse.h: fts5parse.c
1199 fts5.c: $(FTS5_SRC)
1200 $(TCLSH_CMD) $(TOP)/ext/fts5/tool/mkfts5c.tcl
1201 cp $(TOP)/ext/fts5/fts5.h .
1203 fts5.lo: fts5.c $(HDR) $(EXTHDR)
1204 $(LTCOMPILE) -DSQLITE_CORE -c fts5.c
1206 sqlite3rbu.lo: $(TOP)/ext/rbu/sqlite3rbu.c $(HDR) $(EXTHDR)
1207 $(LTCOMPILE) -DSQLITE_CORE -c $(TOP)/ext/rbu/sqlite3rbu.c
1210 # Rules to build the 'testfixture' application.
1212 # If using the amalgamation, use sqlite3.c directly to build the test
1213 # fixture. Otherwise link against libsqlcipher.la. (This distinction is
1214 # necessary because the test fixture requires non-API symbols which are
1215 # hidden when the library is built via the amalgamation).
1217 TESTFIXTURE_FLAGS = -DSQLITE_TEST=1 -DSQLITE_CRASH_TEST=1
1218 TESTFIXTURE_FLAGS += -DTCLSH_INIT_PROC=sqlite3TestInit
1219 TESTFIXTURE_FLAGS += -DSQLITE_SERVER=1 -DSQLITE_PRIVATE="" -DSQLITE_CORE
1220 TESTFIXTURE_FLAGS += -DBUILD_sqlite
1221 TESTFIXTURE_FLAGS += -DSQLITE_SERIES_CONSTRAINT_VERIFY=1
1222 TESTFIXTURE_FLAGS += -DSQLITE_DEFAULT_PAGE_SIZE=1024
1223 TESTFIXTURE_FLAGS += -DSQLITE_ENABLE_STMTVTAB
1224 TESTFIXTURE_FLAGS += -DSQLITE_ENABLE_DBPAGE_VTAB
1226 TESTFIXTURE_SRC0 = $(TESTSRC2) libsqlcipher.la
1227 TESTFIXTURE_SRC1 = sqlite3.c
1228 TESTFIXTURE_SRC = $(TESTSRC) $(TOP)/src/tclsqlite.c
1229 TESTFIXTURE_SRC += $(TESTFIXTURE_SRC$(USE_AMALGAMATION))
1231 testfixture$(TEXE): $(TESTFIXTURE_SRC)
1232 $(LTLINK) -DSQLITE_NO_SYNC=1 $(TEMP_STORE) $(TESTFIXTURE_FLAGS) \
1233 -o $@ $(TESTFIXTURE_SRC) $(LIBTCL) $(TLIBS)
1235 coretestprogs: $(TESTPROGS)
1237 testprogs: coretestprogs srcck1$(BEXE) fuzzcheck$(TEXE) sessionfuzz$(TEXE)
1239 # A very detailed test running most or all test cases
1240 fulltest: $(TESTPROGS) fuzztest
1241 ./testfixture$(TEXE) $(TOP)/test/all.test $(TESTOPTS)
1243 # Really really long testing
1244 soaktest: $(TESTPROGS)
1245 ./testfixture$(TEXE) $(TOP)/test/all.test -soak=1 $(TESTOPTS)
1247 # Do extra testing but not everything.
1248 fulltestonly: $(TESTPROGS) fuzztest
1249 ./testfixture$(TEXE) $(TOP)/test/full.test
1251 # Fuzz testing
1252 fuzztest: fuzzcheck$(TEXE) $(FUZZDATA) sessionfuzz$(TEXE) $(TOP)/test/sessionfuzz-data1.db
1253 ./fuzzcheck$(TEXE) $(FUZZDATA)
1254 ./sessionfuzz$(TEXE) run $(TOP)/test/sessionfuzz-data1.db
1256 fastfuzztest: fuzzcheck$(TEXE) $(FUZZDATA) sessionfuzz$(TEXE) $(TOP)/test/sessionfuzz-data1.db
1257 ./fuzzcheck$(TEXE) --limit-mem 100M $(FUZZDATA)
1258 ./sessionfuzz$(TEXE) run $(TOP)/test/sessionfuzz-data1.db
1260 valgrindfuzz: fuzzcheck$(TEXT) $(FUZZDATA) sessionfuzz$(TEXE) $(TOP)/test/sessionfuzz-data1.db
1261 valgrind ./fuzzcheck$(TEXE) --cell-size-check --limit-mem 10M --timeout 600 $(FUZZDATA)
1262 valgrind ./sessionfuzz$(TEXE) run $(TOP)/test/sessionfuzz-data1.db
1264 # The veryquick.test TCL tests.
1266 tcltest: ./testfixture$(TEXE)
1267 ./testfixture$(TEXE) $(TOP)/test/veryquick.test $(TESTOPTS)
1269 # Minimal testing that runs in less than 3 minutes
1271 quicktest: ./testfixture$(TEXE)
1272 ./testfixture$(TEXE) $(TOP)/test/extraquick.test $(TESTOPTS)
1274 # This is the common case. Run many tests that do not take too long,
1275 # including fuzzcheck, sqlite3_analyzer, and sqldiff tests.
1277 test: fastfuzztest sourcetest $(TESTPROGS) tcltest
1279 # Run a test using valgrind. This can take a really long time
1280 # because valgrind is so much slower than a native machine.
1282 valgrindtest: $(TESTPROGS) valgrindfuzz
1283 OMIT_MISUSE=1 valgrind -v ./testfixture$(TEXE) $(TOP)/test/permutations.test valgrind $(TESTOPTS)
1285 # A very fast test that checks basic sanity. The name comes from
1286 # the 60s-era electronics testing: "Turn it on and see if smoke
1287 # comes out."
1289 smoketest: $(TESTPROGS) fuzzcheck$(TEXE)
1290 ./testfixture$(TEXE) $(TOP)/test/main.test $(TESTOPTS)
1292 sqlite3_analyzer.c: sqlite3.c $(TOP)/src/tclsqlite.c $(TOP)/tool/spaceanal.tcl $(TOP)/tool/mkccode.tcl $(TOP)/tool/sqlite3_analyzer.c.in
1293 $(TCLSH_CMD) $(TOP)/tool/mkccode.tcl $(TOP)/tool/sqlite3_analyzer.c.in >sqlite3_analyzer.c
1295 sqlite3_analyzer$(TEXE): sqlite3_analyzer.c
1296 $(LTLINK) sqlite3_analyzer.c -o $@ $(LIBTCL) $(TLIBS)
1298 sqltclsh.c: sqlite3.c $(TOP)/src/tclsqlite.c $(TOP)/tool/sqltclsh.tcl $(TOP)/ext/misc/appendvfs.c $(TOP)/tool/mkccode.tcl $(TOP)/tool/sqltclsh.c.in
1299 $(TCLSH_CMD) $(TOP)/tool/mkccode.tcl $(TOP)/tool/sqltclsh.c.in >sqltclsh.c
1301 sqltclsh$(TEXE): sqltclsh.c
1302 $(LTLINK) sqltclsh.c -o $@ $(LIBTCL) $(TLIBS)
1304 sqlite3_expert$(TEXE): $(TOP)/ext/expert/sqlite3expert.h $(TOP)/ext/expert/sqlite3expert.c $(TOP)/ext/expert/expert.c sqlite3.c
1305 $(LTLINK) $(TOP)/ext/expert/sqlite3expert.h $(TOP)/ext/expert/sqlite3expert.c $(TOP)/ext/expert/expert.c sqlite3.c -o sqlite3_expert $(TLIBS)
1307 CHECKER_DEPS =\
1308 $(TOP)/tool/mkccode.tcl \
1309 sqlite3.c \
1310 $(TOP)/src/tclsqlite.c \
1311 $(TOP)/ext/repair/sqlite3_checker.tcl \
1312 $(TOP)/ext/repair/checkindex.c \
1313 $(TOP)/ext/repair/checkfreelist.c \
1314 $(TOP)/ext/misc/btreeinfo.c \
1315 $(TOP)/ext/repair/sqlite3_checker.c.in
1317 sqlite3_checker.c: $(CHECKER_DEPS)
1318 $(TCLSH_CMD) $(TOP)/tool/mkccode.tcl $(TOP)/ext/repair/sqlite3_checker.c.in >$@
1320 sqlite3_checker$(TEXE): sqlite3_checker.c
1321 $(LTLINK) sqlite3_checker.c -o $@ $(LIBTCL) $(TLIBS)
1323 dbdump$(TEXE): $(TOP)/ext/misc/dbdump.c sqlite3.lo
1324 $(LTLINK) -DDBDUMP_STANDALONE -o $@ \
1325 $(TOP)/ext/misc/dbdump.c sqlite3.lo $(TLIBS)
1327 showdb$(TEXE): $(TOP)/tool/showdb.c sqlite3.lo
1328 $(LTLINK) -o $@ $(TOP)/tool/showdb.c sqlite3.lo $(TLIBS)
1330 showstat4$(TEXE): $(TOP)/tool/showstat4.c sqlite3.lo
1331 $(LTLINK) -o $@ $(TOP)/tool/showstat4.c sqlite3.lo $(TLIBS)
1333 showjournal$(TEXE): $(TOP)/tool/showjournal.c sqlite3.lo
1334 $(LTLINK) -o $@ $(TOP)/tool/showjournal.c sqlite3.lo $(TLIBS)
1336 showwal$(TEXE): $(TOP)/tool/showwal.c sqlite3.lo
1337 $(LTLINK) -o $@ $(TOP)/tool/showwal.c sqlite3.lo $(TLIBS)
1339 showshm$(TEXE): $(TOP)/tool/showshm.c
1340 $(LTLINK) -o $@ $(TOP)/tool/showshm.c
1342 changeset$(TEXE): $(TOP)/ext/session/changeset.c sqlite3.lo
1343 $(LTLINK) -o $@ $(TOP)/ext/session/changeset.c sqlite3.lo $(TLIBS)
1345 changesetfuzz$(TEXE): $(TOP)/ext/session/changesetfuzz.c sqlite3.lo
1346 $(LTLINK) -o $@ $(TOP)/ext/session/changesetfuzz.c sqlite3.lo $(TLIBS)
1348 rollback-test$(TEXE): $(TOP)/tool/rollback-test.c sqlite3.lo
1349 $(LTLINK) -o $@ $(TOP)/tool/rollback-test.c sqlite3.lo $(TLIBS)
1351 atrc$(TEXX): $(TOP)/test/atrc.c sqlite3.lo
1352 $(LTLINK) -o $@ $(TOP)/test/atrc.c sqlite3.lo $(TLIBS)
1354 LogEst$(TEXE): $(TOP)/tool/logest.c sqlite3.h
1355 $(LTLINK) -I. -o $@ $(TOP)/tool/logest.c
1357 wordcount$(TEXE): $(TOP)/test/wordcount.c sqlite3.lo
1358 $(LTLINK) -o $@ $(TOP)/test/wordcount.c sqlite3.lo $(TLIBS)
1360 speedtest1$(TEXE): $(TOP)/test/speedtest1.c sqlite3.c
1361 $(LTLINK) $(ST_OPT) -o $@ $(TOP)/test/speedtest1.c sqlite3.c $(TLIBS)
1363 KV_OPT += -DSQLITE_DIRECT_OVERFLOW_READ
1365 kvtest$(TEXE): $(TOP)/test/kvtest.c sqlite3.c
1366 $(LTLINK) $(KV_OPT) -o $@ $(TOP)/test/kvtest.c sqlite3.c $(TLIBS)
1368 rbu$(EXE): $(TOP)/ext/rbu/rbu.c $(TOP)/ext/rbu/sqlite3rbu.c sqlite3.lo
1369 $(LTLINK) -I. -o $@ $(TOP)/ext/rbu/rbu.c sqlite3.lo $(TLIBS)
1371 loadfts$(EXE): $(TOP)/tool/loadfts.c libsqlite3.la
1372 $(LTLINK) $(TOP)/tool/loadfts.c libsqlite3.la -o $@ $(TLIBS)
1374 # This target will fail if the SQLite amalgamation contains any exported
1375 # symbols that do not begin with "sqlite3_". It is run as part of the
1376 # releasetest.tcl script.
1378 VALIDIDS=' sqlite3(changeset|changegroup|session)?_'
1379 checksymbols: sqlite3.lo
1380 nm -g --defined-only sqlite3.lo | egrep -v $(VALIDIDS); test $$? -ne 0
1381 echo '0 errors out of 1 tests'
1383 # Build the amalgamation-autoconf package. The amalamgation-tarball target builds
1384 # a tarball named for the version number. Ex: sqlite-autoconf-3110000.tar.gz.
1385 # The snapshot-tarball target builds a tarball named by the SHA1 hash
1387 amalgamation-tarball: sqlite3.c
1388 TOP=$(TOP) sh $(TOP)/tool/mkautoconfamal.sh --normal
1390 snapshot-tarball: sqlite3.c
1391 TOP=$(TOP) sh $(TOP)/tool/mkautoconfamal.sh --snapshot
1393 # The next two rules are used to support the "threadtest" target. Building
1394 # threadtest runs a few thread-safety tests that are implemented in C. This
1395 # target is invoked by the releasetest.tcl script.
1397 THREADTEST3_SRC = $(TOP)/test/threadtest3.c \
1398 $(TOP)/test/tt3_checkpoint.c \
1399 $(TOP)/test/tt3_index.c \
1400 $(TOP)/test/tt3_vacuum.c \
1401 $(TOP)/test/tt3_stress.c \
1402 $(TOP)/test/tt3_lookaside1.c
1404 threadtest3$(TEXE): sqlite3.lo $(THREADTEST3_SRC)
1405 $(LTLINK) $(TOP)/test/threadtest3.c $(TOP)/src/test_multiplex.c sqlite3.lo -o $@ $(TLIBS)
1407 threadtest: threadtest3$(TEXE)
1408 ./threadtest3$(TEXE)
1410 releasetest:
1411 $(TCLSH_CMD) $(TOP)/test/releasetest.tcl
1413 # Standard install and cleanup targets
1415 lib_install: libsqlcipher.la
1416 $(INSTALL) -d $(DESTDIR)$(libdir)
1417 $(LTINSTALL) libsqlcipher.la $(DESTDIR)$(libdir)
1419 install: sqlcipher$(TEXE) lib_install sqlite3.h sqlcipher.pc ${HAVE_TCL:1=tcl_install}
1420 $(INSTALL) -d $(DESTDIR)$(bindir)
1421 $(LTINSTALL) sqlcipher$(TEXE) $(DESTDIR)$(bindir)
1422 $(INSTALL) -d $(DESTDIR)$(includedir)
1423 $(INSTALL) -m 0644 sqlite3.h $(DESTDIR)$(includedir)
1424 $(INSTALL) -m 0644 $(TOP)/src/sqlite3ext.h $(DESTDIR)$(includedir)
1425 $(INSTALL) -d $(DESTDIR)$(pkgconfigdir)
1426 $(INSTALL) -m 0644 sqlcipher.pc $(DESTDIR)$(pkgconfigdir)
1428 pkgIndex.tcl:
1429 echo 'package ifneeded sqlite3 $(RELEASE) [list load $(TCLLIBDIR)/libtclsqlite3$(SHLIB_SUFFIX) sqlite3]' > $@
1430 tcl_install: lib_install libtclsqlite3.la pkgIndex.tcl
1431 $(INSTALL) -d $(DESTDIR)$(TCLLIBDIR)
1432 $(LTINSTALL) libtclsqlite3.la $(DESTDIR)$(TCLLIBDIR)
1433 rm -f $(DESTDIR)$(TCLLIBDIR)/libtclsqlite3.la $(DESTDIR)$(TCLLIBDIR)/libtclsqlite3.a
1434 $(INSTALL) -m 0644 pkgIndex.tcl $(DESTDIR)$(TCLLIBDIR)
1436 clean:
1437 rm -f *.lo *.la *.o sqlcipher$(TEXE) libsqlcipher.la
1438 rm -f sqlite3.h opcodes.*
1439 rm -rf .libs .deps
1440 rm -f lemon$(BEXE) lempar.c parse.* sqlite*.tar.gz
1441 rm -f mkkeywordhash$(BEXE) keywordhash.h
1442 rm -f *.da *.bb *.bbg gmon.out
1443 rm -rf tsrc .target_source
1444 rm -f tclsqlcipher$(TEXE)
1445 rm -f testfixture$(TEXE) test.db
1446 rm -f LogEst$(TEXE) fts3view$(TEXE) rollback-test$(TEXE) showdb$(TEXE)
1447 rm -f showjournal$(TEXE) showstat4$(TEXE) showwal$(TEXE) speedtest1$(TEXE)
1448 rm -f wordcount$(TEXE) changeset$(TEXE)
1449 rm -f sqlite3.dll sqlite3.lib sqlite3.exp sqlite3.def
1450 rm -f sqlite3.c
1451 rm -f sqlite3rc.h
1452 rm -f shell.c sqlite3ext.h
1453 rm -f sqlite3_analyzer$(TEXE) sqlite3_analyzer.c
1454 rm -f sqlite-*-output.vsix
1455 rm -f mptester mptester.exe
1456 rm -f rbu rbu.exe
1457 rm -f srcck1 srcck1.exe
1458 rm -f fuzzershell fuzzershell.exe
1459 rm -f fuzzcheck fuzzcheck.exe
1460 rm -f sqldiff sqldiff.exe
1461 rm -f dbhash dbhash.exe
1462 rm -f fts5.* fts5parse.*
1464 distclean: clean
1465 rm -f config.h config.log config.status libtool Makefile sqlcipher.pc
1468 # Windows section
1470 dll: sqlite3.dll
1472 REAL_LIBOBJ = $(LIBOBJ:%.lo=.libs/%.o)
1474 $(REAL_LIBOBJ): $(LIBOBJ)
1476 sqlite3.def: $(REAL_LIBOBJ)
1477 echo 'EXPORTS' >sqlite3.def
1478 nm $(REAL_LIBOBJ) | grep ' T ' | grep ' _sqlite3_' \
1479 | sed 's/^.* _//' >>sqlite3.def
1481 sqlite3.dll: $(REAL_LIBOBJ) sqlite3.def
1482 $(TCC) -shared -o $@ sqlite3.def \
1483 -Wl,"--strip-all" $(REAL_LIBOBJ)