2 # nmake Makefile for SQLite
5 # The toplevel directory of the source tree. This is the directory
6 # that contains this "Makefile.msc".
10 # Set this non-0 to create and use the SQLite amalgamation file.
12 !IFNDEF USE_AMALGAMATION
16 # Set this non-0 to use the International Components for Unicode (ICU).
22 # Set this non-0 to dynamically link to the MSVC runtime library.
28 # Set this non-0 to attempt setting the native compiler automatically
29 # for cross-compiling the command line tools needed during the compilation
36 # Set this non-0 to use the native libraries paths for cross-compiling
37 # the command line tools needed during the compilation process.
39 !IFNDEF USE_NATIVE_LIBPATHS
40 USE_NATIVE_LIBPATHS = 0
43 # Set this 0 to skip the compiling and embedding of version resources.
49 # Set this non-0 to compile binaries suitable for the WinRT environment.
50 # This setting does not apply to any binaries that require Tcl to operate
51 # properly (i.e. the text fixture, etc).
57 # Set this non-0 to skip attempting to look for and/or link with the Tcl
64 # Set this to non-0 to create and use PDBs.
70 # Set this to non-0 to use the SQLite debugging heap subsystem.
76 # Set this to non-0 to use the Win32 native heap subsystem.
82 # Set this to one of the following values to enable various debugging
83 # features. Each level includes the debugging options from the previous
84 # levels. Currently, the recognized values for DEBUG are:
86 # 0 == NDEBUG: Disables assert() and other runtime diagnostics.
87 # 1 == Disables NDEBUG and all optimizations and then enables PDBs.
88 # 2 == SQLITE_DEBUG: Enables various diagnostics messages and code.
89 # 3 == SQLITE_WIN32_MALLOC_VALIDATE: Validate the Win32 native heap per call.
90 # 4 == SQLITE_DEBUG_OS_TRACE: Enables output from the OSTRACE() macros.
91 # 5 == SQLITE_ENABLE_IOTRACE: Enables output from the IOTRACE() macros.
97 # Check for the predefined command macro CC. This should point to the compiler
98 # binary for the target platform. If it is not defined, simply define it to
99 # the legacy default value 'cl.exe'.
105 # Check for the command macro LD. This should point to the linker binary for
106 # the target platform. If it is not defined, simply define it to the legacy
107 # default value 'link.exe'.
113 # Check for the predefined command macro RC. This should point to the resource
114 # compiler binary for the target platform. If it is not defined, simply define
115 # it to the legacy default value 'rc.exe'.
121 # Check for the command macro NCC. This should point to the compiler binary
122 # for the platform the compilation process is taking place on. If it is not
123 # defined, simply define it to have the same value as the CC macro. When
124 # cross-compiling, it is suggested that this macro be modified via the command
125 # line (since nmake itself does not provide a built-in method to guess it).
126 # For example, to use the x86 compiler when cross-compiling for x64, a command
127 # line similar to the following could be used (all on one line):
129 # nmake /f Makefile.msc sqlite3.dll
130 # XCOMPILE=1 USE_NATIVE_LIBPATHS=1
132 # Alternatively, the full path and file name to the compiler binary for the
133 # platform the compilation process is taking place may be specified (all on
136 # nmake /f Makefile.msc sqlite3.dll
137 # "NCC=""%VCINSTALLDIR%\bin\cl.exe"""
138 # USE_NATIVE_LIBPATHS=1
142 !ELSEIF $(XCOMPILE)!=0
143 NCC = "$(VCINSTALLDIR)\bin\cl.exe"
149 # Check for the MSVC runtime library path macro. Othertise, this
150 # value will default to the 'lib' directory underneath the MSVC
151 # installation directory.
154 NCRTLIBPATH = $(VCINSTALLDIR)\lib
157 NCRTLIBPATH = $(NCRTLIBPATH:\\=\)
159 # Check for the Platform SDK library path macro. Othertise, this
160 # value will default to the 'lib' directory underneath the Windows
161 # SDK installation directory (the environment variable used appears
162 # to be available when using Visual C++ 2008 or later via the
166 NSDKLIBPATH = $(WINDOWSSDKDIR)\lib
169 NSDKLIBPATH = $(NSDKLIBPATH:\\=\)
171 # C compiler and options for use in building executables that
172 # will run on the platform that is doing the build.
176 # Check if the native library paths should be used when compiling
177 # the command line tools used during the compilation process. If
178 # so, set the necessary macro now.
180 !IF $(USE_NATIVE_LIBPATHS)!=0
181 NLTLIBPATHS = "/LIBPATH:$(NCRTLIBPATH)" "/LIBPATH:$(NSDKLIBPATH)"
184 # C compiler and options for use in building executables that
185 # will run on the target platform. (BCC and TCC are usually the
186 # same unless your are cross-compiling.)
188 TCC = $(CC) -W3 -DSQLITE_OS_WIN=1 -I$(TOP) -I$(TOP)\src -fp:precise
189 RCC = $(RC) -DSQLITE_OS_WIN=1 -I$(TOP) -I$(TOP)\src
191 # When compiling the library for use in the WinRT environment,
192 # the following compile-time options must be used as well to
193 # disable use of Win32 APIs that are not available and to enable
194 # use of Win32 APIs that are specific to Windows 8 and/or WinRT.
197 TCC = $(TCC) -DSQLITE_OS_WINRT=1
198 RCC = $(RCC) -DSQLITE_OS_WINRT=1
199 TCC = $(TCC) -DWINAPI_FAMILY=WINAPI_FAMILY_APP
200 RCC = $(RCC) -DWINAPI_FAMILY=WINAPI_FAMILY_APP
203 # Also, we need to dynamically link to the correct MSVC runtime
204 # when compiling for WinRT (e.g. debug or release) OR if the
205 # USE_CRT_DLL option is set to force dynamically linking to the
206 # MSVC runtime library.
208 !IF $(FOR_WINRT)!=0 || $(USE_CRT_DLL)!=0
226 # The mksqlite3c.tcl and mksqlite3h.tcl scripts will pull in
227 # any extension header files by default. For non-amalgamation
228 # builds, we need to make sure the compiler can find these.
230 !IF $(USE_AMALGAMATION)==0
231 TCC = $(TCC) -I$(TOP)\ext\fts3
232 RCC = $(RCC) -I$(TOP)\ext\fts3
233 TCC = $(TCC) -I$(TOP)\ext\rtree
234 RCC = $(RCC) -I$(TOP)\ext\rtree
237 # Define -DNDEBUG to compile without debugging (i.e., for production usage)
238 # Omitting the define will cause extra debugging code to be inserted and
239 # includes extra comments when "EXPLAIN stmt" is used.
242 TCC = $(TCC) -DNDEBUG
243 BCC = $(BCC) -DNDEBUG
244 RCC = $(RCC) -DNDEBUG
248 TCC = $(TCC) -DSQLITE_DEBUG
249 RCC = $(RCC) -DSQLITE_DEBUG
253 TCC = $(TCC) -DSQLITE_DEBUG_OS_TRACE=1
254 RCC = $(RCC) -DSQLITE_DEBUG_OS_TRACE=1
258 TCC = $(TCC) -DSQLITE_ENABLE_IOTRACE
259 RCC = $(RCC) -DSQLITE_ENABLE_IOTRACE
263 # Prevent warnings about "insecure" MSVC runtime library functions
266 TCC = $(TCC) -D_CRT_SECURE_NO_DEPRECATE -D_CRT_SECURE_NO_WARNINGS
267 BCC = $(BCC) -D_CRT_SECURE_NO_DEPRECATE -D_CRT_SECURE_NO_WARNINGS
268 RCC = $(RCC) -D_CRT_SECURE_NO_DEPRECATE -D_CRT_SECURE_NO_WARNINGS
271 # Prevent warnings about "deprecated" POSIX functions being used.
273 TCC = $(TCC) -D_CRT_NONSTDC_NO_DEPRECATE -D_CRT_NONSTDC_NO_WARNINGS
274 BCC = $(BCC) -D_CRT_NONSTDC_NO_DEPRECATE -D_CRT_NONSTDC_NO_WARNINGS
275 RCC = $(RCC) -D_CRT_NONSTDC_NO_DEPRECATE -D_CRT_NONSTDC_NO_WARNINGS
278 # Use the SQLite debugging heap subsystem?
281 TCC = $(TCC) -DSQLITE_MEMDEBUG=1
282 RCC = $(RCC) -DSQLITE_MEMDEBUG=1
285 # Use native Win32 heap subsystem instead of malloc/free?
287 !ELSEIF $(WIN32HEAP)!=0
288 TCC = $(TCC) -DSQLITE_WIN32_MALLOC=1
289 RCC = $(RCC) -DSQLITE_WIN32_MALLOC=1
292 # Validate the heap on every call into the native Win32 heap subsystem?
295 TCC = $(TCC) -DSQLITE_WIN32_MALLOC_VALIDATE=1
296 RCC = $(RCC) -DSQLITE_WIN32_MALLOC_VALIDATE=1
300 # The locations of the Tcl header and library files. Also, the library that
301 # non-stubs enabled programs using Tcl must link against. These variables
302 # (TCLINCDIR, TCLLIBDIR, and LIBTCL) may be overridden via the environment
303 # prior to running nmake in order to match the actual installed location and
304 # version on this machine.
307 TCLINCDIR = c:\tcl\include
311 TCLLIBDIR = c:\tcl\lib
318 # The locations of the ICU header and library files. These variables
319 # (ICUINCDIR, ICULIBDIR, and LIBICU) may be overridden via the environment
320 # prior to running nmake in order to match the actual installed location on
324 ICUINCDIR = c:\icu\include
328 ICULIBDIR = c:\icu\lib
332 LIBICU = icuuc.lib icuin.lib
335 # This is the command to use for tclsh - normally just "tclsh", but we may
336 # know the specific version we want to use. This variable (TCLSH_CMD) may be
337 # overridden via the environment prior to running nmake in order to select a
338 # specific Tcl shell to use.
344 # Compiler options needed for programs that use the readline() library.
346 READLINE_FLAGS = -DHAVE_READLINE=0
348 # The library that programs using readline() must link against.
352 # Should the database engine be compiled threadsafe
354 TCC = $(TCC) -DSQLITE_THREADSAFE=1
355 RCC = $(RCC) -DSQLITE_THREADSAFE=1
357 # Do threads override each others locks by default (1), or do we test (-1)
359 TCC = $(TCC) -DSQLITE_THREAD_OVERRIDE_LOCK=-1
360 RCC = $(RCC) -DSQLITE_THREAD_OVERRIDE_LOCK=-1
362 # Any target libraries which libsqlite must be linked against
368 # Flags controlling use of the in memory btree implementation
370 # SQLITE_TEMP_STORE is 0 to force temporary tables to be in a file, 1 to
371 # default to file, 2 to default to memory, and 3 to force temporary
372 # tables to always be in memory.
374 TCC = $(TCC) -DSQLITE_TEMP_STORE=1
375 RCC = $(RCC) -DSQLITE_TEMP_STORE=1
377 # Enable/disable loadable extensions, and other optional features
378 # based on configuration. (-DSQLITE_OMIT*, -DSQLITE_ENABLE*).
379 # The same set of OMIT and ENABLE flags should be passed to the
380 # LEMON parser generator and the mkkeywordhash tool as well.
382 # BEGIN standard options
383 OPT_FEATURE_FLAGS = $(OPT_FEATURE_FLAGS) -DSQLITE_ENABLE_FTS3=1
384 OPT_FEATURE_FLAGS = $(OPT_FEATURE_FLAGS) -DSQLITE_ENABLE_RTREE=1
385 OPT_FEATURE_FLAGS = $(OPT_FEATURE_FLAGS) -DSQLITE_ENABLE_COLUMN_METADATA=1
386 # END standard options
388 # BEGIN required Windows option
389 OPT_FEATURE_FLAGS = $(OPT_FEATURE_FLAGS) -DSQLITE_MAX_TRIGGER_DEPTH=100
390 # END required Windows option
392 TCC = $(TCC) $(OPT_FEATURE_FLAGS)
393 RCC = $(RCC) $(OPT_FEATURE_FLAGS)
395 # Add in any optional parameters specified on the make commane line
396 # ie. make "OPTS=-DSQLITE_ENABLE_FOO=1 -DSQLITE_OMIT_FOO=1".
400 # If symbols are enabled, enable PDBs.
401 # If debugging is enabled, disable all optimizations and enable PDBs.
403 TCC = $(TCC) -Od -D_DEBUG
404 BCC = $(BCC) -Od -D_DEBUG
405 RCC = $(RCC) -D_DEBUG
411 !IF $(DEBUG)>0 || $(SYMBOLS)!=0
416 # If ICU support is enabled, add the compiler options for it.
418 TCC = $(TCC) -DSQLITE_ENABLE_ICU=1
419 RCC = $(RCC) -DSQLITE_ENABLE_ICU=1
420 TCC = $(TCC) -I$(TOP)\ext\icu
421 RCC = $(RCC) -I$(TOP)\ext\icu
422 TCC = $(TCC) -I$(ICUINCDIR)
423 RCC = $(RCC) -I$(ICUINCDIR)
426 # Command line prefixes for compiling code, compiling resources,
428 LTCOMPILE = $(TCC) -Fo$@
429 LTRCOMPILE = $(RCC) -r
431 LTLINK = $(TCC) -Fe$@
433 # If a platform was set, force the linker to target that.
434 # Note that the vcvars*.bat family of batch files typically
435 # set this for you. Otherwise, the linker will attempt
436 # to deduce the binary type based on the object files.
438 LTLINKOPTS = /MACHINE:$(PLATFORM)
439 LTLIBOPTS = /MACHINE:$(PLATFORM)
442 # When compiling for use in the WinRT environment, the following
443 # linker option must be used to mark the executable as runnable
444 # only in the context of an application container.
447 LTLINKOPTS = $(LTLINKOPTS) /APPCONTAINER
450 # If either debugging or symbols are enabled, enable PDBs.
451 !IF $(DEBUG)>0 || $(SYMBOLS)!=0
455 # Start with the Tcl related linker options.
457 LTLIBPATHS = /LIBPATH:$(TCLLIBDIR)
461 # If ICU support is enabled, add the linker options for it.
463 LTLIBPATHS = $(LTLIBPATHS) /LIBPATH:$(ICULIBDIR)
464 LTLIBS = $(LTLIBS) $(LIBICU)
467 # nawk compatible awk.
470 # You should not have to change anything below this line
471 ###############################################################################
473 # Object files for the SQLite library (non-amalgamation).
475 LIBOBJS0 = alter.lo analyze.lo attach.lo auth.lo \
476 backup.lo bitvec.lo btmutex.lo btree.lo build.lo \
477 callback.lo complete.lo ctime.lo date.lo delete.lo \
478 expr.lo fault.lo fkey.lo \
479 fts3.lo fts3_aux.lo fts3_expr.lo fts3_hash.lo fts3_icu.lo \
480 fts3_porter.lo fts3_snippet.lo fts3_tokenizer.lo fts3_tokenizer1.lo \
481 fts3_tokenize_vtab.lo fts3_unicode.lo fts3_unicode2.lo fts3_write.lo \
482 func.lo global.lo hash.lo \
483 icu.lo insert.lo journal.lo legacy.lo loadext.lo \
484 main.lo malloc.lo mem0.lo mem1.lo mem2.lo mem3.lo mem5.lo \
486 mutex.lo mutex_noop.lo mutex_unix.lo mutex_w32.lo \
487 notify.lo opcodes.lo os.lo os_unix.lo os_win.lo \
488 pager.lo parse.lo pcache.lo pcache1.lo pragma.lo prepare.lo printf.lo \
489 random.lo resolve.lo rowset.lo rtree.lo select.lo status.lo \
490 table.lo tokenize.lo trigger.lo \
491 update.lo util.lo vacuum.lo \
492 vdbe.lo vdbeapi.lo vdbeaux.lo vdbeblob.lo vdbemem.lo vdbesort.lo \
493 vdbetrace.lo wal.lo walker.lo where.lo utf.lo vtab.lo
495 # Object files for the amalgamation.
497 LIBOBJS1 = sqlite3.lo
499 # Determine the real value of LIBOBJ based on the 'configure' script
501 !IF $(USE_AMALGAMATION)==0
507 # Determine if embedded resource compilation and usage are enabled.
510 LIBRESOBJS = sqlite3res.lo
515 # All of the source code files.
519 $(TOP)\src\analyze.c \
520 $(TOP)\src\attach.c \
522 $(TOP)\src\backup.c \
523 $(TOP)\src\bitvec.c \
524 $(TOP)\src\btmutex.c \
527 $(TOP)\src\btreeInt.h \
529 $(TOP)\src\callback.c \
530 $(TOP)\src\complete.c \
533 $(TOP)\src\delete.c \
538 $(TOP)\src\global.c \
541 $(TOP)\src\hwtime.h \
542 $(TOP)\src\insert.c \
543 $(TOP)\src\journal.c \
544 $(TOP)\src\legacy.c \
545 $(TOP)\src\loadext.c \
547 $(TOP)\src\malloc.c \
553 $(TOP)\src\memjournal.c \
556 $(TOP)\src\mutex_noop.c \
557 $(TOP)\src\mutex_unix.c \
558 $(TOP)\src\mutex_w32.c \
559 $(TOP)\src\notify.c \
562 $(TOP)\src\os_common.h \
563 $(TOP)\src\os_unix.c \
564 $(TOP)\src\os_win.c \
568 $(TOP)\src\pcache.c \
569 $(TOP)\src\pcache.h \
570 $(TOP)\src\pcache1.c \
571 $(TOP)\src\pragma.c \
572 $(TOP)\src\prepare.c \
573 $(TOP)\src\printf.c \
574 $(TOP)\src\random.c \
575 $(TOP)\src\resolve.c \
576 $(TOP)\src\rowset.c \
577 $(TOP)\src\select.c \
578 $(TOP)\src\status.c \
580 $(TOP)\src\sqlite.h.in \
581 $(TOP)\src\sqlite3ext.h \
582 $(TOP)\src\sqliteInt.h \
583 $(TOP)\src\sqliteLimit.h \
585 $(TOP)\src\tclsqlite.c \
586 $(TOP)\src\tokenize.c \
587 $(TOP)\src\trigger.c \
589 $(TOP)\src\update.c \
591 $(TOP)\src\vacuum.c \
594 $(TOP)\src\vdbeapi.c \
595 $(TOP)\src\vdbeaux.c \
596 $(TOP)\src\vdbeblob.c \
597 $(TOP)\src\vdbemem.c \
598 $(TOP)\src\vdbesort.c \
599 $(TOP)\src\vdbetrace.c \
600 $(TOP)\src\vdbeInt.h \
604 $(TOP)\src\walker.c \
607 # Source code for extensions
610 $(TOP)\ext\fts1\fts1.c \
611 $(TOP)\ext\fts1\fts1.h \
612 $(TOP)\ext\fts1\fts1_hash.c \
613 $(TOP)\ext\fts1\fts1_hash.h \
614 $(TOP)\ext\fts1\fts1_porter.c \
615 $(TOP)\ext\fts1\fts1_tokenizer.h \
616 $(TOP)\ext\fts1\fts1_tokenizer1.c
618 $(TOP)\ext\fts2\fts2.c \
619 $(TOP)\ext\fts2\fts2.h \
620 $(TOP)\ext\fts2\fts2_hash.c \
621 $(TOP)\ext\fts2\fts2_hash.h \
622 $(TOP)\ext\fts2\fts2_icu.c \
623 $(TOP)\ext\fts2\fts2_porter.c \
624 $(TOP)\ext\fts2\fts2_tokenizer.h \
625 $(TOP)\ext\fts2\fts2_tokenizer.c \
626 $(TOP)\ext\fts2\fts2_tokenizer1.c
628 $(TOP)\ext\fts3\fts3.c \
629 $(TOP)\ext\fts3\fts3.h \
630 $(TOP)\ext\fts3\fts3Int.h \
631 $(TOP)\ext\fts3\fts3_aux.c \
632 $(TOP)\ext\fts3\fts3_expr.c \
633 $(TOP)\ext\fts3\fts3_hash.c \
634 $(TOP)\ext\fts3\fts3_hash.h \
635 $(TOP)\ext\fts3\fts3_icu.c \
636 $(TOP)\ext\fts3\fts3_porter.c \
637 $(TOP)\ext\fts3\fts3_snippet.c \
638 $(TOP)\ext\fts3\fts3_tokenizer.h \
639 $(TOP)\ext\fts3\fts3_tokenizer.c \
640 $(TOP)\ext\fts3\fts3_tokenizer1.c \
641 $(TOP)\ext\fts3\fts3_tokenize_vtab.c \
642 $(TOP)\ext\fts3\fts3_unicode.c \
643 $(TOP)\ext\fts3\fts3_unicode2.c \
644 $(TOP)\ext\fts3\fts3_write.c
646 $(TOP)\ext\icu\sqliteicu.h \
649 $(TOP)\ext\rtree\rtree.h \
650 $(TOP)\ext\rtree\rtree.c
653 # Generated source code files
663 # Source code to the test files.
675 $(TOP)\src\test_autoext.c \
676 $(TOP)\src\test_async.c \
677 $(TOP)\src\test_backup.c \
678 $(TOP)\src\test_btree.c \
679 $(TOP)\src\test_config.c \
680 $(TOP)\src\test_demovfs.c \
681 $(TOP)\src\test_devsym.c \
682 $(TOP)\src\test_fs.c \
683 $(TOP)\src\test_func.c \
684 $(TOP)\src\test_hexio.c \
685 $(TOP)\src\test_init.c \
686 $(TOP)\src\test_intarray.c \
687 $(TOP)\src\test_journal.c \
688 $(TOP)\src\test_malloc.c \
689 $(TOP)\src\test_multiplex.c \
690 $(TOP)\src\test_mutex.c \
691 $(TOP)\src\test_onefile.c \
692 $(TOP)\src\test_osinst.c \
693 $(TOP)\src\test_pcache.c \
694 $(TOP)\src\test_quota.c \
695 $(TOP)\src\test_rtree.c \
696 $(TOP)\src\test_schema.c \
697 $(TOP)\src\test_server.c \
698 $(TOP)\src\test_superlock.c \
699 $(TOP)\src\test_syscall.c \
700 $(TOP)\src\test_stat.c \
701 $(TOP)\src\test_tclvar.c \
702 $(TOP)\src\test_thread.c \
703 $(TOP)\src\test_vfs.c \
704 $(TOP)\src\test_wsd.c \
705 $(TOP)\ext\fts3\fts3_term.c \
706 $(TOP)\ext\fts3\fts3_test.c
708 # Statically linked extensions
711 $(TOP)\ext\misc\amatch.c \
712 $(TOP)\ext\misc\closure.c \
713 $(TOP)\ext\misc\fuzzer.c \
714 $(TOP)\ext\misc\ieee754.c \
715 $(TOP)\ext\misc\nextchar.c \
716 $(TOP)\ext\misc\regexp.c \
717 $(TOP)\ext\misc\spellfix.c \
718 $(TOP)\ext\misc\wholenumber.c
721 # Source code to the library files needed by the test fixture
724 $(TOP)\src\attach.c \
725 $(TOP)\src\backup.c \
726 $(TOP)\src\bitvec.c \
733 $(TOP)\src\insert.c \
738 $(TOP)\src\os_unix.c \
739 $(TOP)\src\os_win.c \
741 $(TOP)\src\pragma.c \
742 $(TOP)\src\prepare.c \
743 $(TOP)\src\printf.c \
744 $(TOP)\src\random.c \
745 $(TOP)\src\pcache.c \
746 $(TOP)\src\pcache1.c \
747 $(TOP)\src\select.c \
748 $(TOP)\src\tokenize.c \
751 $(TOP)\src\vdbeapi.c \
752 $(TOP)\src\vdbeaux.c \
754 $(TOP)\src\vdbemem.c \
755 $(TOP)\src\vdbesort.c \
756 $(TOP)\src\vdbetrace.c \
759 $(TOP)\ext\fts3\fts3.c \
760 $(TOP)\ext\fts3\fts3_aux.c \
761 $(TOP)\ext\fts3\fts3_expr.c \
762 $(TOP)\ext\fts3\fts3_tokenizer.c \
763 $(TOP)\ext\fts3\fts3_tokenize_vtab.c \
764 $(TOP)\ext\fts3\fts3_unicode.c \
765 $(TOP)\ext\fts3\fts3_unicode2.c \
766 $(TOP)\ext\fts3\fts3_write.c \
767 $(TOP)\ext\async\sqlite3async.c
769 # Header files used by all library source files.
773 $(TOP)\src\btreeInt.h \
775 $(TOP)\src\hwtime.h \
780 $(TOP)\src\os_common.h \
782 $(TOP)\src\pcache.h \
785 $(TOP)\src\sqlite3ext.h \
786 $(TOP)\src\sqliteInt.h \
787 $(TOP)\src\sqliteLimit.h \
791 # Header files used by extensions
794 $(TOP)\ext\fts1\fts1.h \
795 $(TOP)\ext\fts1\fts1_hash.h \
796 $(TOP)\ext\fts1\fts1_tokenizer.h
798 $(TOP)\ext\fts2\fts2.h \
799 $(TOP)\ext\fts2\fts2_hash.h \
800 $(TOP)\ext\fts2\fts2_tokenizer.h
802 $(TOP)\ext\fts3\fts3.h \
803 $(TOP)\ext\fts3\fts3Int.h \
804 $(TOP)\ext\fts3\fts3_hash.h \
805 $(TOP)\ext\fts3\fts3_tokenizer.h
807 $(TOP)\ext\rtree\rtree.h
809 $(TOP)\ext\icu\sqliteicu.h
811 $(TOP)\ext\rtree\sqlite3rtree.h
813 # This is the default Makefile target. The objects listed here
814 # are what get build when you type just "make" with no arguments.
816 all: dll libsqlite3.lib sqlite3.exe libtclsqlite3.lib
818 libsqlite3.lib: $(LIBOBJ)
819 $(LTLIB) $(LTLIBOPTS) /OUT:$@ $(LIBOBJ) $(TLIBS)
821 libtclsqlite3.lib: tclsqlite.lo libsqlite3.lib
822 $(LTLIB) $(LTLIBOPTS) $(LTLIBPATHS) /OUT:$@ tclsqlite.lo libsqlite3.lib $(LIBTCL:tcl=tclstub) $(TLIBS)
824 sqlite3.exe: $(TOP)\src\shell.c libsqlite3.lib $(LIBRESOBJS) sqlite3.h
825 $(LTLINK) $(READLINE_FLAGS) \
827 /link $(LTLINKOPTS) $(LTLIBPATHS) libsqlite3.lib $(LIBRESOBJS) $(LIBREADLINE) $(LTLIBS) $(TLIBS)
829 mptester.exe: $(TOP)\mptest\mptest.c libsqlite3.lib $(LIBRESOBJS) sqlite3.h
830 $(LTLINK) $(TOP)\mptest\mptest.c \
831 /link $(LTLINKOPTS) $(LTLIBPATHS) libsqlite3.lib $(LIBRESOBJS) $(LIBREADLINE) $(LTLIBS) $(TLIBS)
833 # This target creates a directory named "tsrc" and fills it with
834 # copies of all of the C source code and header files needed to
835 # build on the target system. Some of the C source code and header
836 # files are automatically generated. This target takes care of
837 # all that automatic generation.
839 .target_source: $(SRC) $(TOP)\tool\vdbe-compress.tcl
842 for %i in ($(SRC)) do copy /Y %i tsrc
843 del /Q tsrc\sqlite.h.in tsrc\parse.y
844 $(TCLSH_CMD) $(TOP)\tool\vdbe-compress.tcl < tsrc\vdbe.c > vdbe.new
845 move vdbe.new tsrc\vdbe.c
846 echo > .target_source
848 sqlite3.c: .target_source $(TOP)\tool\mksqlite3c.tcl
849 $(TCLSH_CMD) $(TOP)\tool\mksqlite3c.tcl
851 copy tsrc\sqlite3ext.h .
853 sqlite3-all.c: sqlite3.c $(TOP)\tool\split-sqlite3c.tcl
854 $(TCLSH_CMD) $(TOP)\tool\split-sqlite3c.tcl
856 # Rule to build the amalgamation
858 sqlite3.lo: sqlite3.c
859 $(LTCOMPILE) -c sqlite3.c
861 # Rules to build the LEMON compiler generator
863 lempar.c: $(TOP)\src\lempar.c
864 copy $(TOP)\src\lempar.c .
866 lemon.exe: $(TOP)\tool\lemon.c lempar.c
867 $(BCC) -Daccess=_access -Fe$@ $(TOP)\tool\lemon.c /link $(NLTLIBPATHS)
869 # Rules to build individual *.lo files from generated *.c files. This
875 parse.lo: parse.c $(HDR)
876 $(LTCOMPILE) -c parse.c
878 opcodes.lo: opcodes.c
879 $(LTCOMPILE) -c opcodes.c
881 # Rule to build the Win32 resources object file.
884 $(LIBRESOBJS): $(TOP)\src\sqlite3.rc $(HDR)
885 echo #ifndef SQLITE_RESOURCE_VERSION > sqlite3rc.h
886 for /F %%V in ('type "$(TOP)\VERSION"') do ( \
887 echo #define SQLITE_RESOURCE_VERSION %%V \
888 | $(NAWK) "/.*/ { gsub(/[.]/,\",\");print }" >> sqlite3rc.h \
890 echo #endif >> sqlite3rc.h
891 $(LTRCOMPILE) -fo $(LIBRESOBJS) $(TOP)\src\sqlite3.rc
894 # Rules to build individual *.lo files from files in the src directory.
896 alter.lo: $(TOP)\src\alter.c $(HDR)
897 $(LTCOMPILE) -c $(TOP)\src\alter.c
899 analyze.lo: $(TOP)\src\analyze.c $(HDR)
900 $(LTCOMPILE) -c $(TOP)\src\analyze.c
902 attach.lo: $(TOP)\src\attach.c $(HDR)
903 $(LTCOMPILE) -c $(TOP)\src\attach.c
905 auth.lo: $(TOP)\src\auth.c $(HDR)
906 $(LTCOMPILE) -c $(TOP)\src\auth.c
908 backup.lo: $(TOP)\src\backup.c $(HDR)
909 $(LTCOMPILE) -c $(TOP)\src\backup.c
911 bitvec.lo: $(TOP)\src\bitvec.c $(HDR)
912 $(LTCOMPILE) -c $(TOP)\src\bitvec.c
914 btmutex.lo: $(TOP)\src\btmutex.c $(HDR)
915 $(LTCOMPILE) -c $(TOP)\src\btmutex.c
917 btree.lo: $(TOP)\src\btree.c $(HDR) $(TOP)\src\pager.h
918 $(LTCOMPILE) -c $(TOP)\src\btree.c
920 build.lo: $(TOP)\src\build.c $(HDR)
921 $(LTCOMPILE) -c $(TOP)\src\build.c
923 callback.lo: $(TOP)\src\callback.c $(HDR)
924 $(LTCOMPILE) -c $(TOP)\src\callback.c
926 complete.lo: $(TOP)\src\complete.c $(HDR)
927 $(LTCOMPILE) -c $(TOP)\src\complete.c
929 ctime.lo: $(TOP)\src\ctime.c $(HDR)
930 $(LTCOMPILE) -c $(TOP)\src\ctime.c
932 date.lo: $(TOP)\src\date.c $(HDR)
933 $(LTCOMPILE) -c $(TOP)\src\date.c
935 delete.lo: $(TOP)\src\delete.c $(HDR)
936 $(LTCOMPILE) -c $(TOP)\src\delete.c
938 expr.lo: $(TOP)\src\expr.c $(HDR)
939 $(LTCOMPILE) -c $(TOP)\src\expr.c
941 fault.lo: $(TOP)\src\fault.c $(HDR)
942 $(LTCOMPILE) -c $(TOP)\src\fault.c
944 fkey.lo: $(TOP)\src\fkey.c $(HDR)
945 $(LTCOMPILE) -c $(TOP)\src\fkey.c
947 func.lo: $(TOP)\src\func.c $(HDR)
948 $(LTCOMPILE) -c $(TOP)\src\func.c
950 global.lo: $(TOP)\src\global.c $(HDR)
951 $(LTCOMPILE) -c $(TOP)\src\global.c
953 hash.lo: $(TOP)\src\hash.c $(HDR)
954 $(LTCOMPILE) -c $(TOP)\src\hash.c
956 insert.lo: $(TOP)\src\insert.c $(HDR)
957 $(LTCOMPILE) -c $(TOP)\src\insert.c
959 journal.lo: $(TOP)\src\journal.c $(HDR)
960 $(LTCOMPILE) -c $(TOP)\src\journal.c
962 legacy.lo: $(TOP)\src\legacy.c $(HDR)
963 $(LTCOMPILE) -c $(TOP)\src\legacy.c
965 loadext.lo: $(TOP)\src\loadext.c $(HDR)
966 $(LTCOMPILE) -c $(TOP)\src\loadext.c
968 main.lo: $(TOP)\src\main.c $(HDR)
969 $(LTCOMPILE) -c $(TOP)\src\main.c
971 malloc.lo: $(TOP)\src\malloc.c $(HDR)
972 $(LTCOMPILE) -c $(TOP)\src\malloc.c
974 mem0.lo: $(TOP)\src\mem0.c $(HDR)
975 $(LTCOMPILE) -c $(TOP)\src\mem0.c
977 mem1.lo: $(TOP)\src\mem1.c $(HDR)
978 $(LTCOMPILE) -c $(TOP)\src\mem1.c
980 mem2.lo: $(TOP)\src\mem2.c $(HDR)
981 $(LTCOMPILE) -c $(TOP)\src\mem2.c
983 mem3.lo: $(TOP)\src\mem3.c $(HDR)
984 $(LTCOMPILE) -c $(TOP)\src\mem3.c
986 mem5.lo: $(TOP)\src\mem5.c $(HDR)
987 $(LTCOMPILE) -c $(TOP)\src\mem5.c
989 memjournal.lo: $(TOP)\src\memjournal.c $(HDR)
990 $(LTCOMPILE) -c $(TOP)\src\memjournal.c
992 mutex.lo: $(TOP)\src\mutex.c $(HDR)
993 $(LTCOMPILE) -c $(TOP)\src\mutex.c
995 mutex_noop.lo: $(TOP)\src\mutex_noop.c $(HDR)
996 $(LTCOMPILE) -c $(TOP)\src\mutex_noop.c
998 mutex_unix.lo: $(TOP)\src\mutex_unix.c $(HDR)
999 $(LTCOMPILE) -c $(TOP)\src\mutex_unix.c
1001 mutex_w32.lo: $(TOP)\src\mutex_w32.c $(HDR)
1002 $(LTCOMPILE) -c $(TOP)\src\mutex_w32.c
1004 notify.lo: $(TOP)\src\notify.c $(HDR)
1005 $(LTCOMPILE) -c $(TOP)\src\notify.c
1007 pager.lo: $(TOP)\src\pager.c $(HDR) $(TOP)\src\pager.h
1008 $(LTCOMPILE) -c $(TOP)\src\pager.c
1010 pcache.lo: $(TOP)\src\pcache.c $(HDR) $(TOP)\src\pcache.h
1011 $(LTCOMPILE) -c $(TOP)\src\pcache.c
1013 pcache1.lo: $(TOP)\src\pcache1.c $(HDR) $(TOP)\src\pcache.h
1014 $(LTCOMPILE) -c $(TOP)\src\pcache1.c
1016 os.lo: $(TOP)\src\os.c $(HDR)
1017 $(LTCOMPILE) -c $(TOP)\src\os.c
1019 os_unix.lo: $(TOP)\src\os_unix.c $(HDR)
1020 $(LTCOMPILE) -c $(TOP)\src\os_unix.c
1022 os_win.lo: $(TOP)\src\os_win.c $(HDR)
1023 $(LTCOMPILE) -c $(TOP)\src\os_win.c
1025 pragma.lo: $(TOP)\src\pragma.c $(HDR)
1026 $(LTCOMPILE) -c $(TOP)\src\pragma.c
1028 prepare.lo: $(TOP)\src\prepare.c $(HDR)
1029 $(LTCOMPILE) -c $(TOP)\src\prepare.c
1031 printf.lo: $(TOP)\src\printf.c $(HDR)
1032 $(LTCOMPILE) -c $(TOP)\src\printf.c
1034 random.lo: $(TOP)\src\random.c $(HDR)
1035 $(LTCOMPILE) -c $(TOP)\src\random.c
1037 resolve.lo: $(TOP)\src\resolve.c $(HDR)
1038 $(LTCOMPILE) -c $(TOP)\src\resolve.c
1040 rowset.lo: $(TOP)\src\rowset.c $(HDR)
1041 $(LTCOMPILE) -c $(TOP)\src\rowset.c
1043 select.lo: $(TOP)\src\select.c $(HDR)
1044 $(LTCOMPILE) -c $(TOP)\src\select.c
1046 status.lo: $(TOP)\src\status.c $(HDR)
1047 $(LTCOMPILE) -c $(TOP)\src\status.c
1049 table.lo: $(TOP)\src\table.c $(HDR)
1050 $(LTCOMPILE) -c $(TOP)\src\table.c
1052 tokenize.lo: $(TOP)\src\tokenize.c keywordhash.h $(HDR)
1053 $(LTCOMPILE) -c $(TOP)\src\tokenize.c
1055 trigger.lo: $(TOP)\src\trigger.c $(HDR)
1056 $(LTCOMPILE) -c $(TOP)\src\trigger.c
1058 update.lo: $(TOP)\src\update.c $(HDR)
1059 $(LTCOMPILE) -c $(TOP)\src\update.c
1061 utf.lo: $(TOP)\src\utf.c $(HDR)
1062 $(LTCOMPILE) -c $(TOP)\src\utf.c
1064 util.lo: $(TOP)\src\util.c $(HDR)
1065 $(LTCOMPILE) -c $(TOP)\src\util.c
1067 vacuum.lo: $(TOP)\src\vacuum.c $(HDR)
1068 $(LTCOMPILE) -c $(TOP)\src\vacuum.c
1070 vdbe.lo: $(TOP)\src\vdbe.c $(HDR)
1071 $(LTCOMPILE) -c $(TOP)\src\vdbe.c
1073 vdbeapi.lo: $(TOP)\src\vdbeapi.c $(HDR)
1074 $(LTCOMPILE) -c $(TOP)\src\vdbeapi.c
1076 vdbeaux.lo: $(TOP)\src\vdbeaux.c $(HDR)
1077 $(LTCOMPILE) -c $(TOP)\src\vdbeaux.c
1079 vdbeblob.lo: $(TOP)\src\vdbeblob.c $(HDR)
1080 $(LTCOMPILE) -c $(TOP)\src\vdbeblob.c
1082 vdbemem.lo: $(TOP)\src\vdbemem.c $(HDR)
1083 $(LTCOMPILE) -c $(TOP)\src\vdbemem.c
1085 vdbesort.lo: $(TOP)\src\vdbesort.c $(HDR)
1086 $(LTCOMPILE) -c $(TOP)\src\vdbesort.c
1088 vdbetrace.lo: $(TOP)\src\vdbetrace.c $(HDR)
1089 $(LTCOMPILE) -c $(TOP)\src\vdbetrace.c
1091 vtab.lo: $(TOP)\src\vtab.c $(HDR)
1092 $(LTCOMPILE) -c $(TOP)\src\vtab.c
1094 wal.lo: $(TOP)\src\wal.c $(HDR)
1095 $(LTCOMPILE) -c $(TOP)\src\wal.c
1097 walker.lo: $(TOP)\src\walker.c $(HDR)
1098 $(LTCOMPILE) -c $(TOP)\src\walker.c
1100 where.lo: $(TOP)\src\where.c $(HDR)
1101 $(LTCOMPILE) -c $(TOP)\src\where.c
1103 tclsqlite.lo: $(TOP)\src\tclsqlite.c $(HDR)
1104 $(LTCOMPILE) -DUSE_TCL_STUBS=1 -DBUILD_sqlite -I$(TCLINCDIR) -c $(TOP)\src\tclsqlite.c
1106 tclsqlite-shell.lo: $(TOP)\src\tclsqlite.c $(HDR)
1107 $(LTCOMPILE) -DTCLSH=1 -DBUILD_sqlite -I$(TCLINCDIR) -c $(TOP)\src\tclsqlite.c
1109 tclsqlite3.exe: tclsqlite-shell.lo libsqlite3.lib $(LIBRESOBJS)
1110 $(LD) $(LDFLAGS) $(LTLINKOPTS) $(LTLIBPATHS) /OUT:$@ libsqlite3.lib tclsqlite-shell.lo $(LIBRESOBJS) $(LTLIBS) $(TLIBS)
1112 # Rules to build opcodes.c and opcodes.h
1114 opcodes.c: opcodes.h $(TOP)\mkopcodec.awk
1115 $(NAWK) -f $(TOP)\mkopcodec.awk opcodes.h > opcodes.c
1117 opcodes.h: parse.h $(TOP)\src\vdbe.c $(TOP)\mkopcodeh.awk
1118 type parse.h $(TOP)\src\vdbe.c | $(NAWK) -f $(TOP)\mkopcodeh.awk > opcodes.h
1120 # Rules to build parse.c and parse.h - the outputs of lemon.
1124 parse.c: $(TOP)\src\parse.y lemon.exe $(TOP)\addopcodes.awk
1125 del /Q parse.y parse.h parse.h.temp
1126 copy $(TOP)\src\parse.y .
1127 .\lemon.exe $(OPT_FEATURE_FLAGS) $(OPTS) parse.y
1128 move parse.h parse.h.temp
1129 $(NAWK) -f $(TOP)\addopcodes.awk parse.h.temp > parse.h
1131 sqlite3.h: $(TOP)\src\sqlite.h.in $(TOP)\manifest.uuid $(TOP)\VERSION
1132 $(TCLSH_CMD) $(TOP)\tool\mksqlite3h.tcl $(TOP) > sqlite3.h
1134 mkkeywordhash.exe: $(TOP)\tool\mkkeywordhash.c
1135 $(BCC) -Fe$@ $(OPT_FEATURE_FLAGS) $(OPTS) $(TOP)\tool\mkkeywordhash.c /link $(NLTLIBPATHS)
1137 keywordhash.h: $(TOP)\tool\mkkeywordhash.c mkkeywordhash.exe
1138 .\mkkeywordhash.exe > keywordhash.h
1142 # Rules to build the extension objects.
1144 icu.lo: $(TOP)\ext\icu\icu.c $(HDR) $(EXTHDR)
1145 $(LTCOMPILE) -DSQLITE_CORE -c $(TOP)\ext\icu\icu.c
1147 fts2.lo: $(TOP)\ext\fts2\fts2.c $(HDR) $(EXTHDR)
1148 $(LTCOMPILE) -DSQLITE_CORE -c $(TOP)\ext\fts2\fts2.c
1150 fts2_hash.lo: $(TOP)\ext\fts2\fts2_hash.c $(HDR) $(EXTHDR)
1151 $(LTCOMPILE) -DSQLITE_CORE -c $(TOP)\ext\fts2\fts2_hash.c
1153 fts2_icu.lo: $(TOP)\ext\fts2\fts2_icu.c $(HDR) $(EXTHDR)
1154 $(LTCOMPILE) -DSQLITE_CORE -c $(TOP)\ext\fts2\fts2_icu.c
1156 fts2_porter.lo: $(TOP)\ext\fts2\fts2_porter.c $(HDR) $(EXTHDR)
1157 $(LTCOMPILE) -DSQLITE_CORE -c $(TOP)\ext\fts2\fts2_porter.c
1159 fts2_tokenizer.lo: $(TOP)\ext\fts2\fts2_tokenizer.c $(HDR) $(EXTHDR)
1160 $(LTCOMPILE) -DSQLITE_CORE -c $(TOP)\ext\fts2\fts2_tokenizer.c
1162 fts2_tokenizer1.lo: $(TOP)\ext\fts2\fts2_tokenizer1.c $(HDR) $(EXTHDR)
1163 $(LTCOMPILE) -DSQLITE_CORE -c $(TOP)\ext\fts2\fts2_tokenizer1.c
1165 fts3.lo: $(TOP)\ext\fts3\fts3.c $(HDR) $(EXTHDR)
1166 $(LTCOMPILE) -DSQLITE_CORE -c $(TOP)\ext\fts3\fts3.c
1168 fts3_aux.lo: $(TOP)\ext\fts3\fts3_aux.c $(HDR) $(EXTHDR)
1169 $(LTCOMPILE) -DSQLITE_CORE -c $(TOP)\ext\fts3\fts3_aux.c
1171 fts3_expr.lo: $(TOP)\ext\fts3\fts3_expr.c $(HDR) $(EXTHDR)
1172 $(LTCOMPILE) -DSQLITE_CORE -c $(TOP)\ext\fts3\fts3_expr.c
1174 fts3_hash.lo: $(TOP)\ext\fts3\fts3_hash.c $(HDR) $(EXTHDR)
1175 $(LTCOMPILE) -DSQLITE_CORE -c $(TOP)\ext\fts3\fts3_hash.c
1177 fts3_icu.lo: $(TOP)\ext\fts3\fts3_icu.c $(HDR) $(EXTHDR)
1178 $(LTCOMPILE) -DSQLITE_CORE -c $(TOP)\ext\fts3\fts3_icu.c
1180 fts3_snippet.lo: $(TOP)\ext\fts3\fts3_snippet.c $(HDR) $(EXTHDR)
1181 $(LTCOMPILE) -DSQLITE_CORE -c $(TOP)\ext\fts3\fts3_snippet.c
1183 fts3_porter.lo: $(TOP)\ext\fts3\fts3_porter.c $(HDR) $(EXTHDR)
1184 $(LTCOMPILE) -DSQLITE_CORE -c $(TOP)\ext\fts3\fts3_porter.c
1186 fts3_tokenizer.lo: $(TOP)\ext\fts3\fts3_tokenizer.c $(HDR) $(EXTHDR)
1187 $(LTCOMPILE) -DSQLITE_CORE -c $(TOP)\ext\fts3\fts3_tokenizer.c
1189 fts3_tokenizer1.lo: $(TOP)\ext\fts3\fts3_tokenizer1.c $(HDR) $(EXTHDR)
1190 $(LTCOMPILE) -DSQLITE_CORE -c $(TOP)\ext\fts3\fts3_tokenizer1.c
1192 fts3_tokenize_vtab.lo: $(TOP)\ext\fts3\fts3_tokenize_vtab.c $(HDR) $(EXTHDR)
1193 $(LTCOMPILE) -DSQLITE_CORE -c $(TOP)\ext\fts3\fts3_tokenize_vtab.c
1195 fts3_unicode.lo: $(TOP)\ext\fts3\fts3_unicode.c $(HDR) $(EXTHDR)
1196 $(LTCOMPILE) -DSQLITE_CORE -c $(TOP)\ext\fts3\fts3_unicode.c
1198 fts3_unicode2.lo: $(TOP)\ext\fts3\fts3_unicode2.c $(HDR) $(EXTHDR)
1199 $(LTCOMPILE) -DSQLITE_CORE -c $(TOP)\ext\fts3\fts3_unicode2.c
1201 fts3_write.lo: $(TOP)\ext\fts3\fts3_write.c $(HDR) $(EXTHDR)
1202 $(LTCOMPILE) -DSQLITE_CORE -c $(TOP)\ext\fts3\fts3_write.c
1204 rtree.lo: $(TOP)\ext\rtree\rtree.c $(HDR) $(EXTHDR)
1205 $(LTCOMPILE) -DSQLITE_CORE -c $(TOP)\ext\rtree\rtree.c
1208 # Rules to build the 'testfixture' application.
1210 # If using the amalgamation, use sqlite3.c directly to build the test
1211 # fixture. Otherwise link against libsqlite3.lib. (This distinction is
1212 # necessary because the test fixture requires non-API symbols which are
1213 # hidden when the library is built via the amalgamation).
1215 TESTFIXTURE_FLAGS = -DTCLSH=1 -DSQLITE_TEST=1 -DSQLITE_CRASH_TEST=1
1216 TESTFIXTURE_FLAGS = $(TESTFIXTURE_FLAGS) -DSQLITE_SERVER=1 -DSQLITE_PRIVATE="" -DSQLITE_CORE
1218 TESTFIXTURE_SRC0 = $(TESTEXT) $(TESTSRC2) libsqlite3.lib
1219 TESTFIXTURE_SRC1 = $(TESTEXT) sqlite3.c
1220 !IF $(USE_AMALGAMATION)==0
1221 TESTFIXTURE_SRC = $(TESTSRC) $(TOP)\src\tclsqlite.c $(TESTFIXTURE_SRC0)
1223 TESTFIXTURE_SRC = $(TESTSRC) $(TOP)\src\tclsqlite.c $(TESTFIXTURE_SRC1)
1226 testfixture.exe: $(TESTFIXTURE_SRC) $(LIBRESOBJS) $(HDR)
1227 $(LTLINK) -DSQLITE_NO_SYNC=1 $(TESTFIXTURE_FLAGS) \
1228 -DBUILD_sqlite -I$(TCLINCDIR) \
1229 $(TESTFIXTURE_SRC) \
1230 /link $(LTLINKOPTS) $(LTLIBPATHS) $(LIBRESOBJS) $(LTLIBS) $(TLIBS)
1232 fulltest: testfixture.exe sqlite3.exe
1233 .\testfixture.exe $(TOP)\test\all.test
1235 soaktest: testfixture.exe sqlite3.exe
1236 .\testfixture.exe $(TOP)\test\all.test -soak=1
1238 fulltestonly: testfixture.exe sqlite3.exe
1239 .\testfixture.exe $(TOP)\test\full.test
1241 test: testfixture.exe sqlite3.exe
1242 .\testfixture.exe $(TOP)\test\veryquick.test
1244 sqlite3_analyzer.c: sqlite3.c $(TOP)\src\test_stat.c $(TOP)\src\tclsqlite.c $(TOP)\tool\spaceanal.tcl
1245 copy sqlite3.c + $(TOP)\src\test_stat.c + $(TOP)\src\tclsqlite.c $@
1246 echo static const char *tclsh_main_loop(void){ >> $@
1247 echo static const char *zMainloop = >> $@
1248 $(NAWK) -f $(TOP)\tool\tostr.awk $(TOP)\tool\spaceanal.tcl >> $@
1249 echo ; return zMainloop; } >> $@
1251 sqlite3_analyzer.exe: sqlite3_analyzer.c $(LIBRESOBJS)
1252 $(LTLINK) -DBUILD_sqlite -DTCLSH=2 -I$(TCLINCDIR) sqlite3_analyzer.c \
1253 /link $(LTLINKOPTS) $(LTLIBPATHS) $(LIBRESOBJS) $(LTLIBS) $(TLIBS)
1256 del /Q *.lo *.ilk *.lib *.obj *.pdb sqlite3.exe libsqlite3.lib
1257 del /Q *.da *.bb *.bbg gmon.out
1258 del /Q sqlite3.h opcodes.c opcodes.h
1259 del /Q lemon.exe lempar.c parse.*
1260 del /Q mkkeywordhash.exe keywordhash.h
1267 del /Q .target_source
1268 del /Q tclsqlite3.exe tclsqlite3.exp
1269 del /Q testfixture.exe testfixture.exp test.db
1270 del /Q sqlite3.dll sqlite3.lib sqlite3.exp sqlite3.def
1273 del /Q shell.c sqlite3ext.h
1274 del /Q sqlite3_analyzer.exe sqlite3_analyzer.exp sqlite3_analyzer.c
1275 del /Q sqlite-*-output.vsix
1278 # Dynamic link library section.
1282 sqlite3.def: libsqlite3.lib
1283 echo EXPORTS > sqlite3.def
1284 dumpbin /all libsqlite3.lib \
1285 | $(NAWK) "/ 1 _?sqlite3_/ { sub(/^.* _?/,\"\");print }" \
1286 | sort >> sqlite3.def
1288 sqlite3.dll: $(LIBOBJ) $(LIBRESOBJS) sqlite3.def
1289 $(LD) $(LDFLAGS) $(LTLINKOPTS) $(LTLIBPATHS) /DLL /DEF:sqlite3.def /OUT:$@ $(LIBOBJ) $(LIBRESOBJS) $(LTLIBS) $(TLIBS)