2002-08-14 00:45:39 +04:00
|
|
|
#!/usr/make
|
|
|
|
#
|
|
|
|
# Makefile for SQLITE
|
|
|
|
#
|
|
|
|
# This is a template makefile for SQLite. Most people prefer to
|
|
|
|
# use the autoconf generated "configure" script to generate the
|
|
|
|
# makefile automatically. But that does not work for everybody
|
|
|
|
# and in every situation. If you are having problems with the
|
|
|
|
# "configure" script, you might want to try this makefile as an
|
|
|
|
# alternative. Create a copy of this file, edit the parameters
|
|
|
|
# below and type "make".
|
|
|
|
#
|
|
|
|
|
|
|
|
#### The toplevel directory of the source tree. This is the directory
|
|
|
|
# that contains this "Makefile.in" and the "configure.in" script.
|
|
|
|
#
|
|
|
|
TOP = ../sqlite
|
|
|
|
|
|
|
|
#### C Compiler and options for use in building executables that
|
|
|
|
# will run on the platform that is doing the build.
|
|
|
|
#
|
2019-09-03 19:23:41 +03:00
|
|
|
BCC = gcc -g -O0
|
2002-08-14 00:45:39 +04:00
|
|
|
#BCC = /opt/ancic/bin/c89 -0
|
|
|
|
|
|
|
|
#### If the target operating system supports the "usleep()" system
|
|
|
|
# call, then define the HAVE_USLEEP macro for all C modules.
|
|
|
|
#
|
|
|
|
#USLEEP =
|
|
|
|
USLEEP = -DHAVE_USLEEP=1
|
|
|
|
|
|
|
|
#### If you want the SQLite library to be safe for use within a
|
|
|
|
# multi-threaded program, then define the following macro
|
|
|
|
# appropriately:
|
|
|
|
#
|
|
|
|
#THREADSAFE = -DTHREADSAFE=1
|
|
|
|
THREADSAFE = -DTHREADSAFE=0
|
|
|
|
|
|
|
|
#### Specify any extra linker options needed to make the library
|
|
|
|
# thread safe
|
|
|
|
#
|
2019-09-03 19:23:41 +03:00
|
|
|
THREADLIB = -lpthread -lm -ldl
|
|
|
|
#THREADLIB =
|
2002-08-14 00:45:39 +04:00
|
|
|
|
2006-01-23 21:06:52 +03:00
|
|
|
#### Specify any extra libraries needed to access required functions.
|
|
|
|
#
|
|
|
|
#TLIBS = -lrt # fdatasync on Solaris 8
|
|
|
|
TLIBS =
|
|
|
|
|
2004-06-09 18:01:51 +04:00
|
|
|
#### Leave SQLITE_DEBUG undefined for maximum speed. Use SQLITE_DEBUG=1
|
|
|
|
# to check for memory leaks. Use SQLITE_DEBUG=2 to print a log of all
|
2002-08-14 00:45:39 +04:00
|
|
|
# malloc()s and free()s in order to track down memory leaks.
|
|
|
|
#
|
|
|
|
# SQLite uses some expensive assert() statements in the inner loop.
|
|
|
|
# You can make the library go almost twice as fast if you compile
|
|
|
|
# with -DNDEBUG=1
|
|
|
|
#
|
2019-09-03 19:23:41 +03:00
|
|
|
OPTS += -DSQLITE_DEBUG=1
|
|
|
|
OPTS += -DSQLITE_ENABLE_WHERETRACE
|
|
|
|
OPTS += -DSQLITE_ENABLE_SELECTTRACE
|
2002-08-14 00:45:39 +04:00
|
|
|
|
|
|
|
#### The suffix to add to executable files. ".exe" for windows.
|
|
|
|
# Nothing for unix.
|
|
|
|
#
|
|
|
|
#EXE = .exe
|
|
|
|
EXE =
|
|
|
|
|
|
|
|
#### C Compile 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.
|
|
|
|
#
|
2019-09-03 19:23:41 +03:00
|
|
|
TCC = gcc -O0
|
2002-08-14 00:45:39 +04:00
|
|
|
#TCC = gcc -g -O0 -Wall
|
|
|
|
#TCC = gcc -g -O0 -Wall -fprofile-arcs -ftest-coverage
|
|
|
|
#TCC = /opt/mingw/bin/i386-mingw32-gcc -O6
|
|
|
|
#TCC = /opt/ansic/bin/c89 -O +z -Wl,-a,archive
|
|
|
|
|
|
|
|
#### Tools used to build a static library.
|
|
|
|
#
|
|
|
|
AR = ar cr
|
|
|
|
#AR = /opt/mingw/bin/i386-mingw32-ar cr
|
|
|
|
RANLIB = ranlib
|
|
|
|
#RANLIB = /opt/mingw/bin/i386-mingw32-ranlib
|
|
|
|
|
2006-06-14 14:38:02 +04:00
|
|
|
MKSHLIB = gcc -shared
|
|
|
|
SO = so
|
|
|
|
SHPREFIX = lib
|
|
|
|
# SO = dll
|
|
|
|
# SHPREFIX =
|
|
|
|
|
2002-08-14 00:45:39 +04:00
|
|
|
#### Extra compiler options needed for programs that use the TCL library.
|
|
|
|
#
|
2019-09-03 19:23:41 +03:00
|
|
|
TCL_FLAGS = -I/home/drh/tcl/include/tcl8.6
|
2002-08-14 00:45:39 +04:00
|
|
|
|
|
|
|
#### Linker options needed to link against the TCL library.
|
|
|
|
#
|
|
|
|
#LIBTCL = -ltcl -lm -ldl
|
2019-09-03 19:23:41 +03:00
|
|
|
LIBTCL = /home/drh/tcl/lib/libtcl8.6.a -lm -lpthread -ldl -lz
|
2002-08-14 00:45:39 +04:00
|
|
|
|
2007-11-13 00:09:10 +03:00
|
|
|
#### Additional objects for SQLite library when TCL support is enabled.
|
|
|
|
#TCLOBJ =
|
|
|
|
TCLOBJ = tclsqlite.o
|
|
|
|
|
2002-08-14 00:45:39 +04:00
|
|
|
#### Compiler options needed for programs that use the readline() library.
|
|
|
|
#
|
2005-03-11 21:06:40 +03:00
|
|
|
READLINE_FLAGS =
|
|
|
|
#READLINE_FLAGS = -DHAVE_READLINE=1 -I/usr/include/readline
|
2002-08-14 00:45:39 +04:00
|
|
|
|
|
|
|
#### Linker options needed by programs using readline() must link against.
|
|
|
|
#
|
2005-03-11 21:06:40 +03:00
|
|
|
LIBREADLINE =
|
|
|
|
#LIBREADLINE = -static -lreadline -ltermcap
|
2002-08-14 00:45:39 +04:00
|
|
|
|
|
|
|
# You should not have to change anything below this line
|
|
|
|
###############################################################################
|
|
|
|
include $(TOP)/main.mk
|