2002-08-14 00:45:39 +04:00
|
|
|
###############################################################################
|
|
|
|
# The following macros should be defined before this script is
|
|
|
|
# invoked:
|
2001-09-28 05:34:43 +04:00
|
|
|
#
|
2002-08-14 00:45:39 +04:00
|
|
|
# TOP The toplevel directory of the source tree. This is the
|
|
|
|
# directory that contains this "Makefile.in" and the
|
|
|
|
# "configure.in" script.
|
2001-09-28 05:34:43 +04:00
|
|
|
#
|
2002-08-14 00:45:39 +04:00
|
|
|
# BCC C Compiler and options for use in building executables that
|
|
|
|
# will run on the platform that is doing the build.
|
2001-09-28 05:34:43 +04:00
|
|
|
#
|
2002-08-14 00:45:39 +04:00
|
|
|
# THREADLIB Specify any extra linker options needed to make the library
|
|
|
|
# thread safe
|
2001-09-28 05:34:43 +04:00
|
|
|
#
|
2002-08-14 00:45:39 +04:00
|
|
|
# OPTS Extra compiler command-line options.
|
2002-01-15 21:39:43 +03:00
|
|
|
#
|
2002-08-14 00:45:39 +04:00
|
|
|
# EXE The suffix to add to executable files. ".exe" for windows
|
|
|
|
# and "" for Unix.
|
2002-01-15 21:39:43 +03:00
|
|
|
#
|
2002-08-14 00:45:39 +04:00
|
|
|
# TCC C Compiler and options for use in building executables that
|
|
|
|
# will run on the target platform. This is usually the same
|
|
|
|
# as BCC, unless you are cross-compiling.
|
2001-09-28 05:34:43 +04:00
|
|
|
#
|
2002-08-14 00:45:39 +04:00
|
|
|
# AR Tools used to build a static library.
|
|
|
|
# RANLIB
|
2001-09-28 05:34:43 +04:00
|
|
|
#
|
2002-08-14 00:45:39 +04:00
|
|
|
# TCL_FLAGS Extra compiler options needed for programs that use the
|
|
|
|
# TCL library.
|
2001-09-28 05:34:43 +04:00
|
|
|
#
|
2002-08-14 00:45:39 +04:00
|
|
|
# LIBTCL Linker options needed to link against the TCL library.
|
2001-09-28 05:34:43 +04:00
|
|
|
#
|
2002-08-14 00:45:39 +04:00
|
|
|
# READLINE_FLAGS Compiler options needed for programs that use the
|
|
|
|
# readline() library.
|
2001-09-28 05:34:43 +04:00
|
|
|
#
|
2002-08-14 00:45:39 +04:00
|
|
|
# LIBREADLINE Linker options needed by programs using readline() must
|
|
|
|
# link against.
|
2001-09-28 05:34:43 +04:00
|
|
|
#
|
2006-01-23 21:06:52 +03:00
|
|
|
# NAWK Nawk compatible awk program. Older (obsolete?) solaris
|
|
|
|
# systems need this to avoid using the original AT&T AWK.
|
2001-09-28 05:34:43 +04:00
|
|
|
#
|
2002-08-14 00:45:39 +04:00
|
|
|
# Once the macros above are defined, the rest of this make script will
|
|
|
|
# build the SQLite library and testing tools.
|
|
|
|
################################################################################
|
2001-09-28 05:34:43 +04:00
|
|
|
|
|
|
|
# This is how we compile
|
|
|
|
#
|
2008-10-14 18:28:35 +04:00
|
|
|
TCCX = $(TCC) $(OPTS) -I. -I$(TOP)/src -I$(TOP)
|
|
|
|
TCCX += -I$(TOP)/ext/rtree -I$(TOP)/ext/icu -I$(TOP)/ext/fts3
|
2009-04-23 18:58:39 +04:00
|
|
|
TCCX += -I$(TOP)/ext/async
|
2011-03-08 22:22:50 +03:00
|
|
|
TCCX += -I$(TOP)/ext/session
|
2001-09-28 05:34:43 +04:00
|
|
|
|
|
|
|
# Object files for the SQLite library.
|
|
|
|
#
|
2013-07-29 17:51:54 +04:00
|
|
|
LIBOBJ+= vdbe.o parse.o \
|
|
|
|
alter.o analyze.o attach.o auth.o \
|
2009-02-03 19:51:24 +03:00
|
|
|
backup.o bitvec.o btmutex.o btree.o build.o \
|
2010-02-23 23:32:15 +03:00
|
|
|
callback.o complete.o ctime.o date.o delete.o expr.o fault.o fkey.o \
|
2011-02-01 19:34:32 +03:00
|
|
|
fts3.o fts3_aux.o fts3_expr.o fts3_hash.o fts3_icu.o fts3_porter.o \
|
2011-05-17 18:41:36 +04:00
|
|
|
fts3_snippet.o fts3_tokenizer.o fts3_tokenizer1.o \
|
2013-04-22 19:30:37 +04:00
|
|
|
fts3_tokenize_vtab.o \
|
2012-05-25 21:50:19 +04:00
|
|
|
fts3_unicode.o fts3_unicode2.o \
|
2011-05-13 21:11:20 +04:00
|
|
|
fts3_write.o func.o global.o hash.o \
|
2010-04-26 04:19:45 +04:00
|
|
|
icu.o insert.o journal.o legacy.o loadext.o \
|
2008-10-28 21:58:20 +03:00
|
|
|
main.o malloc.o mem0.o mem1.o mem2.o mem3.o mem5.o \
|
2008-10-17 22:51:52 +04:00
|
|
|
memjournal.o \
|
2012-06-21 17:00:37 +04:00
|
|
|
mutex.o mutex_noop.o mutex_unix.o mutex_w32.o \
|
|
|
|
notify.o opcodes.o os.o os_unix.o os_win.o \
|
2013-07-29 17:51:54 +04:00
|
|
|
pager.o pcache.o pcache1.o pragma.o prepare.o printf.o \
|
2009-04-22 06:15:47 +04:00
|
|
|
random.o resolve.o rowset.o rtree.o select.o status.o \
|
2008-08-20 20:35:10 +04:00
|
|
|
table.o tokenize.o trigger.o \
|
2004-06-18 21:10:16 +04:00
|
|
|
update.o util.o vacuum.o \
|
2013-07-29 17:51:54 +04:00
|
|
|
vdbeapi.o vdbeaux.o vdbeblob.o vdbemem.o vdbesort.o \
|
2011-07-12 18:28:05 +04:00
|
|
|
vdbetrace.o wal.o walker.o where.o utf.o vtab.o
|
2001-09-28 05:34:43 +04:00
|
|
|
|
2014-08-18 19:08:26 +04:00
|
|
|
LIBOBJ += sqlite3session.o
|
|
|
|
|
2007-06-25 18:28:48 +04:00
|
|
|
|
2008-10-14 18:28:35 +04:00
|
|
|
|
2001-09-28 05:34:43 +04:00
|
|
|
# All of the source code files.
|
|
|
|
#
|
|
|
|
SRC = \
|
2005-02-15 23:47:57 +03:00
|
|
|
$(TOP)/src/alter.c \
|
2005-07-08 16:13:04 +04:00
|
|
|
$(TOP)/src/analyze.c \
|
2003-04-07 01:08:24 +04:00
|
|
|
$(TOP)/src/attach.c \
|
2003-01-12 21:02:16 +03:00
|
|
|
$(TOP)/src/auth.c \
|
2009-02-03 19:51:24 +03:00
|
|
|
$(TOP)/src/backup.c \
|
2008-02-18 17:47:33 +03:00
|
|
|
$(TOP)/src/bitvec.c \
|
2007-08-28 06:27:51 +04:00
|
|
|
$(TOP)/src/btmutex.c \
|
2001-09-28 05:34:43 +04:00
|
|
|
$(TOP)/src/btree.c \
|
|
|
|
$(TOP)/src/btree.h \
|
2007-08-31 21:42:48 +04:00
|
|
|
$(TOP)/src/btreeInt.h \
|
2001-09-28 05:34:43 +04:00
|
|
|
$(TOP)/src/build.c \
|
2005-05-24 16:01:00 +04:00
|
|
|
$(TOP)/src/callback.c \
|
2005-08-14 21:53:20 +04:00
|
|
|
$(TOP)/src/complete.c \
|
2010-02-23 23:08:35 +03:00
|
|
|
$(TOP)/src/ctime.c \
|
2003-11-01 04:53:53 +03:00
|
|
|
$(TOP)/src/date.c \
|
2001-09-28 05:34:43 +04:00
|
|
|
$(TOP)/src/delete.c \
|
|
|
|
$(TOP)/src/expr.c \
|
2008-01-23 00:30:53 +03:00
|
|
|
$(TOP)/src/fault.c \
|
2009-09-19 21:59:59 +04:00
|
|
|
$(TOP)/src/fkey.c \
|
2008-08-21 22:49:27 +04:00
|
|
|
$(TOP)/src/func.c \
|
2008-06-13 22:24:27 +04:00
|
|
|
$(TOP)/src/global.c \
|
2001-09-28 05:34:43 +04:00
|
|
|
$(TOP)/src/hash.c \
|
|
|
|
$(TOP)/src/hash.h \
|
2008-05-30 00:22:37 +04:00
|
|
|
$(TOP)/src/hwtime.h \
|
2001-09-28 05:34:43 +04:00
|
|
|
$(TOP)/src/insert.c \
|
2007-08-22 15:22:03 +04:00
|
|
|
$(TOP)/src/journal.c \
|
2004-06-01 05:45:11 +04:00
|
|
|
$(TOP)/src/legacy.c \
|
2006-06-08 19:28:43 +04:00
|
|
|
$(TOP)/src/loadext.c \
|
2001-09-28 05:34:43 +04:00
|
|
|
$(TOP)/src/main.c \
|
2007-05-05 15:48:52 +04:00
|
|
|
$(TOP)/src/malloc.c \
|
2008-10-28 21:58:20 +03:00
|
|
|
$(TOP)/src/mem0.c \
|
2007-08-15 21:07:57 +04:00
|
|
|
$(TOP)/src/mem1.c \
|
|
|
|
$(TOP)/src/mem2.c \
|
2007-10-19 21:47:24 +04:00
|
|
|
$(TOP)/src/mem3.c \
|
2008-02-15 02:26:56 +03:00
|
|
|
$(TOP)/src/mem5.c \
|
2008-10-17 22:51:52 +04:00
|
|
|
$(TOP)/src/memjournal.c \
|
2007-08-15 17:04:54 +04:00
|
|
|
$(TOP)/src/mutex.c \
|
2007-08-31 21:42:48 +04:00
|
|
|
$(TOP)/src/mutex.h \
|
2008-10-07 19:25:48 +04:00
|
|
|
$(TOP)/src/mutex_noop.c \
|
2007-08-28 20:34:42 +04:00
|
|
|
$(TOP)/src/mutex_unix.c \
|
|
|
|
$(TOP)/src/mutex_w32.c \
|
2009-03-16 16:19:36 +03:00
|
|
|
$(TOP)/src/notify.c \
|
2005-11-30 06:20:31 +03:00
|
|
|
$(TOP)/src/os.c \
|
2007-08-31 21:42:48 +04:00
|
|
|
$(TOP)/src/os.h \
|
|
|
|
$(TOP)/src/os_common.h \
|
2013-11-26 05:00:31 +04:00
|
|
|
$(TOP)/src/os_setup.h \
|
2004-05-22 21:41:58 +04:00
|
|
|
$(TOP)/src/os_unix.c \
|
|
|
|
$(TOP)/src/os_win.c \
|
2013-11-25 13:36:07 +04:00
|
|
|
$(TOP)/src/os_win.h \
|
2001-09-28 05:34:43 +04:00
|
|
|
$(TOP)/src/pager.c \
|
|
|
|
$(TOP)/src/pager.h \
|
|
|
|
$(TOP)/src/parse.y \
|
2008-08-20 20:35:10 +04:00
|
|
|
$(TOP)/src/pcache.c \
|
|
|
|
$(TOP)/src/pcache.h \
|
2008-11-13 17:28:28 +03:00
|
|
|
$(TOP)/src/pcache1.c \
|
2003-04-07 01:08:24 +04:00
|
|
|
$(TOP)/src/pragma.c \
|
2005-05-25 08:11:56 +04:00
|
|
|
$(TOP)/src/prepare.c \
|
2001-09-28 05:34:43 +04:00
|
|
|
$(TOP)/src/printf.c \
|
|
|
|
$(TOP)/src/random.c \
|
2008-08-20 20:35:10 +04:00
|
|
|
$(TOP)/src/resolve.c \
|
2008-12-04 23:40:10 +03:00
|
|
|
$(TOP)/src/rowset.c \
|
2001-09-28 05:34:43 +04:00
|
|
|
$(TOP)/src/select.c \
|
2008-06-19 04:16:08 +04:00
|
|
|
$(TOP)/src/status.c \
|
2001-09-28 05:34:43 +04:00
|
|
|
$(TOP)/src/shell.c \
|
|
|
|
$(TOP)/src/sqlite.h.in \
|
2007-02-23 06:00:44 +03:00
|
|
|
$(TOP)/src/sqlite3ext.h \
|
2001-09-28 05:34:43 +04:00
|
|
|
$(TOP)/src/sqliteInt.h \
|
2007-08-31 21:42:48 +04:00
|
|
|
$(TOP)/src/sqliteLimit.h \
|
2001-09-28 05:34:43 +04:00
|
|
|
$(TOP)/src/table.c \
|
|
|
|
$(TOP)/src/tclsqlite.c \
|
|
|
|
$(TOP)/src/tokenize.c \
|
2002-05-15 16:45:43 +04:00
|
|
|
$(TOP)/src/trigger.c \
|
2004-05-11 05:18:24 +04:00
|
|
|
$(TOP)/src/utf.c \
|
2001-09-28 05:34:43 +04:00
|
|
|
$(TOP)/src/update.c \
|
|
|
|
$(TOP)/src/util.c \
|
2003-04-07 00:52:32 +04:00
|
|
|
$(TOP)/src/vacuum.c \
|
2001-09-28 05:34:43 +04:00
|
|
|
$(TOP)/src/vdbe.c \
|
|
|
|
$(TOP)/src/vdbe.h \
|
2004-05-27 05:53:56 +04:00
|
|
|
$(TOP)/src/vdbeapi.c \
|
2003-09-07 00:12:01 +04:00
|
|
|
$(TOP)/src/vdbeaux.c \
|
2007-05-01 21:49:49 +04:00
|
|
|
$(TOP)/src/vdbeblob.c \
|
2004-05-27 05:53:56 +04:00
|
|
|
$(TOP)/src/vdbemem.c \
|
2011-07-12 18:28:05 +04:00
|
|
|
$(TOP)/src/vdbesort.c \
|
2009-11-25 21:03:42 +03:00
|
|
|
$(TOP)/src/vdbetrace.c \
|
2003-09-07 00:12:01 +04:00
|
|
|
$(TOP)/src/vdbeInt.h \
|
2006-06-12 03:41:55 +04:00
|
|
|
$(TOP)/src/vtab.c \
|
2010-04-26 04:19:45 +04:00
|
|
|
$(TOP)/src/wal.c \
|
|
|
|
$(TOP)/src/wal.h \
|
2008-08-20 20:35:10 +04:00
|
|
|
$(TOP)/src/walker.c \
|
2013-11-12 22:37:25 +04:00
|
|
|
$(TOP)/src/where.c \
|
|
|
|
$(TOP)/src/whereInt.h
|
2001-09-28 05:34:43 +04:00
|
|
|
|
2006-10-03 23:12:32 +04:00
|
|
|
# Source code for extensions
|
|
|
|
#
|
|
|
|
SRC += \
|
|
|
|
$(TOP)/ext/fts1/fts1.c \
|
|
|
|
$(TOP)/ext/fts1/fts1.h \
|
|
|
|
$(TOP)/ext/fts1/fts1_hash.c \
|
|
|
|
$(TOP)/ext/fts1/fts1_hash.h \
|
|
|
|
$(TOP)/ext/fts1/fts1_porter.c \
|
|
|
|
$(TOP)/ext/fts1/fts1_tokenizer.h \
|
|
|
|
$(TOP)/ext/fts1/fts1_tokenizer1.c
|
2007-02-23 06:00:44 +03:00
|
|
|
SRC += \
|
|
|
|
$(TOP)/ext/fts2/fts2.c \
|
|
|
|
$(TOP)/ext/fts2/fts2.h \
|
|
|
|
$(TOP)/ext/fts2/fts2_hash.c \
|
|
|
|
$(TOP)/ext/fts2/fts2_hash.h \
|
2007-07-20 17:42:26 +04:00
|
|
|
$(TOP)/ext/fts2/fts2_icu.c \
|
2007-02-23 06:00:44 +03:00
|
|
|
$(TOP)/ext/fts2/fts2_porter.c \
|
|
|
|
$(TOP)/ext/fts2/fts2_tokenizer.h \
|
2007-07-20 17:42:26 +04:00
|
|
|
$(TOP)/ext/fts2/fts2_tokenizer.c \
|
2007-02-23 06:00:44 +03:00
|
|
|
$(TOP)/ext/fts2/fts2_tokenizer1.c
|
2007-08-20 21:37:47 +04:00
|
|
|
SRC += \
|
|
|
|
$(TOP)/ext/fts3/fts3.c \
|
|
|
|
$(TOP)/ext/fts3/fts3.h \
|
2009-11-26 01:42:22 +03:00
|
|
|
$(TOP)/ext/fts3/fts3Int.h \
|
2011-02-01 19:34:32 +03:00
|
|
|
$(TOP)/ext/fts3/fts3_aux.c \
|
2008-12-17 18:18:17 +03:00
|
|
|
$(TOP)/ext/fts3/fts3_expr.c \
|
2007-08-20 21:37:47 +04:00
|
|
|
$(TOP)/ext/fts3/fts3_hash.c \
|
|
|
|
$(TOP)/ext/fts3/fts3_hash.h \
|
|
|
|
$(TOP)/ext/fts3/fts3_icu.c \
|
|
|
|
$(TOP)/ext/fts3/fts3_porter.c \
|
2009-11-19 18:25:25 +03:00
|
|
|
$(TOP)/ext/fts3/fts3_snippet.c \
|
2007-08-20 21:37:47 +04:00
|
|
|
$(TOP)/ext/fts3/fts3_tokenizer.h \
|
|
|
|
$(TOP)/ext/fts3/fts3_tokenizer.c \
|
2009-11-13 13:36:20 +03:00
|
|
|
$(TOP)/ext/fts3/fts3_tokenizer1.c \
|
2013-04-22 19:30:37 +04:00
|
|
|
$(TOP)/ext/fts3/fts3_tokenize_vtab.c \
|
2012-05-25 21:50:19 +04:00
|
|
|
$(TOP)/ext/fts3/fts3_unicode.c \
|
|
|
|
$(TOP)/ext/fts3/fts3_unicode2.c \
|
2009-11-13 13:36:20 +03:00
|
|
|
$(TOP)/ext/fts3/fts3_write.c
|
2007-06-26 14:56:40 +04:00
|
|
|
SRC += \
|
2008-09-08 12:08:09 +04:00
|
|
|
$(TOP)/ext/icu/sqliteicu.h \
|
2009-08-21 06:07:09 +04:00
|
|
|
$(TOP)/ext/icu/icu.c
|
2008-05-27 00:19:25 +04:00
|
|
|
SRC += \
|
2014-05-08 01:16:56 +04:00
|
|
|
$(TOP)/ext/rtree/sqlite3rtree.h \
|
2008-05-27 00:19:25 +04:00
|
|
|
$(TOP)/ext/rtree/rtree.h \
|
|
|
|
$(TOP)/ext/rtree/rtree.c
|
2013-03-13 16:20:15 +04:00
|
|
|
SRC += \
|
|
|
|
$(TOP)/ext/session/sqlite3session.c \
|
|
|
|
$(TOP)/ext/session/sqlite3session.h
|
2007-02-23 06:00:44 +03:00
|
|
|
|
2007-06-20 12:49:05 +04:00
|
|
|
|
2007-02-23 06:00:44 +03:00
|
|
|
# Generated source code files
|
|
|
|
#
|
|
|
|
SRC += \
|
|
|
|
keywordhash.h \
|
|
|
|
opcodes.c \
|
|
|
|
opcodes.h \
|
|
|
|
parse.c \
|
|
|
|
parse.h \
|
|
|
|
sqlite3.h
|
2006-10-03 23:12:32 +04:00
|
|
|
|
|
|
|
|
2001-09-28 05:34:43 +04:00
|
|
|
# Source code to the test files.
|
|
|
|
#
|
2004-05-14 05:58:11 +04:00
|
|
|
TESTSRC = \
|
2011-06-21 19:24:30 +04:00
|
|
|
$(TOP)/ext/fts3/fts3_term.c \
|
2011-06-13 13:11:01 +04:00
|
|
|
$(TOP)/ext/fts3/fts3_test.c \
|
2001-09-28 05:34:43 +04:00
|
|
|
$(TOP)/src/test1.c \
|
|
|
|
$(TOP)/src/test2.c \
|
|
|
|
$(TOP)/src/test3.c \
|
2003-12-19 05:52:05 +03:00
|
|
|
$(TOP)/src/test4.c \
|
2004-05-08 12:23:19 +04:00
|
|
|
$(TOP)/src/test5.c \
|
2005-11-26 03:25:00 +03:00
|
|
|
$(TOP)/src/test6.c \
|
2006-01-10 02:40:25 +03:00
|
|
|
$(TOP)/src/test7.c \
|
2006-06-12 03:41:55 +04:00
|
|
|
$(TOP)/src/test8.c \
|
2007-03-29 16:19:11 +04:00
|
|
|
$(TOP)/src/test9.c \
|
2006-08-24 00:07:20 +04:00
|
|
|
$(TOP)/src/test_autoext.c \
|
2006-01-09 20:29:52 +03:00
|
|
|
$(TOP)/src/test_async.c \
|
2009-02-03 19:51:24 +03:00
|
|
|
$(TOP)/src/test_backup.c \
|
2007-05-05 22:39:25 +04:00
|
|
|
$(TOP)/src/test_btree.c \
|
2007-05-08 05:08:49 +04:00
|
|
|
$(TOP)/src/test_config.c \
|
2010-04-07 11:57:38 +04:00
|
|
|
$(TOP)/src/test_demovfs.c \
|
2008-01-22 14:50:13 +03:00
|
|
|
$(TOP)/src/test_devsym.c \
|
2013-01-11 13:58:54 +04:00
|
|
|
$(TOP)/src/test_fs.c \
|
2008-03-19 19:08:53 +03:00
|
|
|
$(TOP)/src/test_func.c \
|
2007-04-06 19:02:13 +04:00
|
|
|
$(TOP)/src/test_hexio.c \
|
2009-08-17 19:16:19 +04:00
|
|
|
$(TOP)/src/test_init.c \
|
2009-11-10 20:24:37 +03:00
|
|
|
$(TOP)/src/test_intarray.c \
|
2008-12-20 21:33:59 +03:00
|
|
|
$(TOP)/src/test_journal.c \
|
2007-08-15 23:16:43 +04:00
|
|
|
$(TOP)/src/test_malloc.c \
|
2010-11-05 00:03:47 +03:00
|
|
|
$(TOP)/src/test_multiplex.c \
|
2008-06-18 13:45:56 +04:00
|
|
|
$(TOP)/src/test_mutex.c \
|
2007-09-14 20:19:27 +04:00
|
|
|
$(TOP)/src/test_onefile.c \
|
2008-04-10 18:51:00 +04:00
|
|
|
$(TOP)/src/test_osinst.c \
|
2008-11-19 04:20:26 +03:00
|
|
|
$(TOP)/src/test_pcache.c \
|
2010-09-01 15:40:05 +04:00
|
|
|
$(TOP)/src/test_quota.c \
|
2010-08-28 22:58:00 +04:00
|
|
|
$(TOP)/src/test_rtree.c \
|
2006-06-15 19:59:19 +04:00
|
|
|
$(TOP)/src/test_schema.c \
|
2006-01-25 18:55:37 +03:00
|
|
|
$(TOP)/src/test_server.c \
|
2010-07-12 12:39:37 +04:00
|
|
|
$(TOP)/src/test_stat.c \
|
2012-11-26 23:50:41 +04:00
|
|
|
$(TOP)/src/test_sqllog.c \
|
2010-11-19 21:20:09 +03:00
|
|
|
$(TOP)/src/test_superlock.c \
|
2011-03-28 23:10:06 +04:00
|
|
|
$(TOP)/src/test_syscall.c \
|
2006-06-14 03:51:34 +04:00
|
|
|
$(TOP)/src/test_tclvar.c \
|
2007-09-07 15:29:25 +04:00
|
|
|
$(TOP)/src/test_thread.c \
|
2010-05-05 23:04:59 +04:00
|
|
|
$(TOP)/src/test_vfs.c \
|
2009-08-21 06:07:09 +04:00
|
|
|
$(TOP)/src/test_wsd.c
|
2007-08-31 21:42:48 +04:00
|
|
|
|
2013-04-25 18:31:46 +04:00
|
|
|
# Extensions to be statically loaded.
|
|
|
|
#
|
|
|
|
TESTSRC += \
|
2013-04-25 20:42:55 +04:00
|
|
|
$(TOP)/ext/misc/amatch.c \
|
|
|
|
$(TOP)/ext/misc/closure.c \
|
2014-06-16 16:44:32 +04:00
|
|
|
$(TOP)/ext/misc/fileio.c \
|
2013-04-25 18:31:46 +04:00
|
|
|
$(TOP)/ext/misc/fuzzer.c \
|
2013-04-25 20:42:55 +04:00
|
|
|
$(TOP)/ext/misc/ieee754.c \
|
2013-04-25 23:31:33 +04:00
|
|
|
$(TOP)/ext/misc/nextchar.c \
|
2013-05-29 00:25:54 +04:00
|
|
|
$(TOP)/ext/misc/percentile.c \
|
2013-04-25 18:31:46 +04:00
|
|
|
$(TOP)/ext/misc/regexp.c \
|
2013-04-25 18:59:01 +04:00
|
|
|
$(TOP)/ext/misc/spellfix.c \
|
2013-10-15 01:14:42 +04:00
|
|
|
$(TOP)/ext/misc/totype.c \
|
2013-10-10 17:04:46 +04:00
|
|
|
$(TOP)/ext/misc/wholenumber.c \
|
|
|
|
$(TOP)/ext/misc/vfslog.c
|
2013-04-25 18:31:46 +04:00
|
|
|
|
|
|
|
|
2007-11-23 20:31:17 +03:00
|
|
|
#TESTSRC += $(TOP)/ext/fts2/fts2_tokenizer.c
|
|
|
|
#TESTSRC += $(TOP)/ext/fts3/fts3_tokenizer.c
|
2001-09-28 05:34:43 +04:00
|
|
|
|
2007-08-31 21:42:48 +04:00
|
|
|
TESTSRC2 = \
|
2010-07-07 00:37:09 +04:00
|
|
|
$(TOP)/src/attach.c \
|
|
|
|
$(TOP)/src/backup.c \
|
|
|
|
$(TOP)/src/btree.c \
|
|
|
|
$(TOP)/src/build.c \
|
|
|
|
$(TOP)/src/date.c \
|
|
|
|
$(TOP)/src/expr.c \
|
|
|
|
$(TOP)/src/func.c \
|
|
|
|
$(TOP)/src/insert.c \
|
|
|
|
$(TOP)/src/wal.c \
|
2013-05-15 20:16:25 +04:00
|
|
|
$(TOP)/src/main.c \
|
2010-07-07 00:37:09 +04:00
|
|
|
$(TOP)/src/mem5.c \
|
|
|
|
$(TOP)/src/os.c \
|
|
|
|
$(TOP)/src/os_unix.c \
|
|
|
|
$(TOP)/src/os_win.c \
|
|
|
|
$(TOP)/src/pager.c \
|
|
|
|
$(TOP)/src/pragma.c \
|
|
|
|
$(TOP)/src/prepare.c \
|
|
|
|
$(TOP)/src/printf.c \
|
|
|
|
$(TOP)/src/random.c \
|
|
|
|
$(TOP)/src/pcache.c \
|
|
|
|
$(TOP)/src/pcache1.c \
|
|
|
|
$(TOP)/src/select.c \
|
|
|
|
$(TOP)/src/tokenize.c \
|
|
|
|
$(TOP)/src/utf.c \
|
|
|
|
$(TOP)/src/util.c \
|
|
|
|
$(TOP)/src/vdbeapi.c \
|
|
|
|
$(TOP)/src/vdbeaux.c \
|
|
|
|
$(TOP)/src/vdbe.c \
|
|
|
|
$(TOP)/src/vdbemem.c \
|
|
|
|
$(TOP)/src/where.c \
|
|
|
|
parse.c \
|
|
|
|
$(TOP)/ext/fts3/fts3.c \
|
2011-02-01 19:34:32 +03:00
|
|
|
$(TOP)/ext/fts3/fts3_aux.c \
|
2010-07-07 00:37:09 +04:00
|
|
|
$(TOP)/ext/fts3/fts3_expr.c \
|
|
|
|
$(TOP)/ext/fts3/fts3_tokenizer.c \
|
|
|
|
$(TOP)/ext/fts3/fts3_write.c \
|
2011-03-08 22:22:50 +03:00
|
|
|
$(TOP)/ext/async/sqlite3async.c \
|
|
|
|
$(TOP)/ext/session/sqlite3session.c \
|
|
|
|
$(TOP)/ext/session/test_session.c
|
2007-08-31 21:42:48 +04:00
|
|
|
|
2001-09-28 05:34:43 +04:00
|
|
|
# Header files used by all library source files.
|
|
|
|
#
|
|
|
|
HDR = \
|
|
|
|
$(TOP)/src/btree.h \
|
2007-05-05 15:48:52 +04:00
|
|
|
$(TOP)/src/btreeInt.h \
|
2001-09-28 05:34:43 +04:00
|
|
|
$(TOP)/src/hash.h \
|
2008-05-30 00:22:37 +04:00
|
|
|
$(TOP)/src/hwtime.h \
|
2007-08-31 21:42:48 +04:00
|
|
|
keywordhash.h \
|
2007-08-28 20:34:42 +04:00
|
|
|
$(TOP)/src/mutex.h \
|
2002-09-08 04:04:50 +04:00
|
|
|
opcodes.h \
|
2001-09-28 05:34:43 +04:00
|
|
|
$(TOP)/src/os.h \
|
2004-06-01 05:45:11 +04:00
|
|
|
$(TOP)/src/os_common.h \
|
2013-11-26 05:00:31 +04:00
|
|
|
$(TOP)/src/os_setup.h \
|
2013-11-25 13:36:07 +04:00
|
|
|
$(TOP)/src/os_win.h \
|
2007-08-31 21:42:48 +04:00
|
|
|
$(TOP)/src/pager.h \
|
2008-08-20 18:49:23 +04:00
|
|
|
$(TOP)/src/pcache.h \
|
2007-08-31 21:42:48 +04:00
|
|
|
parse.h \
|
2007-08-28 20:34:42 +04:00
|
|
|
sqlite3.h \
|
2006-06-08 19:28:43 +04:00
|
|
|
$(TOP)/src/sqlite3ext.h \
|
2001-09-28 05:34:43 +04:00
|
|
|
$(TOP)/src/sqliteInt.h \
|
2007-08-28 20:34:42 +04:00
|
|
|
$(TOP)/src/sqliteLimit.h \
|
2003-09-07 00:12:01 +04:00
|
|
|
$(TOP)/src/vdbe.h \
|
2013-11-12 22:37:25 +04:00
|
|
|
$(TOP)/src/vdbeInt.h \
|
|
|
|
$(TOP)/src/whereInt.h
|
2001-09-28 05:34:43 +04:00
|
|
|
|
2006-10-03 23:12:32 +04:00
|
|
|
# Header files used by extensions
|
|
|
|
#
|
2007-02-23 06:00:44 +03:00
|
|
|
EXTHDR += \
|
2006-10-03 23:12:32 +04:00
|
|
|
$(TOP)/ext/fts1/fts1.h \
|
|
|
|
$(TOP)/ext/fts1/fts1_hash.h \
|
|
|
|
$(TOP)/ext/fts1/fts1_tokenizer.h
|
2007-02-23 06:00:44 +03:00
|
|
|
EXTHDR += \
|
|
|
|
$(TOP)/ext/fts2/fts2.h \
|
|
|
|
$(TOP)/ext/fts2/fts2_hash.h \
|
|
|
|
$(TOP)/ext/fts2/fts2_tokenizer.h
|
2007-08-20 21:37:47 +04:00
|
|
|
EXTHDR += \
|
|
|
|
$(TOP)/ext/fts3/fts3.h \
|
2009-11-13 13:36:20 +03:00
|
|
|
$(TOP)/ext/fts3/fts3Int.h \
|
2007-08-20 21:37:47 +04:00
|
|
|
$(TOP)/ext/fts3/fts3_hash.h \
|
|
|
|
$(TOP)/ext/fts3/fts3_tokenizer.h
|
2008-05-27 00:19:25 +04:00
|
|
|
EXTHDR += \
|
|
|
|
$(TOP)/ext/rtree/rtree.h
|
2008-09-08 12:08:09 +04:00
|
|
|
EXTHDR += \
|
|
|
|
$(TOP)/ext/icu/sqliteicu.h
|
2006-10-03 23:12:32 +04:00
|
|
|
|
2001-09-28 05:34:43 +04:00
|
|
|
# This is the default Makefile target. The objects listed here
|
|
|
|
# are what get build when you type just "make" with no arguments.
|
|
|
|
#
|
2005-05-25 00:19:57 +04:00
|
|
|
all: sqlite3.h libsqlite3.a sqlite3$(EXE)
|
2001-09-28 05:34:43 +04:00
|
|
|
|
2007-08-21 02:48:41 +04:00
|
|
|
libsqlite3.a: $(LIBOBJ)
|
|
|
|
$(AR) libsqlite3.a $(LIBOBJ)
|
2004-05-31 22:23:07 +04:00
|
|
|
$(RANLIB) libsqlite3.a
|
2001-09-28 05:34:43 +04:00
|
|
|
|
2007-12-17 19:20:06 +03:00
|
|
|
sqlite3$(EXE): $(TOP)/src/shell.c libsqlite3.a sqlite3.h
|
2007-12-18 14:19:35 +03:00
|
|
|
$(TCCX) $(READLINE_FLAGS) -o sqlite3$(EXE) \
|
2007-12-13 21:20:46 +03:00
|
|
|
$(TOP)/src/shell.c \
|
|
|
|
libsqlite3.a $(LIBREADLINE) $(TLIBS) $(THREADLIB)
|
|
|
|
|
2013-04-08 18:28:33 +04:00
|
|
|
mptester$(EXE): sqlite3.c $(TOP)/mptest/mptest.c
|
|
|
|
$(TCCX) -o $@ -I. $(TOP)/mptest/mptest.c sqlite3.c \
|
|
|
|
$(TLIBS) $(THREADLIB)
|
|
|
|
|
2011-10-20 04:55:54 +04:00
|
|
|
sqlite3.o: sqlite3.c
|
2013-12-24 16:04:24 +04:00
|
|
|
$(TCCX) -I. -c sqlite3.c
|
2011-10-20 04:55:54 +04:00
|
|
|
|
2001-09-28 05:34:43 +04:00
|
|
|
# This target creates a directory named "tsrc" and fills it with
|
|
|
|
# copies of all of the C source code and header files needed to
|
|
|
|
# build on the target system. Some of the C source code and header
|
|
|
|
# files are automatically generated. This target takes care of
|
|
|
|
# all that automatic generation.
|
|
|
|
#
|
2009-06-02 19:21:42 +04:00
|
|
|
target_source: $(SRC) $(TOP)/tool/vdbe-compress.tcl
|
2001-09-28 05:34:43 +04:00
|
|
|
rm -rf tsrc
|
|
|
|
mkdir tsrc
|
2007-08-31 21:42:48 +04:00
|
|
|
cp -f $(SRC) tsrc
|
2001-09-28 05:34:43 +04:00
|
|
|
rm tsrc/sqlite.h.in tsrc/parse.y
|
2013-12-11 04:59:10 +04:00
|
|
|
tclsh $(TOP)/tool/vdbe-compress.tcl $(OPTS) <tsrc/vdbe.c >vdbe.new
|
2009-06-02 19:21:42 +04:00
|
|
|
mv vdbe.new tsrc/vdbe.c
|
2007-12-11 22:34:44 +03:00
|
|
|
touch target_source
|
2001-09-28 05:34:43 +04:00
|
|
|
|
2007-04-01 02:29:05 +04:00
|
|
|
sqlite3.c: target_source $(TOP)/tool/mksqlite3c.tcl
|
|
|
|
tclsh $(TOP)/tool/mksqlite3c.tcl
|
2013-03-19 19:23:18 +04:00
|
|
|
cp tsrc/shell.c tsrc/sqlite3ext.h .
|
|
|
|
cp $(TOP)/ext/session/sqlite3session.h .
|
2010-10-01 21:23:46 +04:00
|
|
|
echo '#ifndef USE_SYSTEM_SQLITE' >tclsqlite3.c
|
|
|
|
cat sqlite3.c >>tclsqlite3.c
|
|
|
|
echo '#endif /* USE_SYSTEM_SQLITE */' >>tclsqlite3.c
|
2007-04-06 01:58:33 +04:00
|
|
|
cat $(TOP)/src/tclsqlite.c >>tclsqlite3.c
|
2011-08-15 19:27:20 +04:00
|
|
|
|
2011-08-24 19:12:08 +04:00
|
|
|
sqlite3.c-debug: target_source $(TOP)/tool/mksqlite3c.tcl
|
2011-08-15 19:27:20 +04:00
|
|
|
tclsh $(TOP)/tool/mksqlite3c.tcl --linemacros
|
|
|
|
echo '#ifndef USE_SYSTEM_SQLITE' >tclsqlite3.c
|
|
|
|
cat sqlite3.c >>tclsqlite3.c
|
|
|
|
echo '#endif /* USE_SYSTEM_SQLITE */' >>tclsqlite3.c
|
|
|
|
echo '#line 1 "tclsqlite.c"' >>tclsqlite3.c
|
|
|
|
cat $(TOP)/src/tclsqlite.c >>tclsqlite3.c
|
2007-04-01 02:29:05 +04:00
|
|
|
|
2011-07-22 15:16:39 +04:00
|
|
|
sqlite3-all.c: sqlite3.c $(TOP)/tool/split-sqlite3c.tcl
|
|
|
|
tclsh $(TOP)/tool/split-sqlite3c.tcl
|
|
|
|
|
2007-07-20 17:42:26 +04:00
|
|
|
fts2amal.c: target_source $(TOP)/ext/fts2/mkfts2amal.tcl
|
|
|
|
tclsh $(TOP)/ext/fts2/mkfts2amal.tcl
|
|
|
|
|
2007-08-20 21:37:47 +04:00
|
|
|
fts3amal.c: target_source $(TOP)/ext/fts3/mkfts3amal.tcl
|
|
|
|
tclsh $(TOP)/ext/fts3/mkfts3amal.tcl
|
|
|
|
|
2001-09-28 05:34:43 +04:00
|
|
|
# Rules to build the LEMON compiler generator
|
|
|
|
#
|
2009-07-03 21:09:28 +04:00
|
|
|
lemon: $(TOP)/tool/lemon.c $(TOP)/src/lempar.c
|
2001-09-28 05:34:43 +04:00
|
|
|
$(BCC) -o lemon $(TOP)/tool/lemon.c
|
2009-07-03 21:09:28 +04:00
|
|
|
cp $(TOP)/src/lempar.c .
|
2001-09-28 05:34:43 +04:00
|
|
|
|
2007-08-31 21:42:48 +04:00
|
|
|
# Rules to build individual *.o files from generated *.c files. This
|
|
|
|
# applies to:
|
|
|
|
#
|
|
|
|
# parse.o
|
|
|
|
# opcodes.o
|
|
|
|
#
|
2008-03-20 05:25:35 +03:00
|
|
|
%.o: %.c $(HDR)
|
|
|
|
$(TCCX) -c $<
|
|
|
|
|
|
|
|
# Rules to build individual *.o files from files in the src directory.
|
|
|
|
#
|
2007-08-31 21:42:48 +04:00
|
|
|
%.o: $(TOP)/src/%.c $(HDR)
|
|
|
|
$(TCCX) -c $<
|
2007-08-28 20:34:42 +04:00
|
|
|
|
2007-08-31 21:42:48 +04:00
|
|
|
tclsqlite.o: $(TOP)/src/tclsqlite.c $(HDR)
|
|
|
|
$(TCCX) $(TCL_FLAGS) -c $(TOP)/src/tclsqlite.c
|
2007-08-28 20:34:42 +04:00
|
|
|
|
2001-09-28 05:34:43 +04:00
|
|
|
|
2002-09-08 04:04:50 +04:00
|
|
|
|
2007-08-31 21:42:48 +04:00
|
|
|
# Rules to build opcodes.c and opcodes.h
|
|
|
|
#
|
2004-10-06 19:03:57 +04:00
|
|
|
opcodes.c: opcodes.h $(TOP)/mkopcodec.awk
|
2011-08-30 05:29:04 +04:00
|
|
|
$(NAWK) -f $(TOP)/mkopcodec.awk opcodes.h >opcodes.c
|
2002-09-08 04:04:50 +04:00
|
|
|
|
2004-10-04 17:19:23 +04:00
|
|
|
opcodes.h: parse.h $(TOP)/src/vdbe.c $(TOP)/mkopcodeh.awk
|
2008-08-21 22:49:27 +04:00
|
|
|
cat parse.h $(TOP)/src/vdbe.c | \
|
|
|
|
$(NAWK) -f $(TOP)/mkopcodeh.awk >opcodes.h
|
2001-09-28 05:34:43 +04:00
|
|
|
|
2007-08-31 21:42:48 +04:00
|
|
|
# Rules to build parse.c and parse.h - the outputs of lemon.
|
|
|
|
#
|
2001-09-28 05:34:43 +04:00
|
|
|
parse.h: parse.c
|
|
|
|
|
2005-11-25 01:22:29 +03:00
|
|
|
parse.c: $(TOP)/src/parse.y lemon $(TOP)/addopcodes.awk
|
2001-09-28 05:34:43 +04:00
|
|
|
cp $(TOP)/src/parse.y .
|
2007-10-12 04:23:44 +04:00
|
|
|
rm -f parse.h
|
2004-10-31 00:23:09 +04:00
|
|
|
./lemon $(OPTS) parse.y
|
2005-11-25 01:22:29 +03:00
|
|
|
mv parse.h parse.h.temp
|
2010-07-07 00:37:09 +04:00
|
|
|
$(NAWK) -f $(TOP)/addopcodes.awk parse.h.temp >parse.h
|
2001-09-28 05:34:43 +04:00
|
|
|
|
2014-04-12 03:14:48 +04:00
|
|
|
sqlite3.h: $(TOP)/src/sqlite.h.in $(TOP)/manifest.uuid $(TOP)/VERSION $(TOP)/ext/rtree/sqlite3rtree.h
|
2009-08-14 20:01:24 +04:00
|
|
|
tclsh $(TOP)/tool/mksqlite3h.tcl $(TOP) >sqlite3.h
|
2001-09-28 05:34:43 +04:00
|
|
|
|
2005-01-18 07:00:42 +03:00
|
|
|
keywordhash.h: $(TOP)/tool/mkkeywordhash.c
|
2004-11-03 06:59:57 +03:00
|
|
|
$(BCC) -o mkkeywordhash $(OPTS) $(TOP)/tool/mkkeywordhash.c
|
2005-01-18 07:00:42 +03:00
|
|
|
./mkkeywordhash >keywordhash.h
|
2004-11-03 06:59:57 +03:00
|
|
|
|
2004-05-27 05:53:56 +04:00
|
|
|
|
2001-09-28 05:34:43 +04:00
|
|
|
|
2007-06-25 18:28:48 +04:00
|
|
|
# Rules to build the extension objects.
|
|
|
|
#
|
|
|
|
icu.o: $(TOP)/ext/icu/icu.c $(HDR) $(EXTHDR)
|
|
|
|
$(TCCX) -DSQLITE_CORE -c $(TOP)/ext/icu/icu.c
|
|
|
|
|
|
|
|
fts2.o: $(TOP)/ext/fts2/fts2.c $(HDR) $(EXTHDR)
|
|
|
|
$(TCCX) -DSQLITE_CORE -c $(TOP)/ext/fts2/fts2.c
|
|
|
|
|
|
|
|
fts2_hash.o: $(TOP)/ext/fts2/fts2_hash.c $(HDR) $(EXTHDR)
|
|
|
|
$(TCCX) -DSQLITE_CORE -c $(TOP)/ext/fts2/fts2_hash.c
|
|
|
|
|
|
|
|
fts2_icu.o: $(TOP)/ext/fts2/fts2_icu.c $(HDR) $(EXTHDR)
|
|
|
|
$(TCCX) -DSQLITE_CORE -c $(TOP)/ext/fts2/fts2_icu.c
|
|
|
|
|
|
|
|
fts2_porter.o: $(TOP)/ext/fts2/fts2_porter.c $(HDR) $(EXTHDR)
|
|
|
|
$(TCCX) -DSQLITE_CORE -c $(TOP)/ext/fts2/fts2_porter.c
|
|
|
|
|
|
|
|
fts2_tokenizer.o: $(TOP)/ext/fts2/fts2_tokenizer.c $(HDR) $(EXTHDR)
|
|
|
|
$(TCCX) -DSQLITE_CORE -c $(TOP)/ext/fts2/fts2_tokenizer.c
|
|
|
|
|
|
|
|
fts2_tokenizer1.o: $(TOP)/ext/fts2/fts2_tokenizer1.c $(HDR) $(EXTHDR)
|
|
|
|
$(TCCX) -DSQLITE_CORE -c $(TOP)/ext/fts2/fts2_tokenizer1.c
|
|
|
|
|
2007-08-20 21:37:47 +04:00
|
|
|
fts3.o: $(TOP)/ext/fts3/fts3.c $(HDR) $(EXTHDR)
|
|
|
|
$(TCCX) -DSQLITE_CORE -c $(TOP)/ext/fts3/fts3.c
|
|
|
|
|
2011-02-01 19:34:32 +03:00
|
|
|
fts3_aux.o: $(TOP)/ext/fts3/fts3_aux.c $(HDR) $(EXTHDR)
|
|
|
|
$(TCCX) -DSQLITE_CORE -c $(TOP)/ext/fts3/fts3_aux.c
|
|
|
|
|
2008-12-17 18:18:17 +03:00
|
|
|
fts3_expr.o: $(TOP)/ext/fts3/fts3_expr.c $(HDR) $(EXTHDR)
|
|
|
|
$(TCCX) -DSQLITE_CORE -c $(TOP)/ext/fts3/fts3_expr.c
|
|
|
|
|
2007-08-20 21:37:47 +04:00
|
|
|
fts3_hash.o: $(TOP)/ext/fts3/fts3_hash.c $(HDR) $(EXTHDR)
|
|
|
|
$(TCCX) -DSQLITE_CORE -c $(TOP)/ext/fts3/fts3_hash.c
|
|
|
|
|
|
|
|
fts3_icu.o: $(TOP)/ext/fts3/fts3_icu.c $(HDR) $(EXTHDR)
|
|
|
|
$(TCCX) -DSQLITE_CORE -c $(TOP)/ext/fts3/fts3_icu.c
|
|
|
|
|
2009-11-13 13:36:20 +03:00
|
|
|
fts3_snippet.o: $(TOP)/ext/fts3/fts3_snippet.c $(HDR) $(EXTHDR)
|
|
|
|
$(TCCX) -DSQLITE_CORE -c $(TOP)/ext/fts3/fts3_snippet.c
|
|
|
|
|
2007-08-20 21:37:47 +04:00
|
|
|
fts3_porter.o: $(TOP)/ext/fts3/fts3_porter.c $(HDR) $(EXTHDR)
|
|
|
|
$(TCCX) -DSQLITE_CORE -c $(TOP)/ext/fts3/fts3_porter.c
|
|
|
|
|
|
|
|
fts3_tokenizer.o: $(TOP)/ext/fts3/fts3_tokenizer.c $(HDR) $(EXTHDR)
|
|
|
|
$(TCCX) -DSQLITE_CORE -c $(TOP)/ext/fts3/fts3_tokenizer.c
|
|
|
|
|
|
|
|
fts3_tokenizer1.o: $(TOP)/ext/fts3/fts3_tokenizer1.c $(HDR) $(EXTHDR)
|
|
|
|
$(TCCX) -DSQLITE_CORE -c $(TOP)/ext/fts3/fts3_tokenizer1.c
|
|
|
|
|
2013-04-22 19:30:37 +04:00
|
|
|
fts3_tokenize_vtab.o: $(TOP)/ext/fts3/fts3_tokenize_vtab.c $(HDR) $(EXTHDR)
|
|
|
|
$(TCCX) -DSQLITE_CORE -c $(TOP)/ext/fts3/fts3_tokenize_vtab.c
|
|
|
|
|
2012-05-25 21:50:19 +04:00
|
|
|
fts3_unicode.o: $(TOP)/ext/fts3/fts3_unicode.c $(HDR) $(EXTHDR)
|
|
|
|
$(TCCX) -DSQLITE_CORE -c $(TOP)/ext/fts3/fts3_unicode.c
|
|
|
|
|
|
|
|
fts3_unicode2.o: $(TOP)/ext/fts3/fts3_unicode2.c $(HDR) $(EXTHDR)
|
|
|
|
$(TCCX) -DSQLITE_CORE -c $(TOP)/ext/fts3/fts3_unicode2.c
|
|
|
|
|
2009-11-13 13:36:20 +03:00
|
|
|
fts3_write.o: $(TOP)/ext/fts3/fts3_write.c $(HDR) $(EXTHDR)
|
|
|
|
$(TCCX) -DSQLITE_CORE -c $(TOP)/ext/fts3/fts3_write.c
|
|
|
|
|
2008-05-26 22:41:54 +04:00
|
|
|
rtree.o: $(TOP)/ext/rtree/rtree.c $(HDR) $(EXTHDR)
|
|
|
|
$(TCCX) -DSQLITE_CORE -c $(TOP)/ext/rtree/rtree.c
|
|
|
|
|
2014-08-18 19:08:26 +04:00
|
|
|
sqlite3session.o: $(TOP)/ext/session/sqlite3session.c $(HDR) $(EXTHDR)
|
|
|
|
$(TCCX) -DSQLITE_CORE -c $(TOP)/ext/session/sqlite3session.c
|
|
|
|
|
2007-06-25 18:28:48 +04:00
|
|
|
|
2004-05-22 21:41:58 +04:00
|
|
|
# Rules for building test programs and for running tests
|
|
|
|
#
|
2004-05-31 22:23:07 +04:00
|
|
|
tclsqlite3: $(TOP)/src/tclsqlite.c libsqlite3.a
|
|
|
|
$(TCCX) $(TCL_FLAGS) -DTCLSH=1 -o tclsqlite3 \
|
2004-06-30 12:20:16 +04:00
|
|
|
$(TOP)/src/tclsqlite.c libsqlite3.a $(LIBTCL) $(THREADLIB)
|
2001-09-28 05:34:43 +04:00
|
|
|
|
2013-03-13 16:20:15 +04:00
|
|
|
sqlite3_analyzer.c: sqlite3.c $(TOP)/src/test_stat.c $(TOP)/src/tclsqlite.c \
|
|
|
|
$(TOP)/tool/spaceanal.tcl
|
2011-09-21 20:43:07 +04:00
|
|
|
echo "#define TCLSH 2" > $@
|
|
|
|
cat sqlite3.c $(TOP)/src/test_stat.c $(TOP)/src/tclsqlite.c >> $@
|
|
|
|
echo "static const char *tclsh_main_loop(void){" >> $@
|
|
|
|
echo "static const char *zMainloop = " >> $@
|
|
|
|
$(NAWK) -f $(TOP)/tool/tostr.awk $(TOP)/tool/spaceanal.tcl >> $@
|
|
|
|
echo "; return zMainloop; }" >> $@
|
|
|
|
|
2011-09-21 22:29:49 +04:00
|
|
|
sqlite3_analyzer$(EXE): sqlite3_analyzer.c
|
2011-09-21 20:43:07 +04:00
|
|
|
$(TCCX) $(TCL_FLAGS) sqlite3_analyzer.c -o $@ $(LIBTCL) $(THREADLIB)
|
2007-08-31 21:42:48 +04:00
|
|
|
|
|
|
|
# Rules to build the 'testfixture' application.
|
|
|
|
#
|
2010-07-12 20:47:48 +04:00
|
|
|
TESTFIXTURE_FLAGS = -DSQLITE_TEST=1 -DSQLITE_CRASH_TEST=1
|
2007-08-31 21:42:48 +04:00
|
|
|
TESTFIXTURE_FLAGS += -DSQLITE_SERVER=1 -DSQLITE_PRIVATE="" -DSQLITE_CORE
|
|
|
|
|
|
|
|
testfixture$(EXE): $(TESTSRC2) libsqlite3.a $(TESTSRC) $(TOP)/src/tclsqlite.c
|
2010-07-12 20:47:48 +04:00
|
|
|
$(TCCX) $(TCL_FLAGS) -DTCLSH=1 $(TESTFIXTURE_FLAGS) \
|
2007-08-31 21:42:48 +04:00
|
|
|
$(TESTSRC) $(TESTSRC2) $(TOP)/src/tclsqlite.c \
|
2012-10-19 00:49:26 +04:00
|
|
|
-o testfixture$(EXE) $(LIBTCL) libsqlite3.a $(THREADLIB)
|
2007-08-31 21:42:48 +04:00
|
|
|
|
2013-03-19 19:23:18 +04:00
|
|
|
amalgamation-testfixture$(EXE): sqlite3.c $(TESTSRC) $(TOP)/src/tclsqlite.c \
|
|
|
|
$(TOP)/ext/session/test_session.c
|
2010-07-12 20:47:48 +04:00
|
|
|
$(TCCX) $(TCL_FLAGS) -DTCLSH=1 $(TESTFIXTURE_FLAGS) \
|
2007-08-31 21:42:48 +04:00
|
|
|
$(TESTSRC) $(TOP)/src/tclsqlite.c sqlite3.c \
|
2013-03-19 19:23:18 +04:00
|
|
|
$(TOP)/ext/session/test_session.c \
|
2007-08-31 21:42:48 +04:00
|
|
|
-o testfixture$(EXE) $(LIBTCL) $(THREADLIB)
|
2004-06-22 15:29:02 +04:00
|
|
|
|
2007-11-23 20:31:17 +03:00
|
|
|
fts3-testfixture$(EXE): sqlite3.c fts3amal.c $(TESTSRC) $(TOP)/src/tclsqlite.c
|
2010-07-12 20:47:48 +04:00
|
|
|
$(TCCX) $(TCL_FLAGS) -DTCLSH=1 $(TESTFIXTURE_FLAGS) \
|
2007-11-23 20:31:17 +03:00
|
|
|
-DSQLITE_ENABLE_FTS3=1 \
|
|
|
|
$(TESTSRC) $(TOP)/src/tclsqlite.c sqlite3.c fts3amal.c \
|
|
|
|
-o testfixture$(EXE) $(LIBTCL) $(THREADLIB)
|
|
|
|
|
2005-11-26 03:25:00 +03:00
|
|
|
fulltest: testfixture$(EXE) sqlite3$(EXE)
|
2001-09-28 05:34:43 +04:00
|
|
|
./testfixture$(EXE) $(TOP)/test/all.test
|
|
|
|
|
2007-06-18 16:22:43 +04:00
|
|
|
soaktest: testfixture$(EXE) sqlite3$(EXE)
|
2010-06-15 10:56:37 +04:00
|
|
|
./testfixture$(EXE) $(TOP)/test/all.test -soak=1
|
2007-06-18 16:22:43 +04:00
|
|
|
|
2012-09-13 05:51:02 +04:00
|
|
|
fulltestonly: testfixture$(EXE) sqlite3$(EXE)
|
|
|
|
./testfixture$(EXE) $(TOP)/test/full.test
|
|
|
|
|
2013-06-17 22:20:48 +04:00
|
|
|
queryplantest: testfixture$(EXE) sqlite3$(EXE)
|
|
|
|
./testfixture$(EXE) $(TOP)/test/permutations.test queryplanner
|
|
|
|
|
2004-05-31 22:23:07 +04:00
|
|
|
test: testfixture$(EXE) sqlite3$(EXE)
|
2008-06-25 21:54:53 +04:00
|
|
|
./testfixture$(EXE) $(TOP)/test/veryquick.test
|
2001-09-28 05:34:43 +04:00
|
|
|
|
2010-09-13 16:15:36 +04:00
|
|
|
# The next two rules are used to support the "threadtest" target. Building
|
|
|
|
# threadtest runs a few thread-safety tests that are implemented in C. This
|
|
|
|
# target is invoked by the releasetest.tcl script.
|
|
|
|
#
|
2013-03-13 16:20:15 +04:00
|
|
|
threadtest3$(EXE): sqlite3.o $(TOP)/test/threadtest3.c \
|
|
|
|
$(TOP)/test/tt3_checkpoint.c
|
2010-11-19 12:58:11 +03:00
|
|
|
$(TCCX) -O2 sqlite3.o $(TOP)/test/threadtest3.c \
|
2010-09-13 16:15:36 +04:00
|
|
|
-o threadtest3$(EXE) $(THREADLIB)
|
|
|
|
|
|
|
|
threadtest: threadtest3$(EXE)
|
|
|
|
./threadtest3$(EXE)
|
|
|
|
|
2006-06-14 14:38:02 +04:00
|
|
|
TEST_EXTENSION = $(SHPREFIX)testloadext.$(SO)
|
|
|
|
$(TEST_EXTENSION): $(TOP)/src/test_loadext.c
|
|
|
|
$(MKSHLIB) $(TOP)/src/test_loadext.c -o $(TEST_EXTENSION)
|
|
|
|
|
|
|
|
extensiontest: testfixture$(EXE) $(TEST_EXTENSION)
|
|
|
|
./testfixture$(EXE) $(TOP)/test/loadext.test
|
|
|
|
|
2014-06-30 15:14:26 +04:00
|
|
|
showdb$(EXE): $(TOP)/tool/showdb.c sqlite3.o
|
2013-11-07 22:37:31 +04:00
|
|
|
$(TCC) -DSQLITE_THREADSAFE=0 -DSQLITE_OMIT_LOAD_EXTENSION -o showdb$(EXE) \
|
2014-06-30 15:14:26 +04:00
|
|
|
$(TOP)/tool/showdb.c sqlite3.o $(THREADLIB)
|
|
|
|
|
|
|
|
showstat4$(EXE): $(TOP)/tool/showstat4.c sqlite3.o
|
|
|
|
$(TCC) -DSQLITE_THREADSAFE=0 -DSQLITE_OMIT_LOAD_EXTENSION -o showstat4$(EXE) \
|
|
|
|
$(TOP)/tool/showstat4.c sqlite3.o $(THREADLIB)
|
|
|
|
|
|
|
|
showjournal$(EXE): $(TOP)/tool/showjournal.c sqlite3.o
|
|
|
|
$(TCC) -DSQLITE_THREADSAFE=0 -DSQLITE_OMIT_LOAD_EXTENSION -o showjournal$(EXE) \
|
|
|
|
$(TOP)/tool/showjournal.c sqlite3.o $(THREADLIB)
|
|
|
|
|
|
|
|
showwal$(EXE): $(TOP)/tool/showwal.c sqlite3.o
|
|
|
|
$(TCC) -DSQLITE_THREADSAFE=0 -DSQLITE_OMIT_LOAD_EXTENSION -o showwal$(EXE) \
|
|
|
|
$(TOP)/tool/showwal.c sqlite3.o $(THREADLIB)
|
|
|
|
|
2014-08-18 21:56:31 +04:00
|
|
|
changeset$(EXE): $(TOP)/ext/session/changeset.c sqlite3.o
|
|
|
|
$(TCC) -DSQLITE_THREADSAFE=0 -DSQLITE_OMIT_LOAD_EXTENSION -o changeset$(EXE) \
|
|
|
|
$(TOP)/ext/session/changeset.c sqlite3.o $(THREADLIB)
|
|
|
|
|
2014-07-07 20:07:43 +04:00
|
|
|
fts3view$(EXE): $(TOP)/ext/fts3/tool/fts3view.c sqlite3.o
|
|
|
|
$(TCC) -DSQLITE_THREADSAFE=0 -DSQLITE_OMIT_LOAD_EXTENSION -o fts3view$(EXE) \
|
|
|
|
$(TOP)/ext/fts3/tool/fts3view.c sqlite3.o $(THREADLIB)
|
|
|
|
|
2014-06-30 15:14:26 +04:00
|
|
|
rollback-test$(EXE): $(TOP)/tool/rollback-test.c sqlite3.o
|
|
|
|
$(TCC) -DSQLITE_THREADSAFE=0 -DSQLITE_OMIT_LOAD_EXTENSION -o rollback-test$(EXE) \
|
|
|
|
$(TOP)/tool/rollback-test.c sqlite3.o $(THREADLIB)
|
2013-10-10 21:33:52 +04:00
|
|
|
|
2014-06-18 22:10:12 +04:00
|
|
|
LogEst$(EXE): $(TOP)/tool/logest.c sqlite3.h
|
|
|
|
$(TCC) -o LogEst$(EXE) $(TOP)/tool/logest.c
|
2013-10-10 21:33:52 +04:00
|
|
|
|
2013-11-07 22:37:31 +04:00
|
|
|
wordcount$(EXE): $(TOP)/test/wordcount.c sqlite3.c
|
|
|
|
$(TCC) -DSQLITE_THREADSAFE=0 -DSQLITE_OMIT_LOAD_EXTENSION -o wordcount$(EXE) \
|
|
|
|
$(TOP)/test/wordcount.c sqlite3.c
|
|
|
|
|
2013-11-23 08:16:58 +04:00
|
|
|
speedtest1$(EXE): $(TOP)/test/speedtest1.c sqlite3.o
|
2013-12-24 16:04:24 +04:00
|
|
|
$(TCC) -I. -o speedtest1$(EXE) $(TOP)/test/speedtest1.c sqlite3.o $(THREADLIB)
|
2013-11-23 08:16:58 +04:00
|
|
|
|
2011-07-07 12:19:16 +04:00
|
|
|
# This target will fail if the SQLite amalgamation contains any exported
|
|
|
|
# symbols that do not begin with "sqlite3_". It is run as part of the
|
|
|
|
# releasetest.tcl script.
|
|
|
|
#
|
|
|
|
checksymbols: sqlite3.o
|
|
|
|
nm -g --defined-only sqlite3.o | grep -v " sqlite3_" ; test $$? -ne 0
|
|
|
|
|
2013-05-27 22:37:33 +04:00
|
|
|
# Build the amalgamation-autoconf package.
|
|
|
|
#
|
|
|
|
dist: sqlite3.c
|
|
|
|
TOP=$(TOP) sh $(TOP)/tool/mkautoconfamal.sh
|
|
|
|
|
2007-08-31 21:42:48 +04:00
|
|
|
|
2004-05-22 21:41:58 +04:00
|
|
|
# Standard install and cleanup targets
|
|
|
|
#
|
2004-05-31 22:23:07 +04:00
|
|
|
install: sqlite3 libsqlite3.a sqlite3.h
|
|
|
|
mv sqlite3 /usr/bin
|
|
|
|
mv libsqlite3.a /usr/lib
|
|
|
|
mv sqlite3.h /usr/include
|
2001-09-28 05:34:43 +04:00
|
|
|
|
|
|
|
clean:
|
2011-09-22 04:06:44 +04:00
|
|
|
rm -f *.o sqlite3 sqlite3.exe libsqlite3.a sqlite3.h opcodes.*
|
2011-10-13 22:08:04 +04:00
|
|
|
rm -f lemon lemon.exe lempar.c parse.* sqlite*.tar.gz
|
|
|
|
rm -f mkkeywordhash mkkeywordhash.exe keywordhash.h
|
2001-09-28 05:34:43 +04:00
|
|
|
rm -f $(PUBLISH)
|
|
|
|
rm -f *.da *.bb *.bbg gmon.out
|
2012-03-09 00:00:36 +04:00
|
|
|
rm -rf quota2a quota2b quota2c
|
2007-12-11 22:34:44 +03:00
|
|
|
rm -rf tsrc target_source
|
2006-09-03 02:14:59 +04:00
|
|
|
rm -f testloadext.dll libtestloadext.so
|
2011-09-22 04:06:44 +04:00
|
|
|
rm -f amalgamation-testfixture amalgamation-testfixture.exe
|
|
|
|
rm -f fts3-testfixture fts3-testfixture.exe
|
|
|
|
rm -f testfixture testfixture.exe
|
|
|
|
rm -f threadtest3 threadtest3.exe
|
2014-07-19 01:02:54 +04:00
|
|
|
rm -f LogEst LogEst.exe
|
|
|
|
rm -f fts3view fts3view.exe
|
|
|
|
rm -f rollback-test rollback-test.exe
|
|
|
|
rm -f showdb showdb.exe
|
|
|
|
rm -f showjournal showjournal.exe
|
|
|
|
rm -f showstat4 showstat4.exe
|
|
|
|
rm -f showwal showwal.exe
|
|
|
|
rm -f speedtest1 speedtest1.exe
|
|
|
|
rm -f wordcount wordcount.exe
|
2013-10-12 03:01:18 +04:00
|
|
|
rm -f sqlite3.c sqlite3-*.c fts?amal.c tclsqlite3.c
|
2013-03-29 23:52:04 +04:00
|
|
|
rm -f sqlite3rc.h
|
|
|
|
rm -f shell.c sqlite3ext.h
|
2011-09-22 04:06:44 +04:00
|
|
|
rm -f sqlite3_analyzer sqlite3_analyzer.exe sqlite3_analyzer.c
|
2012-10-20 13:35:57 +04:00
|
|
|
rm -f sqlite-*-output.vsix
|
2013-04-10 07:06:43 +04:00
|
|
|
rm -f mptester mptester.exe
|