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.
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 # 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.)
30 TCC
= @CC@ @CPPFLAGS@ @CFLAGS@
-I.
-I
${TOP}/src
-I
${TOP}/ext
/rtree
32 # Define this for the autoconf-based build, so that the code knows it can
33 # include the generated config.h
35 TCC
+= -D_HAVE_SQLITE_CONFIG_H
-DBUILD_sqlite
37 # Define -DNDEBUG to compile without debugging (i.e., for production usage)
38 # Omitting the define will cause extra debugging code to be inserted and
39 # includes extra comments when "EXPLAIN stmt" is used.
41 TCC
+= @TARGET_DEBUG@ @XTHREADCONNECT@
43 # Compiler options needed for programs that use the TCL library.
45 TCC
+= @TCL_INCLUDE_SPEC@
47 # The library that programs using TCL must link against.
49 LIBTCL
= @TCL_LIB_SPEC@ @TCL_LIBS@
51 # Compiler options needed for programs that use the readline() library.
53 READLINE_FLAGS
= -DHAVE_READLINE
=@TARGET_HAVE_READLINE@ @TARGET_READLINE_INC@
55 # The library that programs using readline() must link against.
57 LIBREADLINE
= @TARGET_READLINE_LIBS@
59 # Should the database engine be compiled threadsafe
61 TCC
+= -DSQLITE_THREADSAFE
=@SQLITE_THREADSAFE@
63 # Any target libraries which libsqlite must be linked against
67 # Flags controlling use of the in memory btree implementation
69 # SQLITE_TEMP_STORE is 0 to force temporary tables to be in a file, 1 to
70 # default to file, 2 to default to memory, and 3 to force temporary
71 # tables to always be in memory.
73 TEMP_STORE
= -DSQLITE_TEMP_STORE
=@TEMP_STORE@
75 # Enable/disable loadable extensions, and other optional features
76 # based on configuration. (-DSQLITE_OMIT*, -DSQLITE_ENABLE*).
77 # The same set of OMIT and ENABLE flags should be passed to the
78 # LEMON parser generator and the mkkeywordhash tool as well.
79 OPT_FEATURE_FLAGS
= @OPT_FEATURE_FLAGS@
81 TCC
+= $(OPT_FEATURE_FLAGS
)
83 # Add in any optional parameters specified on the make commane line
84 # ie. make "OPTS=-DSQLITE_ENABLE_FOO=1 -DSQLITE_OMIT_FOO=1".
87 # Version numbers and release number for the SQLite being compiled.
90 VERSION_NUMBER
= @VERSION_NUMBER@
96 TEXE
= @TARGET_EXEEXT@
98 # The following variable is "1" if the configure script was able to locate
99 # the tclConfig.sh file. It is an empty string otherwise. When this
100 # variable is "1", the TCL extension library (libtclsqlite3.so) is built
103 HAVE_TCL
= @HAVE_TCL@
105 # This is the command to use for tclsh - normally just "tclsh", but we may
106 # know the specific version we want to use
108 TCLSH_CMD
= @TCLSH_CMD@
110 # Where do we want to install the tcl plugin
112 TCLLIBDIR
= @TCLLIBDIR@
114 # The suffix used on shared libraries. Ex: ".dll", ".so", ".dylib"
116 SHLIB_SUFFIX
= @TCL_SHLIB_SUFFIX@
118 # If gcov support was enabled by the configure script, add the appropriate
119 # flags here. It's not always as easy as just having the user add the right
120 # CFLAGS / LDFLAGS, because libtool wants to use CFLAGS when linking, which
121 # causes build errors with -fprofile-arcs -ftest-coverage with some GCCs.
122 # Supposedly GCC does the right thing if you use --coverage, but in
123 # practice it still fails. See:
125 # http://www.mail-archive.com/debian-gcc@lists.debian.org/msg26197.html
129 GCOV_CFLAGS1
= -DSQLITE_COVERAGE_TEST
=1 -fprofile-arcs
-ftest-coverage
130 GCOV_LDFLAGS1
= -lgcov
131 USE_GCOV
= @USE_GCOV@
132 LTCOMPILE_EXTRAS
+= $(GCOV_CFLAGS
$(USE_GCOV
))
133 LTLINK_EXTRAS
+= $(GCOV_LDFLAGS
$(USE_GCOV
))
141 $(TOP
)/src
/crypto.h \
142 $(TOP
)/src
/crypto.c \
143 $(TOP
)/src
/crypto_impl.c
147 # The directory into which to store package information for
149 # Some standard variables and programs
152 exec_prefix = @
exec_prefix@
154 pkgconfigdir
= $(libdir)/pkgconfig
156 includedir = @
includedir@
159 ALLOWRELEASE
= @ALLOWRELEASE@
161 # libtool compile/link/install
162 LTCOMPILE
= $(LIBTOOL
) --mode
=compile
--tag
=CC
$(TCC
) $(LTCOMPILE_EXTRAS
)
163 LTLINK
= $(LIBTOOL
) --mode
=link
$(TCC
) $(LTCOMPILE_EXTRAS
) @LDFLAGS@
$(LTLINK_EXTRAS
)
164 LTINSTALL
= $(LIBTOOL
) --mode
=install $(INSTALL
)
166 # nawk compatible awk.
169 # You should not have to change anything below this line
170 ###############################################################################
172 USE_AMALGAMATION
= @USE_AMALGAMATION@
174 # Object files for the SQLite library (non-amalgamation).
176 LIBOBJS0
= alter.lo analyze.lo attach.lo auth.lo \
177 backup.lo bitvec.lo btmutex.lo btree.lo build.lo \
178 callback.lo complete.lo ctime.lo date.lo delete.lo \
179 expr.lo fault.lo fkey.lo \
180 fts3.lo fts3_aux.lo fts3_expr.lo fts3_hash.lo fts3_icu.lo fts3_porter.lo \
181 fts3_snippet.lo fts3_tokenizer.lo fts3_tokenizer1.lo fts3_write.lo \
182 func.lo global.lo hash.lo \
183 icu.lo insert.lo journal.lo legacy.lo loadext.lo \
184 main.lo malloc.lo mem0.lo mem1.lo mem2.lo mem3.lo mem5.lo \
186 mutex.lo mutex_noop.lo mutex_os2.lo mutex_unix.lo mutex_w32.lo \
187 notify.lo opcodes.lo os.lo os_os2.lo os_unix.lo os_win.lo \
188 pager.lo parse.lo pcache.lo pcache1.lo pragma.lo prepare.lo printf.lo \
189 random.lo resolve.lo rowset.lo rtree.lo select.lo status.lo \
190 table.lo tokenize.lo trigger.lo \
191 update.lo util.lo vacuum.lo \
192 vdbe.lo vdbeapi.lo vdbeaux.lo vdbeblob.lo vdbemem.lo vdbesort.lo \
193 vdbetrace.lo wal.lo walker.lo where.lo utf.lo vtab.lo
$(CRYPTOLIBOBJ
)
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.
209 $(TOP
)/src
/analyze.c \
210 $(TOP
)/src
/attach.c \
212 $(TOP
)/src
/backup.c \
213 $(TOP
)/src
/bitvec.c \
214 $(TOP
)/src
/btmutex.c \
217 $(TOP
)/src
/btreeInt.h \
219 $(TOP
)/src
/callback.c \
220 $(TOP
)/src
/complete.c \
223 $(TOP
)/src
/delete.c \
228 $(TOP
)/src
/global.c \
231 $(TOP
)/src
/hwtime.h \
232 $(TOP
)/src
/insert.c \
233 $(TOP
)/src
/journal.c \
234 $(TOP
)/src
/legacy.c \
235 $(TOP
)/src
/loadext.c \
237 $(TOP
)/src
/malloc.c \
243 $(TOP
)/src
/memjournal.c \
246 $(TOP
)/src
/mutex_noop.c \
247 $(TOP
)/src
/mutex_os2.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_os2.c \
255 $(TOP
)/src
/os_unix.c \
256 $(TOP
)/src
/os_win.c \
260 $(TOP
)/src
/pcache.c \
261 $(TOP
)/src
/pcache.h \
262 $(TOP
)/src
/pcache1.c \
263 $(TOP
)/src
/pragma.c \
264 $(TOP
)/src
/prepare.c \
265 $(TOP
)/src
/printf.c \
266 $(TOP
)/src
/random.c \
267 $(TOP
)/src
/resolve.c \
268 $(TOP
)/src
/rowset.c \
269 $(TOP
)/src
/select.c \
270 $(TOP
)/src
/status.c \
272 $(TOP
)/src
/sqlite.h.in \
273 $(TOP
)/src
/sqlite3ext.h \
274 $(TOP
)/src
/sqliteInt.h \
275 $(TOP
)/src
/sqliteLimit.h \
277 $(TOP
)/src
/tclsqlite.c \
278 $(TOP
)/src
/tokenize.c \
279 $(TOP
)/src
/trigger.c \
281 $(TOP
)/src
/update.c \
283 $(TOP
)/src
/vacuum.c \
286 $(TOP
)/src
/vdbeapi.c \
287 $(TOP
)/src
/vdbeaux.c \
288 $(TOP
)/src
/vdbeblob.c \
289 $(TOP
)/src
/vdbemem.c \
290 $(TOP
)/src
/vdbesort.c \
291 $(TOP
)/src
/vdbetrace.c \
292 $(TOP
)/src
/vdbeInt.h \
296 $(TOP
)/src
/walker.c \
299 # Source code for extensions
302 $(TOP
)/ext
/fts1
/fts1.c \
303 $(TOP
)/ext
/fts1
/fts1.h \
304 $(TOP
)/ext
/fts1
/fts1_hash.c \
305 $(TOP
)/ext
/fts1
/fts1_hash.h \
306 $(TOP
)/ext
/fts1
/fts1_porter.c \
307 $(TOP
)/ext
/fts1
/fts1_tokenizer.h \
308 $(TOP
)/ext
/fts1
/fts1_tokenizer1.c
310 $(TOP
)/ext
/fts2
/fts2.c \
311 $(TOP
)/ext
/fts2
/fts2.h \
312 $(TOP
)/ext
/fts2
/fts2_hash.c \
313 $(TOP
)/ext
/fts2
/fts2_hash.h \
314 $(TOP
)/ext
/fts2
/fts2_icu.c \
315 $(TOP
)/ext
/fts2
/fts2_porter.c \
316 $(TOP
)/ext
/fts2
/fts2_tokenizer.h \
317 $(TOP
)/ext
/fts2
/fts2_tokenizer.c \
318 $(TOP
)/ext
/fts2
/fts2_tokenizer1.c
320 $(TOP
)/ext
/fts3
/fts3.c \
321 $(TOP
)/ext
/fts3
/fts3.h \
322 $(TOP
)/ext
/fts3
/fts3Int.h \
323 $(TOP
)/ext
/fts3
/fts3_aux.c \
324 $(TOP
)/ext
/fts3
/fts3_expr.c \
325 $(TOP
)/ext
/fts3
/fts3_hash.c \
326 $(TOP
)/ext
/fts3
/fts3_hash.h \
327 $(TOP
)/ext
/fts3
/fts3_icu.c \
328 $(TOP
)/ext
/fts3
/fts3_porter.c \
329 $(TOP
)/ext
/fts3
/fts3_snippet.c \
330 $(TOP
)/ext
/fts3
/fts3_tokenizer.h \
331 $(TOP
)/ext
/fts3
/fts3_tokenizer.c \
332 $(TOP
)/ext
/fts3
/fts3_tokenizer1.c \
333 $(TOP
)/ext
/fts3
/fts3_write.c
335 $(TOP
)/ext
/icu
/sqliteicu.h \
338 $(TOP
)/ext
/rtree
/rtree.h \
339 $(TOP
)/ext
/rtree
/rtree.c
342 # Generated source code files
353 # Source code to the test files.
365 $(TOP
)/src
/test_autoext.c \
366 $(TOP
)/src
/test_async.c \
367 $(TOP
)/src
/test_backup.c \
368 $(TOP
)/src
/test_btree.c \
369 $(TOP
)/src
/test_config.c \
370 $(TOP
)/src
/test_demovfs.c \
371 $(TOP
)/src
/test_devsym.c \
372 $(TOP
)/src
/test_func.c \
373 $(TOP
)/src
/test_fuzzer.c \
374 $(TOP
)/src
/test_hexio.c \
375 $(TOP
)/src
/test_init.c \
376 $(TOP
)/src
/test_intarray.c \
377 $(TOP
)/src
/test_journal.c \
378 $(TOP
)/src
/test_malloc.c \
379 $(TOP
)/src
/test_multiplex.c \
380 $(TOP
)/src
/test_mutex.c \
381 $(TOP
)/src
/test_onefile.c \
382 $(TOP
)/src
/test_osinst.c \
383 $(TOP
)/src
/test_pcache.c \
384 $(TOP
)/src
/test_quota.c \
385 $(TOP
)/src
/test_rtree.c \
386 $(TOP
)/src
/test_schema.c \
387 $(TOP
)/src
/test_server.c \
388 $(TOP
)/src
/test_superlock.c \
389 $(TOP
)/src
/test_syscall.c \
390 $(TOP
)/src
/test_stat.c \
391 $(TOP
)/src
/test_tclvar.c \
392 $(TOP
)/src
/test_thread.c \
393 $(TOP
)/src
/test_vfs.c \
394 $(TOP
)/src
/test_wholenumber.c \
395 $(TOP
)/src
/test_wsd.c \
396 $(TOP
)/ext
/fts3
/fts3_term.c \
397 $(TOP
)/ext
/fts3
/fts3_test.c
399 # Source code to the library files needed by the test fixture
402 $(TOP
)/src
/attach.c \
403 $(TOP
)/src
/backup.c \
404 $(TOP
)/src
/bitvec.c \
411 $(TOP
)/src
/insert.c \
415 $(TOP
)/src
/os_os2.c \
416 $(TOP
)/src
/os_unix.c \
417 $(TOP
)/src
/os_win.c \
419 $(TOP
)/src
/pragma.c \
420 $(TOP
)/src
/prepare.c \
421 $(TOP
)/src
/printf.c \
422 $(TOP
)/src
/random.c \
423 $(TOP
)/src
/pcache.c \
424 $(TOP
)/src
/pcache1.c \
425 $(TOP
)/src
/select.c \
426 $(TOP
)/src
/tokenize.c \
429 $(TOP
)/src
/vdbeapi.c \
430 $(TOP
)/src
/vdbeaux.c \
432 $(TOP
)/src
/vdbemem.c \
433 $(TOP
)/src
/vdbetrace.c \
436 $(TOP
)/ext
/fts3
/fts3.c \
437 $(TOP
)/ext
/fts3
/fts3_aux.c \
438 $(TOP
)/ext
/fts3
/fts3_expr.c \
439 $(TOP
)/ext
/fts3
/fts3_term.c \
440 $(TOP
)/ext
/fts3
/fts3_tokenizer.c \
441 $(TOP
)/ext
/fts3
/fts3_write.c \
442 $(TOP
)/ext
/async
/sqlite3async.c
444 # Header files used by all library source files.
448 $(TOP
)/src
/btreeInt.h \
450 $(TOP
)/src
/hwtime.h \
455 $(TOP
)/src
/os_common.h \
457 $(TOP
)/src
/pcache.h \
460 $(TOP
)/src
/sqlite3ext.h \
461 $(TOP
)/src
/sqliteInt.h \
462 $(TOP
)/src
/sqliteLimit.h \
464 $(TOP
)/src
/vdbeInt.h \
467 # Header files used by extensions
470 $(TOP
)/ext
/fts1
/fts1.h \
471 $(TOP
)/ext
/fts1
/fts1_hash.h \
472 $(TOP
)/ext
/fts1
/fts1_tokenizer.h
474 $(TOP
)/ext
/fts2
/fts2.h \
475 $(TOP
)/ext
/fts2
/fts2_hash.h \
476 $(TOP
)/ext
/fts2
/fts2_tokenizer.h
478 $(TOP
)/ext
/fts3
/fts3.h \
479 $(TOP
)/ext
/fts3
/fts3Int.h \
480 $(TOP
)/ext
/fts3
/fts3_hash.h \
481 $(TOP
)/ext
/fts3
/fts3_tokenizer.h
483 $(TOP
)/ext
/rtree
/rtree.h
485 $(TOP
)/ext
/icu
/sqliteicu.h
487 $(TOP
)/ext
/rtree
/sqlite3rtree.h
489 # This is the default Makefile target. The objects listed here
490 # are what get build when you type just "make" with no arguments.
492 all: sqlite3.h libsqlite3.la sqlite3
$(TEXE
) $(HAVE_TCL
:1=libtclsqlite3.la
)
494 Makefile
: $(TOP
)/Makefile.in
497 sqlite3.
pc: $(TOP
)/sqlite3.
pc.in
500 libsqlite3.la
: $(LIBOBJ
)
501 $(LTLINK
) -o
$@
$(LIBOBJ
) $(TLIBS
) \
502 ${ALLOWRELEASE} -rpath
"$(libdir)" -version-info
"8:6:8"
504 libtclsqlite3.la
: tclsqlite.lo libsqlite3.la
505 $(LTLINK
) -o
$@ tclsqlite.lo \
506 libsqlite3.la @TCL_STUB_LIB_SPEC@
$(TLIBS
) \
507 -rpath
"$(TCLLIBDIR)" \
508 -version-info
"8:6:8" \
511 sqlite3
$(TEXE
): $(TOP
)/src
/shell.c libsqlite3.la sqlite3.h
512 $(LTLINK
) $(READLINE_FLAGS
) \
513 -o
$@
$(TOP
)/src
/shell.c libsqlite3.la \
514 $(LIBREADLINE
) $(TLIBS
) -rpath
"$(libdir)"
516 # This target creates a directory named "tsrc" and fills it with
517 # copies of all of the C source code and header files needed to
518 # build on the target system. Some of the C source code and header
519 # files are automatically generated. This target takes care of
520 # all that automatic generation.
522 .target_source
: $(SRC
) $(TOP
)/tool
/vdbe-compress.tcl
526 rm tsrc
/sqlite.h.in tsrc
/parse.y
527 $(TCLSH_CMD
) $(TOP
)/tool
/vdbe-compress.tcl
<tsrc
/vdbe.c
>vdbe.new
528 mv vdbe.new tsrc
/vdbe.c
531 sqlite3.c
: .target_source
$(TOP
)/tool
/mksqlite3c.tcl
532 $(TCLSH_CMD
) $(TOP
)/tool
/mksqlite3c.tcl
534 tclsqlite3.c
: sqlite3.c
535 echo
'#ifndef USE_SYSTEM_SQLITE' >tclsqlite3.c
536 cat sqlite3.c
>>tclsqlite3.c
537 echo
'#endif /* USE_SYSTEM_SQLITE */' >>tclsqlite3.c
538 cat
$(TOP
)/src
/tclsqlite.c
>>tclsqlite3.c
540 sqlite3-all.c
: sqlite3.c
$(TOP
)/tool
/split-sqlite3c.tcl
541 $(TCLSH_CMD
) $(TOP
)/tool
/split-sqlite3c.tcl
543 # Rule to build the amalgamation
545 sqlite3.lo
: sqlite3.c
546 $(LTCOMPILE
) $(TEMP_STORE
) -c sqlite3.c
548 # Rules to build the LEMON compiler generator
550 lemon
$(BEXE
): $(TOP
)/tool
/lemon.c
$(TOP
)/src
/lempar.c
551 $(BCC
) -o
$@
$(TOP
)/tool
/lemon.c
552 cp
$(TOP
)/src
/lempar.c .
554 # Rules to build individual *.o files from generated *.c files. This
560 parse.lo
: parse.c
$(HDR
)
561 $(LTCOMPILE
) $(TEMP_STORE
) -c parse.c
563 opcodes.lo
: opcodes.c
564 $(LTCOMPILE
) $(TEMP_STORE
) -c opcodes.c
567 crypto.lo
: $(TOP
)/src
/crypto.c
$(HDR
)
568 $(LTCOMPILE
) -c
$(TOP
)/src
/crypto.c
569 crypto_impl.lo
: $(TOP
)/src
/crypto_impl.c
$(HDR
)
570 $(LTCOMPILE
) -c
$(TOP
)/src
/crypto_impl.c
573 # Rules to build individual *.o files from files in the src directory.
575 alter.lo
: $(TOP
)/src
/alter.c
$(HDR
)
576 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/alter.c
578 analyze.lo
: $(TOP
)/src
/analyze.c
$(HDR
)
579 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/analyze.c
581 attach.lo
: $(TOP
)/src
/attach.c
$(HDR
)
582 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/attach.c
584 auth.lo
: $(TOP
)/src
/auth.c
$(HDR
)
585 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/auth.c
587 backup.lo
: $(TOP
)/src
/backup.c
$(HDR
)
588 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/backup.c
590 bitvec.lo
: $(TOP
)/src
/bitvec.c
$(HDR
)
591 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/bitvec.c
593 btmutex.lo
: $(TOP
)/src
/btmutex.c
$(HDR
)
594 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/btmutex.c
596 btree.lo
: $(TOP
)/src
/btree.c
$(HDR
) $(TOP
)/src
/pager.h
597 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/btree.c
599 build.lo
: $(TOP
)/src
/build.c
$(HDR
)
600 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/build.c
602 callback.lo
: $(TOP
)/src
/callback.c
$(HDR
)
603 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/callback.c
605 complete.lo
: $(TOP
)/src
/complete.c
$(HDR
)
606 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/complete.c
608 ctime.lo
: $(TOP
)/src
/ctime.c
$(HDR
)
609 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/ctime.c
611 date.lo
: $(TOP
)/src
/date.c
$(HDR
)
612 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/date.c
614 delete.lo
: $(TOP
)/src
/delete.c
$(HDR
)
615 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/delete.c
617 expr.lo
: $(TOP
)/src
/expr.c
$(HDR
)
618 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/expr.c
620 fault.lo
: $(TOP
)/src
/fault.c
$(HDR
)
621 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/fault.c
623 fkey.lo
: $(TOP
)/src
/fkey.c
$(HDR
)
624 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/fkey.c
626 func.lo
: $(TOP
)/src
/func.c
$(HDR
)
627 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/func.c
629 global.lo
: $(TOP
)/src
/global.c
$(HDR
)
630 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/global.c
632 hash.lo
: $(TOP
)/src
/hash.c
$(HDR
)
633 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/hash.c
635 insert.lo
: $(TOP
)/src
/insert.c
$(HDR
)
636 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/insert.c
638 journal.lo
: $(TOP
)/src
/journal.c
$(HDR
)
639 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/journal.c
641 legacy.lo
: $(TOP
)/src
/legacy.c
$(HDR
)
642 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/legacy.c
644 loadext.lo
: $(TOP
)/src
/loadext.c
$(HDR
)
645 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/loadext.c
647 main.lo
: $(TOP
)/src
/main.c
$(HDR
)
648 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/main.c
650 malloc.lo
: $(TOP
)/src
/malloc.c
$(HDR
)
651 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/malloc.c
653 mem0.lo
: $(TOP
)/src
/mem0.c
$(HDR
)
654 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/mem0.c
656 mem1.lo
: $(TOP
)/src
/mem1.c
$(HDR
)
657 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/mem1.c
659 mem2.lo
: $(TOP
)/src
/mem2.c
$(HDR
)
660 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/mem2.c
662 mem3.lo
: $(TOP
)/src
/mem3.c
$(HDR
)
663 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/mem3.c
665 mem5.lo
: $(TOP
)/src
/mem5.c
$(HDR
)
666 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/mem5.c
668 memjournal.lo
: $(TOP
)/src
/memjournal.c
$(HDR
)
669 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/memjournal.c
671 mutex.lo
: $(TOP
)/src
/mutex.c
$(HDR
)
672 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/mutex.c
674 mutex_noop.lo
: $(TOP
)/src
/mutex_noop.c
$(HDR
)
675 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/mutex_noop.c
677 mutex_os2.lo
: $(TOP
)/src
/mutex_os2.c
$(HDR
)
678 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/mutex_os2.c
680 mutex_unix.lo
: $(TOP
)/src
/mutex_unix.c
$(HDR
)
681 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/mutex_unix.c
683 mutex_w32.lo
: $(TOP
)/src
/mutex_w32.c
$(HDR
)
684 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/mutex_w32.c
686 notify.lo
: $(TOP
)/src
/notify.c
$(HDR
)
687 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/notify.c
689 pager.lo
: $(TOP
)/src
/pager.c
$(HDR
) $(TOP
)/src
/pager.h
690 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/pager.c
692 pcache.lo
: $(TOP
)/src
/pcache.c
$(HDR
) $(TOP
)/src
/pcache.h
693 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/pcache.c
695 pcache1.lo
: $(TOP
)/src
/pcache1.c
$(HDR
) $(TOP
)/src
/pcache.h
696 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/pcache1.c
698 os.lo
: $(TOP
)/src
/os.c
$(HDR
)
699 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/os.c
701 os_unix.lo
: $(TOP
)/src
/os_unix.c
$(HDR
)
702 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/os_unix.c
704 os_win.lo
: $(TOP
)/src
/os_win.c
$(HDR
)
705 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/os_win.c
707 os_os2.lo
: $(TOP
)/src
/os_os2.c
$(HDR
)
708 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/os_os2.c
710 pragma.lo
: $(TOP
)/src
/pragma.c
$(HDR
)
711 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/pragma.c
713 prepare.lo
: $(TOP
)/src
/prepare.c
$(HDR
)
714 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/prepare.c
716 printf.lo
: $(TOP
)/src
/printf.c
$(HDR
)
717 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/printf.c
719 random.lo
: $(TOP
)/src
/random.c
$(HDR
)
720 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/random.c
722 resolve.lo
: $(TOP
)/src
/resolve.c
$(HDR
)
723 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/resolve.c
725 rowset.lo
: $(TOP
)/src
/rowset.c
$(HDR
)
726 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/rowset.c
728 select.lo
: $(TOP
)/src
/select.c
$(HDR
)
729 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/select.c
731 status.lo
: $(TOP
)/src
/status.c
$(HDR
)
732 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/status.c
734 table.lo
: $(TOP
)/src
/table.c
$(HDR
)
735 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/table.c
737 tokenize.lo
: $(TOP
)/src
/tokenize.c keywordhash.h
$(HDR
)
738 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/tokenize.c
740 trigger.lo
: $(TOP
)/src
/trigger.c
$(HDR
)
741 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/trigger.c
743 update.lo
: $(TOP
)/src
/update.c
$(HDR
)
744 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/update.c
746 utf.lo
: $(TOP
)/src
/utf.c
$(HDR
)
747 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/utf.c
749 util.lo
: $(TOP
)/src
/util.c
$(HDR
)
750 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/util.c
752 vacuum.lo
: $(TOP
)/src
/vacuum.c
$(HDR
)
753 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/vacuum.c
755 vdbe.lo
: $(TOP
)/src
/vdbe.c
$(HDR
)
756 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/vdbe.c
758 vdbeapi.lo
: $(TOP
)/src
/vdbeapi.c
$(HDR
)
759 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/vdbeapi.c
761 vdbeaux.lo
: $(TOP
)/src
/vdbeaux.c
$(HDR
)
762 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/vdbeaux.c
764 vdbeblob.lo
: $(TOP
)/src
/vdbeblob.c
$(HDR
)
765 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/vdbeblob.c
767 vdbemem.lo
: $(TOP
)/src
/vdbemem.c
$(HDR
)
768 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/vdbemem.c
770 vdbesort.lo
: $(TOP
)/src
/vdbesort.c
$(HDR
)
771 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/vdbesort.c
773 vdbetrace.lo
: $(TOP
)/src
/vdbetrace.c
$(HDR
)
774 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/vdbetrace.c
776 vtab.lo
: $(TOP
)/src
/vtab.c
$(HDR
)
777 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/vtab.c
779 wal.lo
: $(TOP
)/src
/wal.c
$(HDR
)
780 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/wal.c
782 walker.lo
: $(TOP
)/src
/walker.c
$(HDR
)
783 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/walker.c
785 where.lo
: $(TOP
)/src
/where.c
$(HDR
)
786 $(LTCOMPILE
) $(TEMP_STORE
) -c
$(TOP
)/src
/where.c
788 tclsqlite.lo
: $(TOP
)/src
/tclsqlite.c
$(HDR
)
789 $(LTCOMPILE
) -DUSE_TCL_STUBS
=1 -c
$(TOP
)/src
/tclsqlite.c
791 tclsqlite-shell.lo
: $(TOP
)/src
/tclsqlite.c
$(HDR
)
792 $(LTCOMPILE
) -DTCLSH
=1 -o
$@
-c
$(TOP
)/src
/tclsqlite.c
794 tclsqlite-stubs.lo
: $(TOP
)/src
/tclsqlite.c
$(HDR
)
795 $(LTCOMPILE
) -DUSE_TCL_STUBS
=1 -o
$@
-c
$(TOP
)/src
/tclsqlite.c
797 tclsqlite3
$(TEXE
): tclsqlite-shell.lo libsqlite3.la
798 $(LTLINK
) -o
$@ tclsqlite-shell.lo \
799 libsqlite3.la
$(LIBTCL
)
801 # Rules to build opcodes.c and opcodes.h
803 opcodes.c
: opcodes.h
$(TOP
)/mkopcodec.awk
804 $(NAWK
) -f
$(TOP
)/mkopcodec.awk opcodes.h
>opcodes.c
806 opcodes.h
: parse.h
$(TOP
)/src
/vdbe.c
$(TOP
)/mkopcodeh.awk
807 cat parse.h
$(TOP
)/src
/vdbe.c |
$(NAWK
) -f
$(TOP
)/mkopcodeh.awk
>opcodes.h
809 # Rules to build parse.c and parse.h - the outputs of lemon.
813 parse.c
: $(TOP
)/src
/parse.y lemon
$(BEXE
) $(TOP
)/addopcodes.awk
814 cp
$(TOP
)/src
/parse.y .
816 .
/lemon
$(BEXE
) $(OPT_FEATURE_FLAGS
) $(OPTS
) parse.y
817 mv parse.h parse.h.temp
818 $(NAWK
) -f
$(TOP
)/addopcodes.awk parse.h.temp
>parse.h
820 sqlite3.h
: $(TOP
)/src
/sqlite.h.in
$(TOP
)/manifest.uuid
$(TOP
)/VERSION
821 $(TCLSH_CMD
) $(TOP
)/tool
/mksqlite3h.tcl
$(TOP
) >sqlite3.h
823 keywordhash.h
: $(TOP
)/tool
/mkkeywordhash.c
824 $(BCC
) -o mkkeywordhash
$(BEXE
) $(OPT_FEATURE_FLAGS
) $(OPTS
) $(TOP
)/tool
/mkkeywordhash.c
825 .
/mkkeywordhash
$(BEXE
) >keywordhash.h
829 # Rules to build the extension objects.
831 icu.lo
: $(TOP
)/ext
/icu
/icu.c
$(HDR
) $(EXTHDR
)
832 $(LTCOMPILE
) -DSQLITE_CORE
-c
$(TOP
)/ext
/icu
/icu.c
834 fts2.lo
: $(TOP
)/ext
/fts2
/fts2.c
$(HDR
) $(EXTHDR
)
835 $(LTCOMPILE
) -DSQLITE_CORE
-c
$(TOP
)/ext
/fts2
/fts2.c
837 fts2_hash.lo
: $(TOP
)/ext
/fts2
/fts2_hash.c
$(HDR
) $(EXTHDR
)
838 $(LTCOMPILE
) -DSQLITE_CORE
-c
$(TOP
)/ext
/fts2
/fts2_hash.c
840 fts2_icu.lo
: $(TOP
)/ext
/fts2
/fts2_icu.c
$(HDR
) $(EXTHDR
)
841 $(LTCOMPILE
) -DSQLITE_CORE
-c
$(TOP
)/ext
/fts2
/fts2_icu.c
843 fts2_porter.lo
: $(TOP
)/ext
/fts2
/fts2_porter.c
$(HDR
) $(EXTHDR
)
844 $(LTCOMPILE
) -DSQLITE_CORE
-c
$(TOP
)/ext
/fts2
/fts2_porter.c
846 fts2_tokenizer.lo
: $(TOP
)/ext
/fts2
/fts2_tokenizer.c
$(HDR
) $(EXTHDR
)
847 $(LTCOMPILE
) -DSQLITE_CORE
-c
$(TOP
)/ext
/fts2
/fts2_tokenizer.c
849 fts2_tokenizer1.lo
: $(TOP
)/ext
/fts2
/fts2_tokenizer1.c
$(HDR
) $(EXTHDR
)
850 $(LTCOMPILE
) -DSQLITE_CORE
-c
$(TOP
)/ext
/fts2
/fts2_tokenizer1.c
852 fts3.lo
: $(TOP
)/ext
/fts3
/fts3.c
$(HDR
) $(EXTHDR
)
853 $(LTCOMPILE
) -DSQLITE_CORE
-c
$(TOP
)/ext
/fts3
/fts3.c
855 fts3_aux.lo
: $(TOP
)/ext
/fts3
/fts3_aux.c
$(HDR
) $(EXTHDR
)
856 $(LTCOMPILE
) -DSQLITE_CORE
-c
$(TOP
)/ext
/fts3
/fts3_aux.c
858 fts3_expr.lo
: $(TOP
)/ext
/fts3
/fts3_expr.c
$(HDR
) $(EXTHDR
)
859 $(LTCOMPILE
) -DSQLITE_CORE
-c
$(TOP
)/ext
/fts3
/fts3_expr.c
861 fts3_hash.lo
: $(TOP
)/ext
/fts3
/fts3_hash.c
$(HDR
) $(EXTHDR
)
862 $(LTCOMPILE
) -DSQLITE_CORE
-c
$(TOP
)/ext
/fts3
/fts3_hash.c
864 fts3_icu.lo
: $(TOP
)/ext
/fts3
/fts3_icu.c
$(HDR
) $(EXTHDR
)
865 $(LTCOMPILE
) -DSQLITE_CORE
-c
$(TOP
)/ext
/fts3
/fts3_icu.c
867 fts3_porter.lo
: $(TOP
)/ext
/fts3
/fts3_porter.c
$(HDR
) $(EXTHDR
)
868 $(LTCOMPILE
) -DSQLITE_CORE
-c
$(TOP
)/ext
/fts3
/fts3_porter.c
870 fts3_snippet.lo
: $(TOP
)/ext
/fts3
/fts3_snippet.c
$(HDR
) $(EXTHDR
)
871 $(LTCOMPILE
) -DSQLITE_CORE
-c
$(TOP
)/ext
/fts3
/fts3_snippet.c
873 fts3_tokenizer.lo
: $(TOP
)/ext
/fts3
/fts3_tokenizer.c
$(HDR
) $(EXTHDR
)
874 $(LTCOMPILE
) -DSQLITE_CORE
-c
$(TOP
)/ext
/fts3
/fts3_tokenizer.c
876 fts3_tokenizer1.lo
: $(TOP
)/ext
/fts3
/fts3_tokenizer1.c
$(HDR
) $(EXTHDR
)
877 $(LTCOMPILE
) -DSQLITE_CORE
-c
$(TOP
)/ext
/fts3
/fts3_tokenizer1.c
879 fts3_write.lo
: $(TOP
)/ext
/fts3
/fts3_write.c
$(HDR
) $(EXTHDR
)
880 $(LTCOMPILE
) -DSQLITE_CORE
-c
$(TOP
)/ext
/fts3
/fts3_write.c
882 rtree.lo
: $(TOP
)/ext
/rtree
/rtree.c
$(HDR
) $(EXTHDR
)
883 $(LTCOMPILE
) -DSQLITE_CORE
-c
$(TOP
)/ext
/rtree
/rtree.c
886 # Rules to build the 'testfixture' application.
888 # If using the amalgamation, use sqlite3.c directly to build the test
889 # fixture. Otherwise link against libsqlite3.la. (This distinction is
890 # necessary because the test fixture requires non-API symbols which are
891 # hidden when the library is built via the amalgamation).
893 TESTFIXTURE_FLAGS
= -DTCLSH
=1 -DSQLITE_TEST
=1 -DSQLITE_CRASH_TEST
=1
894 TESTFIXTURE_FLAGS
+= -DSQLITE_SERVER
=1 -DSQLITE_PRIVATE
="" -DSQLITE_CORE
895 TESTFIXTURE_FLAGS
+= -DBUILD_sqlite
897 TESTFIXTURE_SRC0
= $(TESTSRC2
) libsqlite3.la
898 TESTFIXTURE_SRC1
= sqlite3.c
899 TESTFIXTURE_SRC
= $(TESTSRC
) $(TOP
)/src
/tclsqlite.c
$(TESTFIXTURE_SRC
$(USE_AMALGAMATION
))
901 testfixture
$(TEXE
): $(TESTFIXTURE_SRC
)
902 $(LTLINK
) -DSQLITE_NO_SYNC
=1 $(TEMP_STORE
) $(TESTFIXTURE_FLAGS
) \
903 -o
$@
$(TESTFIXTURE_SRC
) $(LIBTCL
) $(TLIBS
)
906 fulltest
: testfixture
$(TEXE
) sqlite3
$(TEXE
)
907 .
/testfixture
$(TEXE
) $(TOP
)/test/all.
test
909 soaktest
: testfixture
$(TEXE
) sqlite3
$(TEXE
)
910 .
/testfixture
$(TEXE
) $(TOP
)/test/all.
test -soak
=1
912 test: testfixture
$(TEXE
) sqlite3
$(TEXE
)
913 .
/testfixture
$(TEXE
) $(TOP
)/test/veryquick.
test
915 sqlite3_analyzer.c
: sqlite3.c
$(TOP
)/src
/test_stat.c
$(TOP
)/src
/tclsqlite.c
$(TOP
)/tool
/spaceanal.tcl
916 echo
"#define TCLSH 2" > $@
917 cat sqlite3.c
$(TOP
)/src
/test_stat.c
$(TOP
)/src
/tclsqlite.c
>> $@
918 echo
"static const char *tclsh_main_loop(void){" >> $@
919 echo
"static const char *zMainloop = " >> $@
920 $(NAWK
) -f
$(TOP
)/tool
/tostr.awk
$(TOP
)/tool
/spaceanal.tcl
>> $@
921 echo
"; return zMainloop; }" >> $@
923 sqlite3_analyzer
$(TEXE
): sqlite3_analyzer.c
924 $(LTLINK
) sqlite3_analyzer.c
-o
$@
$(LIBTCL
) $(TLIBS
)
926 # Standard install and cleanup targets
928 lib_install
: libsqlite3.la
929 $(INSTALL
) -d
$(DESTDIR
)$(libdir)
930 $(LTINSTALL
) libsqlite3.la
$(DESTDIR
)$(libdir)
932 install: sqlite3
$(BEXE
) lib_install sqlite3.h sqlite3.
pc ${HAVE_TCL
:1=tcl_install
}
933 $(INSTALL
) -d
$(DESTDIR
)$(bindir)
934 $(LTINSTALL
) sqlite3
$(BEXE
) $(DESTDIR
)$(bindir)
935 $(INSTALL
) -d
$(DESTDIR
)$(includedir)
936 $(INSTALL
) -m
0644 sqlite3.h
$(DESTDIR
)$(includedir)
937 $(INSTALL
) -m
0644 $(TOP
)/src
/sqlite3ext.h
$(DESTDIR
)$(includedir)
938 $(INSTALL
) -d
$(DESTDIR
)$(pkgconfigdir
)
939 $(INSTALL
) -m
0644 sqlite3.
pc $(DESTDIR
)$(pkgconfigdir
)
942 echo
'package ifneeded sqlite3 $(RELEASE) [list load $(TCLLIBDIR)/libtclsqlite3.so sqlite3]' > $@
943 tcl_install
: lib_install libtclsqlite3.la pkgIndex.tcl
944 $(INSTALL
) -d
$(DESTDIR
)$(TCLLIBDIR
)
945 $(LTINSTALL
) libtclsqlite3.la
$(DESTDIR
)$(TCLLIBDIR
)
946 rm -f
$(DESTDIR
)$(TCLLIBDIR
)/libtclsqlite3.la
$(DESTDIR
)$(TCLLIBDIR
)/libtclsqlite3.a
947 $(INSTALL
) -m
0644 pkgIndex.tcl
$(DESTDIR
)$(TCLLIBDIR
)
950 rm -f
*.lo
*.la
*.o sqlite3
$(TEXE
) libsqlite3.la
951 rm -f sqlite3.h opcodes.
*
953 rm -f lemon
$(BEXE
) lempar.c parse.
* sqlite
*.
tar.gz
954 rm -f mkkeywordhash
$(BEXE
) keywordhash.h
956 rm -f
*.da
*.bb
*.bbg gmon.out
957 rm -rf quota2a quota2b quota2c
958 rm -rf tsrc .target_source
959 rm -f tclsqlite3
$(TEXE
)
960 rm -f testfixture
$(TEXE
) test.db
961 rm -f sqlite3.dll sqlite3.lib sqlite3.exp sqlite3.def
963 rm -f sqlite3_analyzer
$(TEXE
) sqlite3_analyzer.c
966 rm -f config.log config.status libtool Makefile sqlite3.
pc
973 REAL_LIBOBJ
= $(LIBOBJ
:%.lo
=.libs
/%.o
)
975 $(REAL_LIBOBJ
): $(LIBOBJ
)
977 sqlite3.def
: $(REAL_LIBOBJ
)
978 echo
'EXPORTS' >sqlite3.def
979 nm
$(REAL_LIBOBJ
) | grep
' T ' | grep
' _sqlite3_' \
980 | sed
's/^.* _//' >>sqlite3.def
982 sqlite3.dll
: $(REAL_LIBOBJ
) sqlite3.def
983 $(TCC
) -shared
-o
$@ sqlite3.def \
984 -Wl
,"--strip-all" $(REAL_LIBOBJ
)