shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1 | # |
shaneh | 603e426 | 2011-06-17 18:52:07 +0000 | [diff] [blame] | 2 | # nmake Makefile for SQLite |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 3 | # |
| 4 | |
| 5 | # The toplevel directory of the source tree. This is the directory |
| 6 | # that contains this "Makefile.msc". |
| 7 | # |
| 8 | TOP = . |
| 9 | |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 10 | # Set this non-0 to create and use the SQLite amalgamation file. |
| 11 | # |
mistachkin | 0ec0744 | 2012-10-12 18:06:07 +0000 | [diff] [blame] | 12 | !IFNDEF USE_AMALGAMATION |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 13 | USE_AMALGAMATION = 1 |
mistachkin | 0ec0744 | 2012-10-12 18:06:07 +0000 | [diff] [blame] | 14 | !ENDIF |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 15 | |
mistachkin | 7651091 | 2013-10-11 23:01:18 +0000 | [diff] [blame] | 16 | # Set this non-0 to split the SQLite amalgamation file into chunks to |
| 17 | # be used for debugging with Visual Studio. |
| 18 | # |
| 19 | !IFNDEF SPLIT_AMALGAMATION |
mistachkin | 0aedc6b | 2013-10-11 23:02:13 +0000 | [diff] [blame] | 20 | SPLIT_AMALGAMATION = 0 |
mistachkin | 7651091 | 2013-10-11 23:01:18 +0000 | [diff] [blame] | 21 | !ENDIF |
| 22 | |
mistachkin | c756ded | 2011-10-02 05:23:16 +0000 | [diff] [blame] | 23 | # Set this non-0 to use the International Components for Unicode (ICU). |
| 24 | # |
mistachkin | 0ec0744 | 2012-10-12 18:06:07 +0000 | [diff] [blame] | 25 | !IFNDEF USE_ICU |
mistachkin | c756ded | 2011-10-02 05:23:16 +0000 | [diff] [blame] | 26 | USE_ICU = 0 |
mistachkin | 0ec0744 | 2012-10-12 18:06:07 +0000 | [diff] [blame] | 27 | !ENDIF |
mistachkin | c756ded | 2011-10-02 05:23:16 +0000 | [diff] [blame] | 28 | |
mistachkin | 8d967a9 | 2012-06-21 04:21:35 +0000 | [diff] [blame] | 29 | # Set this non-0 to dynamically link to the MSVC runtime library. |
| 30 | # |
mistachkin | 0ec0744 | 2012-10-12 18:06:07 +0000 | [diff] [blame] | 31 | !IFNDEF USE_CRT_DLL |
mistachkin | 8d967a9 | 2012-06-21 04:21:35 +0000 | [diff] [blame] | 32 | USE_CRT_DLL = 0 |
mistachkin | 0ec0744 | 2012-10-12 18:06:07 +0000 | [diff] [blame] | 33 | !ENDIF |
mistachkin | 8d967a9 | 2012-06-21 04:21:35 +0000 | [diff] [blame] | 34 | |
mistachkin | 0157e01 | 2013-09-06 21:41:11 +0000 | [diff] [blame] | 35 | # Set this non-0 to generate assembly code listings for the source code |
| 36 | # files. |
| 37 | # |
| 38 | !IFNDEF USE_LISTINGS |
| 39 | USE_LISTINGS = 0 |
| 40 | !ENDIF |
| 41 | |
mistachkin | 52fd8e1 | 2012-08-28 01:44:13 +0000 | [diff] [blame] | 42 | # Set this non-0 to attempt setting the native compiler automatically |
| 43 | # for cross-compiling the command line tools needed during the compilation |
| 44 | # process. |
| 45 | # |
mistachkin | 0ec0744 | 2012-10-12 18:06:07 +0000 | [diff] [blame] | 46 | !IFNDEF XCOMPILE |
mistachkin | 52fd8e1 | 2012-08-28 01:44:13 +0000 | [diff] [blame] | 47 | XCOMPILE = 0 |
mistachkin | 0ec0744 | 2012-10-12 18:06:07 +0000 | [diff] [blame] | 48 | !ENDIF |
mistachkin | 52fd8e1 | 2012-08-28 01:44:13 +0000 | [diff] [blame] | 49 | |
mistachkin | bd58d5f | 2012-06-30 22:22:34 +0000 | [diff] [blame] | 50 | # Set this non-0 to use the native libraries paths for cross-compiling |
| 51 | # the command line tools needed during the compilation process. |
| 52 | # |
mistachkin | 0ec0744 | 2012-10-12 18:06:07 +0000 | [diff] [blame] | 53 | !IFNDEF USE_NATIVE_LIBPATHS |
mistachkin | bd58d5f | 2012-06-30 22:22:34 +0000 | [diff] [blame] | 54 | USE_NATIVE_LIBPATHS = 0 |
mistachkin | 0ec0744 | 2012-10-12 18:06:07 +0000 | [diff] [blame] | 55 | !ENDIF |
mistachkin | bd58d5f | 2012-06-30 22:22:34 +0000 | [diff] [blame] | 56 | |
mistachkin | 08c1c31 | 2012-10-06 03:48:25 +0000 | [diff] [blame] | 57 | # Set this 0 to skip the compiling and embedding of version resources. |
| 58 | # |
mistachkin | 0ec0744 | 2012-10-12 18:06:07 +0000 | [diff] [blame] | 59 | !IFNDEF USE_RC |
mistachkin | 08c1c31 | 2012-10-06 03:48:25 +0000 | [diff] [blame] | 60 | USE_RC = 1 |
mistachkin | 0ec0744 | 2012-10-12 18:06:07 +0000 | [diff] [blame] | 61 | !ENDIF |
mistachkin | 08c1c31 | 2012-10-06 03:48:25 +0000 | [diff] [blame] | 62 | |
mistachkin | 46b721a | 2012-03-23 12:28:21 +0000 | [diff] [blame] | 63 | # Set this non-0 to compile binaries suitable for the WinRT environment. |
| 64 | # This setting does not apply to any binaries that require Tcl to operate |
| 65 | # properly (i.e. the text fixture, etc). |
| 66 | # |
mistachkin | 0ec0744 | 2012-10-12 18:06:07 +0000 | [diff] [blame] | 67 | !IFNDEF FOR_WINRT |
mistachkin | 46b721a | 2012-03-23 12:28:21 +0000 | [diff] [blame] | 68 | FOR_WINRT = 0 |
mistachkin | 0ec0744 | 2012-10-12 18:06:07 +0000 | [diff] [blame] | 69 | !ENDIF |
mistachkin | 46b721a | 2012-03-23 12:28:21 +0000 | [diff] [blame] | 70 | |
mistachkin | 31856a3 | 2012-07-27 07:13:25 +0000 | [diff] [blame] | 71 | # Set this non-0 to skip attempting to look for and/or link with the Tcl |
| 72 | # runtime library. |
| 73 | # |
mistachkin | 0ec0744 | 2012-10-12 18:06:07 +0000 | [diff] [blame] | 74 | !IFNDEF NO_TCL |
mistachkin | 31856a3 | 2012-07-27 07:13:25 +0000 | [diff] [blame] | 75 | NO_TCL = 0 |
mistachkin | 0ec0744 | 2012-10-12 18:06:07 +0000 | [diff] [blame] | 76 | !ENDIF |
mistachkin | 31856a3 | 2012-07-27 07:13:25 +0000 | [diff] [blame] | 77 | |
mistachkin | 4d60be5 | 2011-08-26 05:40:31 +0000 | [diff] [blame] | 78 | # Set this to non-0 to create and use PDBs. |
| 79 | # |
mistachkin | 0ec0744 | 2012-10-12 18:06:07 +0000 | [diff] [blame] | 80 | !IFNDEF SYMBOLS |
mistachkin | 4d60be5 | 2011-08-26 05:40:31 +0000 | [diff] [blame] | 81 | SYMBOLS = 1 |
mistachkin | 0ec0744 | 2012-10-12 18:06:07 +0000 | [diff] [blame] | 82 | !ENDIF |
mistachkin | 4d60be5 | 2011-08-26 05:40:31 +0000 | [diff] [blame] | 83 | |
mistachkin | 2f7d5d8 | 2012-08-22 00:39:34 +0000 | [diff] [blame] | 84 | # Set this to non-0 to use the SQLite debugging heap subsystem. |
| 85 | # |
mistachkin | 0ec0744 | 2012-10-12 18:06:07 +0000 | [diff] [blame] | 86 | !IFNDEF MEMDEBUG |
mistachkin | 2f7d5d8 | 2012-08-22 00:39:34 +0000 | [diff] [blame] | 87 | MEMDEBUG = 0 |
mistachkin | 0ec0744 | 2012-10-12 18:06:07 +0000 | [diff] [blame] | 88 | !ENDIF |
mistachkin | 2f7d5d8 | 2012-08-22 00:39:34 +0000 | [diff] [blame] | 89 | |
| 90 | # Set this to non-0 to use the Win32 native heap subsystem. |
| 91 | # |
mistachkin | 0ec0744 | 2012-10-12 18:06:07 +0000 | [diff] [blame] | 92 | !IFNDEF WIN32HEAP |
mistachkin | 2f7d5d8 | 2012-08-22 00:39:34 +0000 | [diff] [blame] | 93 | WIN32HEAP = 0 |
mistachkin | 0ec0744 | 2012-10-12 18:06:07 +0000 | [diff] [blame] | 94 | !ENDIF |
mistachkin | 2f7d5d8 | 2012-08-22 00:39:34 +0000 | [diff] [blame] | 95 | |
mistachkin | f2d25f2 | 2011-08-25 04:09:12 +0000 | [diff] [blame] | 96 | # Set this to one of the following values to enable various debugging |
| 97 | # features. Each level includes the debugging options from the previous |
| 98 | # levels. Currently, the recognized values for DEBUG are: |
| 99 | # |
| 100 | # 0 == NDEBUG: Disables assert() and other runtime diagnostics. |
| 101 | # 1 == Disables NDEBUG and all optimizations and then enables PDBs. |
| 102 | # 2 == SQLITE_DEBUG: Enables various diagnostics messages and code. |
| 103 | # 3 == SQLITE_WIN32_MALLOC_VALIDATE: Validate the Win32 native heap per call. |
| 104 | # 4 == SQLITE_DEBUG_OS_TRACE: Enables output from the OSTRACE() macros. |
| 105 | # 5 == SQLITE_ENABLE_IOTRACE: Enables output from the IOTRACE() macros. |
| 106 | # |
mistachkin | 0ec0744 | 2012-10-12 18:06:07 +0000 | [diff] [blame] | 107 | !IFNDEF DEBUG |
mistachkin | f2d25f2 | 2011-08-25 04:09:12 +0000 | [diff] [blame] | 108 | DEBUG = 0 |
mistachkin | 0ec0744 | 2012-10-12 18:06:07 +0000 | [diff] [blame] | 109 | !ENDIF |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 110 | |
mistachkin | 8bcd3fa | 2013-08-29 01:03:38 +0000 | [diff] [blame] | 111 | # Enable use of available compiler optimizations? Normally, this should be |
| 112 | # non-zero. Setting this to zero, thus disabling all compiler optimizations, |
| 113 | # can be useful for testing. |
| 114 | # |
| 115 | !IFNDEF OPTIMIZATIONS |
| 116 | OPTIMIZATIONS = 2 |
| 117 | !ENDIF |
| 118 | |
mistachkin | e37f99c | 2012-06-30 16:22:05 +0000 | [diff] [blame] | 119 | # Check for the predefined command macro CC. This should point to the compiler |
mistachkin | bd58d5f | 2012-06-30 22:22:34 +0000 | [diff] [blame] | 120 | # binary for the target platform. If it is not defined, simply define it to |
mistachkin | e37f99c | 2012-06-30 16:22:05 +0000 | [diff] [blame] | 121 | # the legacy default value 'cl.exe'. |
| 122 | # |
| 123 | !IFNDEF CC |
| 124 | CC = cl.exe |
| 125 | !ENDIF |
| 126 | |
mistachkin | 228aeff | 2012-06-30 19:24:09 +0000 | [diff] [blame] | 127 | # Check for the command macro LD. This should point to the linker binary for |
mistachkin | bd58d5f | 2012-06-30 22:22:34 +0000 | [diff] [blame] | 128 | # the target platform. If it is not defined, simply define it to the legacy |
mistachkin | 228aeff | 2012-06-30 19:24:09 +0000 | [diff] [blame] | 129 | # default value 'link.exe'. |
| 130 | # |
| 131 | !IFNDEF LD |
| 132 | LD = link.exe |
| 133 | !ENDIF |
| 134 | |
mistachkin | 4d9d1f4 | 2012-09-03 10:32:32 +0000 | [diff] [blame] | 135 | # Check for the predefined command macro RC. This should point to the resource |
| 136 | # compiler binary for the target platform. If it is not defined, simply define |
| 137 | # it to the legacy default value 'rc.exe'. |
| 138 | # |
| 139 | !IFNDEF RC |
| 140 | RC = rc.exe |
| 141 | !ENDIF |
| 142 | |
mistachkin | e37f99c | 2012-06-30 16:22:05 +0000 | [diff] [blame] | 143 | # Check for the command macro NCC. This should point to the compiler binary |
mistachkin | bd58d5f | 2012-06-30 22:22:34 +0000 | [diff] [blame] | 144 | # for the platform the compilation process is taking place on. If it is not |
| 145 | # defined, simply define it to have the same value as the CC macro. When |
mistachkin | e37f99c | 2012-06-30 16:22:05 +0000 | [diff] [blame] | 146 | # cross-compiling, it is suggested that this macro be modified via the command |
| 147 | # line (since nmake itself does not provide a built-in method to guess it). |
| 148 | # For example, to use the x86 compiler when cross-compiling for x64, a command |
mistachkin | bd58d5f | 2012-06-30 22:22:34 +0000 | [diff] [blame] | 149 | # line similar to the following could be used (all on one line): |
mistachkin | e37f99c | 2012-06-30 16:22:05 +0000 | [diff] [blame] | 150 | # |
mistachkin | 6f92833 | 2012-08-17 11:47:32 +0000 | [diff] [blame] | 151 | # nmake /f Makefile.msc sqlite3.dll |
mistachkin | 52fd8e1 | 2012-08-28 01:44:13 +0000 | [diff] [blame] | 152 | # XCOMPILE=1 USE_NATIVE_LIBPATHS=1 |
| 153 | # |
| 154 | # Alternatively, the full path and file name to the compiler binary for the |
| 155 | # platform the compilation process is taking place may be specified (all on |
| 156 | # one line): |
| 157 | # |
| 158 | # nmake /f Makefile.msc sqlite3.dll |
mistachkin | bd58d5f | 2012-06-30 22:22:34 +0000 | [diff] [blame] | 159 | # "NCC=""%VCINSTALLDIR%\bin\cl.exe""" |
| 160 | # USE_NATIVE_LIBPATHS=1 |
mistachkin | e37f99c | 2012-06-30 16:22:05 +0000 | [diff] [blame] | 161 | # |
mistachkin | fd0ba2a | 2012-07-27 08:21:45 +0000 | [diff] [blame] | 162 | !IFDEF NCC |
| 163 | NCC = $(NCC:\\=\) |
mistachkin | 52fd8e1 | 2012-08-28 01:44:13 +0000 | [diff] [blame] | 164 | !ELSEIF $(XCOMPILE)!=0 |
mistachkin | 5fac420 | 2013-12-03 23:33:29 +0000 | [diff] [blame] | 165 | NCC = "$(VCINSTALLDIR)\bin\$(CC)" |
mistachkin | 52fd8e1 | 2012-08-28 01:44:13 +0000 | [diff] [blame] | 166 | NCC = $(NCC:\\=\) |
mistachkin | fd0ba2a | 2012-07-27 08:21:45 +0000 | [diff] [blame] | 167 | !ELSE |
mistachkin | e37f99c | 2012-06-30 16:22:05 +0000 | [diff] [blame] | 168 | NCC = $(CC) |
| 169 | !ENDIF |
| 170 | |
mistachkin | bd58d5f | 2012-06-30 22:22:34 +0000 | [diff] [blame] | 171 | # Check for the MSVC runtime library path macro. Othertise, this |
| 172 | # value will default to the 'lib' directory underneath the MSVC |
| 173 | # installation directory. |
| 174 | # |
| 175 | !IFNDEF NCRTLIBPATH |
| 176 | NCRTLIBPATH = $(VCINSTALLDIR)\lib |
| 177 | !ENDIF |
| 178 | |
mistachkin | 0b5ae72 | 2012-07-27 23:03:47 +0000 | [diff] [blame] | 179 | NCRTLIBPATH = $(NCRTLIBPATH:\\=\) |
| 180 | |
mistachkin | bd58d5f | 2012-06-30 22:22:34 +0000 | [diff] [blame] | 181 | # Check for the Platform SDK library path macro. Othertise, this |
| 182 | # value will default to the 'lib' directory underneath the Windows |
| 183 | # SDK installation directory (the environment variable used appears |
| 184 | # to be available when using Visual C++ 2008 or later via the |
| 185 | # command line). |
| 186 | # |
| 187 | !IFNDEF NSDKLIBPATH |
| 188 | NSDKLIBPATH = $(WINDOWSSDKDIR)\lib |
| 189 | !ENDIF |
| 190 | |
mistachkin | 0b5ae72 | 2012-07-27 23:03:47 +0000 | [diff] [blame] | 191 | NSDKLIBPATH = $(NSDKLIBPATH:\\=\) |
| 192 | |
mistachkin | bd58d5f | 2012-06-30 22:22:34 +0000 | [diff] [blame] | 193 | # C compiler and options for use in building executables that |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 194 | # will run on the platform that is doing the build. |
| 195 | # |
mistachkin | e37f99c | 2012-06-30 16:22:05 +0000 | [diff] [blame] | 196 | BCC = $(NCC) -W3 |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 197 | |
mistachkin | 0157e01 | 2013-09-06 21:41:11 +0000 | [diff] [blame] | 198 | # Check if assembly code listings should be generated for the source |
| 199 | # code files to be compiled. |
| 200 | # |
| 201 | !IF $(USE_LISTINGS)!=0 |
| 202 | BCC = $(BCC) -FAcs |
| 203 | !ENDIF |
| 204 | |
mistachkin | bd58d5f | 2012-06-30 22:22:34 +0000 | [diff] [blame] | 205 | # Check if the native library paths should be used when compiling |
| 206 | # the command line tools used during the compilation process. If |
| 207 | # so, set the necessary macro now. |
| 208 | # |
| 209 | !IF $(USE_NATIVE_LIBPATHS)!=0 |
| 210 | NLTLIBPATHS = "/LIBPATH:$(NCRTLIBPATH)" "/LIBPATH:$(NSDKLIBPATH)" |
| 211 | !ENDIF |
| 212 | |
| 213 | # C compiler and options for use in building executables that |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 214 | # will run on the target platform. (BCC and TCC are usually the |
| 215 | # same unless your are cross-compiling.) |
| 216 | # |
mistachkin | 8ccc6d4 | 2012-09-27 21:03:53 +0000 | [diff] [blame] | 217 | TCC = $(CC) -W3 -DSQLITE_OS_WIN=1 -I$(TOP) -I$(TOP)\src -fp:precise |
| 218 | RCC = $(RC) -DSQLITE_OS_WIN=1 -I$(TOP) -I$(TOP)\src |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 219 | |
mistachkin | 0157e01 | 2013-09-06 21:41:11 +0000 | [diff] [blame] | 220 | # Check if assembly code listings should be generated for the source |
| 221 | # code files to be compiled. |
| 222 | # |
| 223 | !IF $(USE_LISTINGS)!=0 |
| 224 | TCC = $(TCC) -FAcs |
| 225 | !ENDIF |
| 226 | |
mistachkin | f39eaf2 | 2012-03-20 02:18:42 +0000 | [diff] [blame] | 227 | # When compiling the library for use in the WinRT environment, |
mistachkin | 46b721a | 2012-03-23 12:28:21 +0000 | [diff] [blame] | 228 | # the following compile-time options must be used as well to |
mistachkin | f39eaf2 | 2012-03-20 02:18:42 +0000 | [diff] [blame] | 229 | # disable use of Win32 APIs that are not available and to enable |
| 230 | # use of Win32 APIs that are specific to Windows 8 and/or WinRT. |
| 231 | # |
mistachkin | 46b721a | 2012-03-23 12:28:21 +0000 | [diff] [blame] | 232 | !IF $(FOR_WINRT)!=0 |
mistachkin | 8d967a9 | 2012-06-21 04:21:35 +0000 | [diff] [blame] | 233 | TCC = $(TCC) -DSQLITE_OS_WINRT=1 |
mistachkin | 4d9d1f4 | 2012-09-03 10:32:32 +0000 | [diff] [blame] | 234 | RCC = $(RCC) -DSQLITE_OS_WINRT=1 |
mistachkin | 08c1c31 | 2012-10-06 03:48:25 +0000 | [diff] [blame] | 235 | TCC = $(TCC) -DWINAPI_FAMILY=WINAPI_FAMILY_APP |
| 236 | RCC = $(RCC) -DWINAPI_FAMILY=WINAPI_FAMILY_APP |
mistachkin | 8d967a9 | 2012-06-21 04:21:35 +0000 | [diff] [blame] | 237 | !ENDIF |
| 238 | |
| 239 | # Also, we need to dynamically link to the correct MSVC runtime |
| 240 | # when compiling for WinRT (e.g. debug or release) OR if the |
| 241 | # USE_CRT_DLL option is set to force dynamically linking to the |
| 242 | # MSVC runtime library. |
| 243 | # |
| 244 | !IF $(FOR_WINRT)!=0 || $(USE_CRT_DLL)!=0 |
| 245 | !IF $(DEBUG)>0 |
| 246 | TCC = $(TCC) -MDd |
mistachkin | 08c1c31 | 2012-10-06 03:48:25 +0000 | [diff] [blame] | 247 | BCC = $(BCC) -MDd |
mistachkin | 8d967a9 | 2012-06-21 04:21:35 +0000 | [diff] [blame] | 248 | !ELSE |
| 249 | TCC = $(TCC) -MD |
mistachkin | 08c1c31 | 2012-10-06 03:48:25 +0000 | [diff] [blame] | 250 | BCC = $(BCC) -MD |
mistachkin | 8d967a9 | 2012-06-21 04:21:35 +0000 | [diff] [blame] | 251 | !ENDIF |
| 252 | !ELSE |
| 253 | !IF $(DEBUG)>0 |
| 254 | TCC = $(TCC) -MTd |
mistachkin | 08c1c31 | 2012-10-06 03:48:25 +0000 | [diff] [blame] | 255 | BCC = $(BCC) -MTd |
mistachkin | 8d967a9 | 2012-06-21 04:21:35 +0000 | [diff] [blame] | 256 | !ELSE |
| 257 | TCC = $(TCC) -MT |
mistachkin | 08c1c31 | 2012-10-06 03:48:25 +0000 | [diff] [blame] | 258 | BCC = $(BCC) -MT |
mistachkin | 8d967a9 | 2012-06-21 04:21:35 +0000 | [diff] [blame] | 259 | !ENDIF |
mistachkin | 46b721a | 2012-03-23 12:28:21 +0000 | [diff] [blame] | 260 | !ENDIF |
mistachkin | f39eaf2 | 2012-03-20 02:18:42 +0000 | [diff] [blame] | 261 | |
| 262 | # The mksqlite3c.tcl and mksqlite3h.tcl scripts will pull in |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 263 | # any extension header files by default. For non-amalgamation |
| 264 | # builds, we need to make sure the compiler can find these. |
| 265 | # |
| 266 | !IF $(USE_AMALGAMATION)==0 |
| 267 | TCC = $(TCC) -I$(TOP)\ext\fts3 |
mistachkin | 4d9d1f4 | 2012-09-03 10:32:32 +0000 | [diff] [blame] | 268 | RCC = $(RCC) -I$(TOP)\ext\fts3 |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 269 | TCC = $(TCC) -I$(TOP)\ext\rtree |
mistachkin | 4d9d1f4 | 2012-09-03 10:32:32 +0000 | [diff] [blame] | 270 | RCC = $(RCC) -I$(TOP)\ext\rtree |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 271 | !ENDIF |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 272 | |
| 273 | # Define -DNDEBUG to compile without debugging (i.e., for production usage) |
| 274 | # Omitting the define will cause extra debugging code to be inserted and |
| 275 | # includes extra comments when "EXPLAIN stmt" is used. |
| 276 | # |
mistachkin | 753c544 | 2011-08-25 02:02:25 +0000 | [diff] [blame] | 277 | !IF $(DEBUG)==0 |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 278 | TCC = $(TCC) -DNDEBUG |
mistachkin | fec360a | 2012-04-18 10:29:21 +0000 | [diff] [blame] | 279 | BCC = $(BCC) -DNDEBUG |
mistachkin | 4d9d1f4 | 2012-09-03 10:32:32 +0000 | [diff] [blame] | 280 | RCC = $(RCC) -DNDEBUG |
mistachkin | 753c544 | 2011-08-25 02:02:25 +0000 | [diff] [blame] | 281 | !ENDIF |
| 282 | |
| 283 | !IF $(DEBUG)>1 |
| 284 | TCC = $(TCC) -DSQLITE_DEBUG |
mistachkin | 4d9d1f4 | 2012-09-03 10:32:32 +0000 | [diff] [blame] | 285 | RCC = $(RCC) -DSQLITE_DEBUG |
mistachkin | 753c544 | 2011-08-25 02:02:25 +0000 | [diff] [blame] | 286 | !ENDIF |
| 287 | |
| 288 | !IF $(DEBUG)>3 |
| 289 | TCC = $(TCC) -DSQLITE_DEBUG_OS_TRACE=1 |
mistachkin | 4d9d1f4 | 2012-09-03 10:32:32 +0000 | [diff] [blame] | 290 | RCC = $(RCC) -DSQLITE_DEBUG_OS_TRACE=1 |
mistachkin | 753c544 | 2011-08-25 02:02:25 +0000 | [diff] [blame] | 291 | !ENDIF |
| 292 | |
| 293 | !IF $(DEBUG)>4 |
| 294 | TCC = $(TCC) -DSQLITE_ENABLE_IOTRACE |
mistachkin | 4d9d1f4 | 2012-09-03 10:32:32 +0000 | [diff] [blame] | 295 | RCC = $(RCC) -DSQLITE_ENABLE_IOTRACE |
mistachkin | 753c544 | 2011-08-25 02:02:25 +0000 | [diff] [blame] | 296 | !ENDIF |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 297 | |
mistachkin | 176f1b4 | 2011-08-02 23:34:00 +0000 | [diff] [blame] | 298 | # |
mistachkin | bd58d5f | 2012-06-30 22:22:34 +0000 | [diff] [blame] | 299 | # Prevent warnings about "insecure" MSVC runtime library functions |
| 300 | # being used. |
mistachkin | 176f1b4 | 2011-08-02 23:34:00 +0000 | [diff] [blame] | 301 | # |
| 302 | TCC = $(TCC) -D_CRT_SECURE_NO_DEPRECATE -D_CRT_SECURE_NO_WARNINGS |
mistachkin | fec360a | 2012-04-18 10:29:21 +0000 | [diff] [blame] | 303 | BCC = $(BCC) -D_CRT_SECURE_NO_DEPRECATE -D_CRT_SECURE_NO_WARNINGS |
mistachkin | 4d9d1f4 | 2012-09-03 10:32:32 +0000 | [diff] [blame] | 304 | RCC = $(RCC) -D_CRT_SECURE_NO_DEPRECATE -D_CRT_SECURE_NO_WARNINGS |
mistachkin | 176f1b4 | 2011-08-02 23:34:00 +0000 | [diff] [blame] | 305 | |
mistachkin | 1b186a9 | 2011-08-24 16:13:57 +0000 | [diff] [blame] | 306 | # |
mistachkin | bd58d5f | 2012-06-30 22:22:34 +0000 | [diff] [blame] | 307 | # Prevent warnings about "deprecated" POSIX functions being used. |
| 308 | # |
| 309 | TCC = $(TCC) -D_CRT_NONSTDC_NO_DEPRECATE -D_CRT_NONSTDC_NO_WARNINGS |
| 310 | BCC = $(BCC) -D_CRT_NONSTDC_NO_DEPRECATE -D_CRT_NONSTDC_NO_WARNINGS |
mistachkin | 4d9d1f4 | 2012-09-03 10:32:32 +0000 | [diff] [blame] | 311 | RCC = $(RCC) -D_CRT_NONSTDC_NO_DEPRECATE -D_CRT_NONSTDC_NO_WARNINGS |
mistachkin | bd58d5f | 2012-06-30 22:22:34 +0000 | [diff] [blame] | 312 | |
| 313 | # |
mistachkin | 2f7d5d8 | 2012-08-22 00:39:34 +0000 | [diff] [blame] | 314 | # Use the SQLite debugging heap subsystem? |
mistachkin | 1b186a9 | 2011-08-24 16:13:57 +0000 | [diff] [blame] | 315 | # |
mistachkin | 2f7d5d8 | 2012-08-22 00:39:34 +0000 | [diff] [blame] | 316 | !IF $(MEMDEBUG)!=0 |
| 317 | TCC = $(TCC) -DSQLITE_MEMDEBUG=1 |
mistachkin | 4d9d1f4 | 2012-09-03 10:32:32 +0000 | [diff] [blame] | 318 | RCC = $(RCC) -DSQLITE_MEMDEBUG=1 |
mistachkin | 2f7d5d8 | 2012-08-22 00:39:34 +0000 | [diff] [blame] | 319 | |
| 320 | # |
| 321 | # Use native Win32 heap subsystem instead of malloc/free? |
| 322 | # |
| 323 | !ELSEIF $(WIN32HEAP)!=0 |
| 324 | TCC = $(TCC) -DSQLITE_WIN32_MALLOC=1 |
mistachkin | 4d9d1f4 | 2012-09-03 10:32:32 +0000 | [diff] [blame] | 325 | RCC = $(RCC) -DSQLITE_WIN32_MALLOC=1 |
mistachkin | 753c544 | 2011-08-25 02:02:25 +0000 | [diff] [blame] | 326 | |
| 327 | # |
| 328 | # Validate the heap on every call into the native Win32 heap subsystem? |
| 329 | # |
| 330 | !IF $(DEBUG)>2 |
| 331 | TCC = $(TCC) -DSQLITE_WIN32_MALLOC_VALIDATE=1 |
mistachkin | 4d9d1f4 | 2012-09-03 10:32:32 +0000 | [diff] [blame] | 332 | RCC = $(RCC) -DSQLITE_WIN32_MALLOC_VALIDATE=1 |
mistachkin | 753c544 | 2011-08-25 02:02:25 +0000 | [diff] [blame] | 333 | !ENDIF |
mistachkin | 2f7d5d8 | 2012-08-22 00:39:34 +0000 | [diff] [blame] | 334 | !ENDIF |
mistachkin | 1b186a9 | 2011-08-24 16:13:57 +0000 | [diff] [blame] | 335 | |
mistachkin | 5b0b6fd | 2011-06-25 01:14:36 +0000 | [diff] [blame] | 336 | # The locations of the Tcl header and library files. Also, the library that |
| 337 | # non-stubs enabled programs using Tcl must link against. These variables |
| 338 | # (TCLINCDIR, TCLLIBDIR, and LIBTCL) may be overridden via the environment |
| 339 | # prior to running nmake in order to match the actual installed location and |
| 340 | # version on this machine. |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 341 | # |
mistachkin | e37f99c | 2012-06-30 16:22:05 +0000 | [diff] [blame] | 342 | !IFNDEF TCLINCDIR |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 343 | TCLINCDIR = c:\tcl\include |
mistachkin | e37f99c | 2012-06-30 16:22:05 +0000 | [diff] [blame] | 344 | !ENDIF |
mistachkin | 5b0b6fd | 2011-06-25 01:14:36 +0000 | [diff] [blame] | 345 | |
mistachkin | e37f99c | 2012-06-30 16:22:05 +0000 | [diff] [blame] | 346 | !IFNDEF TCLLIBDIR |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 347 | TCLLIBDIR = c:\tcl\lib |
mistachkin | e37f99c | 2012-06-30 16:22:05 +0000 | [diff] [blame] | 348 | !ENDIF |
mistachkin | 5b0b6fd | 2011-06-25 01:14:36 +0000 | [diff] [blame] | 349 | |
mistachkin | e37f99c | 2012-06-30 16:22:05 +0000 | [diff] [blame] | 350 | !IFNDEF LIBTCL |
mistachkin | 5b0b6fd | 2011-06-25 01:14:36 +0000 | [diff] [blame] | 351 | LIBTCL = tcl85.lib |
mistachkin | e37f99c | 2012-06-30 16:22:05 +0000 | [diff] [blame] | 352 | !ENDIF |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 353 | |
mistachkin | c756ded | 2011-10-02 05:23:16 +0000 | [diff] [blame] | 354 | # The locations of the ICU header and library files. These variables |
| 355 | # (ICUINCDIR, ICULIBDIR, and LIBICU) may be overridden via the environment |
| 356 | # prior to running nmake in order to match the actual installed location on |
| 357 | # this machine. |
| 358 | # |
mistachkin | e37f99c | 2012-06-30 16:22:05 +0000 | [diff] [blame] | 359 | !IFNDEF ICUINCDIR |
mistachkin | c756ded | 2011-10-02 05:23:16 +0000 | [diff] [blame] | 360 | ICUINCDIR = c:\icu\include |
mistachkin | e37f99c | 2012-06-30 16:22:05 +0000 | [diff] [blame] | 361 | !ENDIF |
mistachkin | c756ded | 2011-10-02 05:23:16 +0000 | [diff] [blame] | 362 | |
mistachkin | e37f99c | 2012-06-30 16:22:05 +0000 | [diff] [blame] | 363 | !IFNDEF ICULIBDIR |
mistachkin | c756ded | 2011-10-02 05:23:16 +0000 | [diff] [blame] | 364 | ICULIBDIR = c:\icu\lib |
mistachkin | e37f99c | 2012-06-30 16:22:05 +0000 | [diff] [blame] | 365 | !ENDIF |
mistachkin | c756ded | 2011-10-02 05:23:16 +0000 | [diff] [blame] | 366 | |
mistachkin | e37f99c | 2012-06-30 16:22:05 +0000 | [diff] [blame] | 367 | !IFNDEF LIBICU |
mistachkin | c756ded | 2011-10-02 05:23:16 +0000 | [diff] [blame] | 368 | LIBICU = icuuc.lib icuin.lib |
mistachkin | e37f99c | 2012-06-30 16:22:05 +0000 | [diff] [blame] | 369 | !ENDIF |
mistachkin | c756ded | 2011-10-02 05:23:16 +0000 | [diff] [blame] | 370 | |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 371 | # This is the command to use for tclsh - normally just "tclsh", but we may |
mistachkin | 5b0b6fd | 2011-06-25 01:14:36 +0000 | [diff] [blame] | 372 | # know the specific version we want to use. This variable (TCLSH_CMD) may be |
| 373 | # overridden via the environment prior to running nmake in order to select a |
| 374 | # specific Tcl shell to use. |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 375 | # |
mistachkin | e37f99c | 2012-06-30 16:22:05 +0000 | [diff] [blame] | 376 | !IFNDEF TCLSH_CMD |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 377 | TCLSH_CMD = tclsh85 |
mistachkin | e37f99c | 2012-06-30 16:22:05 +0000 | [diff] [blame] | 378 | !ENDIF |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 379 | |
| 380 | # Compiler options needed for programs that use the readline() library. |
| 381 | # |
mistachkin | 8bcd3fa | 2013-08-29 01:03:38 +0000 | [diff] [blame] | 382 | !IFNDEF READLINE_FLAGS |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 383 | READLINE_FLAGS = -DHAVE_READLINE=0 |
mistachkin | 8bcd3fa | 2013-08-29 01:03:38 +0000 | [diff] [blame] | 384 | !ENDIF |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 385 | |
| 386 | # The library that programs using readline() must link against. |
| 387 | # |
mistachkin | 8bcd3fa | 2013-08-29 01:03:38 +0000 | [diff] [blame] | 388 | !IFNDEF LIBREADLINE |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 389 | LIBREADLINE = |
mistachkin | 8bcd3fa | 2013-08-29 01:03:38 +0000 | [diff] [blame] | 390 | !ENDIF |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 391 | |
| 392 | # Should the database engine be compiled threadsafe |
| 393 | # |
| 394 | TCC = $(TCC) -DSQLITE_THREADSAFE=1 |
mistachkin | 4d9d1f4 | 2012-09-03 10:32:32 +0000 | [diff] [blame] | 395 | RCC = $(RCC) -DSQLITE_THREADSAFE=1 |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 396 | |
| 397 | # Do threads override each others locks by default (1), or do we test (-1) |
| 398 | # |
| 399 | TCC = $(TCC) -DSQLITE_THREAD_OVERRIDE_LOCK=-1 |
mistachkin | 4d9d1f4 | 2012-09-03 10:32:32 +0000 | [diff] [blame] | 400 | RCC = $(RCC) -DSQLITE_THREAD_OVERRIDE_LOCK=-1 |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 401 | |
| 402 | # Any target libraries which libsqlite must be linked against |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 403 | # |
mistachkin | e37f99c | 2012-06-30 16:22:05 +0000 | [diff] [blame] | 404 | !IFNDEF TLIBS |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 405 | TLIBS = |
mistachkin | e37f99c | 2012-06-30 16:22:05 +0000 | [diff] [blame] | 406 | !ENDIF |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 407 | |
| 408 | # Flags controlling use of the in memory btree implementation |
| 409 | # |
| 410 | # SQLITE_TEMP_STORE is 0 to force temporary tables to be in a file, 1 to |
| 411 | # default to file, 2 to default to memory, and 3 to force temporary |
| 412 | # tables to always be in memory. |
| 413 | # |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 414 | TCC = $(TCC) -DSQLITE_TEMP_STORE=1 |
mistachkin | 4d9d1f4 | 2012-09-03 10:32:32 +0000 | [diff] [blame] | 415 | RCC = $(RCC) -DSQLITE_TEMP_STORE=1 |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 416 | |
| 417 | # Enable/disable loadable extensions, and other optional features |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 418 | # based on configuration. (-DSQLITE_OMIT*, -DSQLITE_ENABLE*). |
| 419 | # The same set of OMIT and ENABLE flags should be passed to the |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 420 | # LEMON parser generator and the mkkeywordhash tool as well. |
| 421 | |
| 422 | # BEGIN standard options |
| 423 | OPT_FEATURE_FLAGS = $(OPT_FEATURE_FLAGS) -DSQLITE_ENABLE_FTS3=1 |
| 424 | OPT_FEATURE_FLAGS = $(OPT_FEATURE_FLAGS) -DSQLITE_ENABLE_RTREE=1 |
| 425 | OPT_FEATURE_FLAGS = $(OPT_FEATURE_FLAGS) -DSQLITE_ENABLE_COLUMN_METADATA=1 |
| 426 | # END standard options |
| 427 | |
| 428 | # BEGIN required Windows option |
| 429 | OPT_FEATURE_FLAGS = $(OPT_FEATURE_FLAGS) -DSQLITE_MAX_TRIGGER_DEPTH=100 |
| 430 | # END required Windows option |
| 431 | |
| 432 | TCC = $(TCC) $(OPT_FEATURE_FLAGS) |
mistachkin | 4d9d1f4 | 2012-09-03 10:32:32 +0000 | [diff] [blame] | 433 | RCC = $(RCC) $(OPT_FEATURE_FLAGS) |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 434 | |
| 435 | # Add in any optional parameters specified on the make commane line |
| 436 | # ie. make "OPTS=-DSQLITE_ENABLE_FOO=1 -DSQLITE_OMIT_FOO=1". |
| 437 | TCC = $(TCC) $(OPTS) |
mistachkin | 4d9d1f4 | 2012-09-03 10:32:32 +0000 | [diff] [blame] | 438 | RCC = $(RCC) $(OPTS) |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 439 | |
mistachkin | 8bcd3fa | 2013-08-29 01:03:38 +0000 | [diff] [blame] | 440 | # If compiling for debugging, add some defines. |
mistachkin | f2d25f2 | 2011-08-25 04:09:12 +0000 | [diff] [blame] | 441 | !IF $(DEBUG)>0 |
mistachkin | 8bcd3fa | 2013-08-29 01:03:38 +0000 | [diff] [blame] | 442 | TCC = $(TCC) -D_DEBUG |
| 443 | BCC = $(BCC) -D_DEBUG |
mistachkin | 4d9d1f4 | 2012-09-03 10:32:32 +0000 | [diff] [blame] | 444 | RCC = $(RCC) -D_DEBUG |
mistachkin | 4d60be5 | 2011-08-26 05:40:31 +0000 | [diff] [blame] | 445 | !ENDIF |
| 446 | |
mistachkin | 8bcd3fa | 2013-08-29 01:03:38 +0000 | [diff] [blame] | 447 | # If optimizations are enabled or disabled (either implicitly or |
| 448 | # explicitly), add the necessary flags. |
| 449 | !IF $(DEBUG)>0 || $(OPTIMIZATIONS)==0 |
| 450 | TCC = $(TCC) -Od |
| 451 | BCC = $(BCC) -Od |
| 452 | !ELSEIF $(OPTIMIZATIONS)>=3 |
| 453 | TCC = $(TCC) -Ox |
| 454 | BCC = $(BCC) -Ox |
| 455 | !ELSEIF $(OPTIMIZATIONS)==2 |
| 456 | TCC = $(TCC) -O2 |
| 457 | BCC = $(BCC) -O2 |
| 458 | !ELSEIF $(OPTIMIZATIONS)==1 |
| 459 | TCC = $(TCC) -O1 |
| 460 | BCC = $(BCC) -O1 |
| 461 | !ENDIF |
| 462 | |
| 463 | # If symbols are enabled (or compiling for debugging), enable PDBs. |
mistachkin | 4d60be5 | 2011-08-26 05:40:31 +0000 | [diff] [blame] | 464 | !IF $(DEBUG)>0 || $(SYMBOLS)!=0 |
| 465 | TCC = $(TCC) -Zi |
mistachkin | fec360a | 2012-04-18 10:29:21 +0000 | [diff] [blame] | 466 | BCC = $(BCC) -Zi |
mistachkin | 753c544 | 2011-08-25 02:02:25 +0000 | [diff] [blame] | 467 | !ENDIF |
| 468 | |
mistachkin | c756ded | 2011-10-02 05:23:16 +0000 | [diff] [blame] | 469 | # If ICU support is enabled, add the compiler options for it. |
| 470 | !IF $(USE_ICU)!=0 |
| 471 | TCC = $(TCC) -DSQLITE_ENABLE_ICU=1 |
mistachkin | 4d9d1f4 | 2012-09-03 10:32:32 +0000 | [diff] [blame] | 472 | RCC = $(RCC) -DSQLITE_ENABLE_ICU=1 |
mistachkin | c756ded | 2011-10-02 05:23:16 +0000 | [diff] [blame] | 473 | TCC = $(TCC) -I$(TOP)\ext\icu |
mistachkin | 4d9d1f4 | 2012-09-03 10:32:32 +0000 | [diff] [blame] | 474 | RCC = $(RCC) -I$(TOP)\ext\icu |
mistachkin | c756ded | 2011-10-02 05:23:16 +0000 | [diff] [blame] | 475 | TCC = $(TCC) -I$(ICUINCDIR) |
mistachkin | 4d9d1f4 | 2012-09-03 10:32:32 +0000 | [diff] [blame] | 476 | RCC = $(RCC) -I$(ICUINCDIR) |
mistachkin | c756ded | 2011-10-02 05:23:16 +0000 | [diff] [blame] | 477 | !ENDIF |
| 478 | |
mistachkin | 4d9d1f4 | 2012-09-03 10:32:32 +0000 | [diff] [blame] | 479 | # Command line prefixes for compiling code, compiling resources, |
| 480 | # linking, etc. |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 481 | LTCOMPILE = $(TCC) -Fo$@ |
mistachkin | 4d9d1f4 | 2012-09-03 10:32:32 +0000 | [diff] [blame] | 482 | LTRCOMPILE = $(RCC) -r |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 483 | LTLIB = lib.exe |
shaneh | 2a0b9ef | 2011-06-20 20:52:32 +0000 | [diff] [blame] | 484 | LTLINK = $(TCC) -Fe$@ |
| 485 | |
| 486 | # If a platform was set, force the linker to target that. |
| 487 | # Note that the vcvars*.bat family of batch files typically |
| 488 | # set this for you. Otherwise, the linker will attempt |
| 489 | # to deduce the binary type based on the object files. |
mistachkin | e37f99c | 2012-06-30 16:22:05 +0000 | [diff] [blame] | 490 | !IFDEF PLATFORM |
shaneh | 2a0b9ef | 2011-06-20 20:52:32 +0000 | [diff] [blame] | 491 | LTLINKOPTS = /MACHINE:$(PLATFORM) |
shaneh | 29ebea8 | 2011-06-21 18:12:07 +0000 | [diff] [blame] | 492 | LTLIBOPTS = /MACHINE:$(PLATFORM) |
shaneh | 2a0b9ef | 2011-06-20 20:52:32 +0000 | [diff] [blame] | 493 | !ENDIF |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 494 | |
mistachkin | a6ff857 | 2012-04-17 21:00:12 +0000 | [diff] [blame] | 495 | # When compiling for use in the WinRT environment, the following |
| 496 | # linker option must be used to mark the executable as runnable |
| 497 | # only in the context of an application container. |
| 498 | # |
| 499 | !IF $(FOR_WINRT)!=0 |
| 500 | LTLINKOPTS = $(LTLINKOPTS) /APPCONTAINER |
mistachkin | 60bdad7 | 2013-07-11 03:09:45 +0000 | [diff] [blame] | 501 | !IF "$(VISUALSTUDIOVERSION)"=="12.0" |
mistachkin | da5b1cd | 2013-07-10 19:39:02 +0000 | [diff] [blame] | 502 | !IF "$(PLATFORM)"=="x86" |
mistachkin | 4eaa129 | 2013-07-10 21:33:25 +0000 | [diff] [blame] | 503 | LTLINKOPTS = $(LTLINKOPTS) "/LIBPATH:$(VCINSTALLDIR)\lib\store" |
mistachkin | da5b1cd | 2013-07-10 19:39:02 +0000 | [diff] [blame] | 504 | !ELSEIF "$(PLATFORM)"=="x64" |
mistachkin | 4eaa129 | 2013-07-10 21:33:25 +0000 | [diff] [blame] | 505 | LTLINKOPTS = $(LTLINKOPTS) "/LIBPATH:$(VCINSTALLDIR)\lib\store\amd64" |
| 506 | !ELSEIF "$(PLATFORM)"=="ARM" |
| 507 | LTLINKOPTS = $(LTLINKOPTS) "/LIBPATH:$(VCINSTALLDIR)\lib\store\arm" |
| 508 | !ELSE |
| 509 | LTLINKOPTS = $(LTLINKOPTS) "/LIBPATH:$(VCINSTALLDIR)\lib\store" |
mistachkin | da5b1cd | 2013-07-10 19:39:02 +0000 | [diff] [blame] | 510 | !ENDIF |
| 511 | !ENDIF |
mistachkin | a6ff857 | 2012-04-17 21:00:12 +0000 | [diff] [blame] | 512 | !ENDIF |
| 513 | |
mistachkin | fec360a | 2012-04-18 10:29:21 +0000 | [diff] [blame] | 514 | # If either debugging or symbols are enabled, enable PDBs. |
mistachkin | 4d60be5 | 2011-08-26 05:40:31 +0000 | [diff] [blame] | 515 | !IF $(DEBUG)>0 || $(SYMBOLS)!=0 |
mistachkin | 228aeff | 2012-06-30 19:24:09 +0000 | [diff] [blame] | 516 | LDFLAGS = /DEBUG |
mistachkin | 753c544 | 2011-08-25 02:02:25 +0000 | [diff] [blame] | 517 | !ENDIF |
| 518 | |
mistachkin | c756ded | 2011-10-02 05:23:16 +0000 | [diff] [blame] | 519 | # Start with the Tcl related linker options. |
mistachkin | 31856a3 | 2012-07-27 07:13:25 +0000 | [diff] [blame] | 520 | !IF $(NO_TCL)==0 |
mistachkin | c756ded | 2011-10-02 05:23:16 +0000 | [diff] [blame] | 521 | LTLIBPATHS = /LIBPATH:$(TCLLIBDIR) |
| 522 | LTLIBS = $(LIBTCL) |
mistachkin | 31856a3 | 2012-07-27 07:13:25 +0000 | [diff] [blame] | 523 | !ENDIF |
mistachkin | c756ded | 2011-10-02 05:23:16 +0000 | [diff] [blame] | 524 | |
| 525 | # If ICU support is enabled, add the linker options for it. |
| 526 | !IF $(USE_ICU)!=0 |
| 527 | LTLIBPATHS = $(LTLIBPATHS) /LIBPATH:$(ICULIBDIR) |
| 528 | LTLIBS = $(LTLIBS) $(LIBICU) |
| 529 | !ENDIF |
| 530 | |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 531 | # nawk compatible awk. |
mistachkin | 8bcd3fa | 2013-08-29 01:03:38 +0000 | [diff] [blame] | 532 | !IFNDEF NAWK |
mistachkin | 5b0b6fd | 2011-06-25 01:14:36 +0000 | [diff] [blame] | 533 | NAWK = gawk.exe |
mistachkin | 8bcd3fa | 2013-08-29 01:03:38 +0000 | [diff] [blame] | 534 | !ENDIF |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 535 | |
| 536 | # You should not have to change anything below this line |
| 537 | ############################################################################### |
| 538 | |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 539 | # Object files for the SQLite library (non-amalgamation). |
| 540 | # |
mistachkin | f67feef | 2013-07-29 19:03:20 +0000 | [diff] [blame] | 541 | LIBOBJS0 = vdbe.lo parse.lo alter.lo analyze.lo attach.lo auth.lo \ |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 542 | backup.lo bitvec.lo btmutex.lo btree.lo build.lo \ |
| 543 | callback.lo complete.lo ctime.lo date.lo delete.lo \ |
| 544 | expr.lo fault.lo fkey.lo \ |
drh | 391d4ba | 2012-05-28 20:22:16 +0000 | [diff] [blame] | 545 | fts3.lo fts3_aux.lo fts3_expr.lo fts3_hash.lo fts3_icu.lo \ |
| 546 | fts3_porter.lo fts3_snippet.lo fts3_tokenizer.lo fts3_tokenizer1.lo \ |
drh | 4d648c7 | 2013-04-22 17:07:56 +0000 | [diff] [blame] | 547 | fts3_tokenize_vtab.lo fts3_unicode.lo fts3_unicode2.lo fts3_write.lo \ |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 548 | func.lo global.lo hash.lo \ |
| 549 | icu.lo insert.lo journal.lo legacy.lo loadext.lo \ |
| 550 | main.lo malloc.lo mem0.lo mem1.lo mem2.lo mem3.lo mem5.lo \ |
| 551 | memjournal.lo \ |
mistachkin | f1c6bc5 | 2012-06-21 15:09:20 +0000 | [diff] [blame] | 552 | mutex.lo mutex_noop.lo mutex_unix.lo mutex_w32.lo \ |
| 553 | notify.lo opcodes.lo os.lo os_unix.lo os_win.lo \ |
mistachkin | f67feef | 2013-07-29 19:03:20 +0000 | [diff] [blame] | 554 | pager.lo pcache.lo pcache1.lo pragma.lo prepare.lo printf.lo \ |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 555 | random.lo resolve.lo rowset.lo rtree.lo select.lo status.lo \ |
| 556 | table.lo tokenize.lo trigger.lo \ |
| 557 | update.lo util.lo vacuum.lo \ |
mistachkin | f67feef | 2013-07-29 19:03:20 +0000 | [diff] [blame] | 558 | vdbeapi.lo vdbeaux.lo vdbeblob.lo vdbemem.lo vdbesort.lo \ |
mistachkin | 81c428a | 2011-08-17 02:19:54 +0000 | [diff] [blame] | 559 | vdbetrace.lo wal.lo walker.lo where.lo utf.lo vtab.lo |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 560 | |
| 561 | # Object files for the amalgamation. |
| 562 | # |
| 563 | LIBOBJS1 = sqlite3.lo |
| 564 | |
| 565 | # Determine the real value of LIBOBJ based on the 'configure' script |
| 566 | # |
| 567 | !IF $(USE_AMALGAMATION)==0 |
| 568 | LIBOBJ = $(LIBOBJS0) |
| 569 | !ELSE |
| 570 | LIBOBJ = $(LIBOBJS1) |
| 571 | !ENDIF |
| 572 | |
mistachkin | 08c1c31 | 2012-10-06 03:48:25 +0000 | [diff] [blame] | 573 | # Determine if embedded resource compilation and usage are enabled. |
| 574 | # |
| 575 | !IF $(USE_RC)!=0 |
| 576 | LIBRESOBJS = sqlite3res.lo |
| 577 | !ELSE |
| 578 | LIBRESOBJS = |
| 579 | !ENDIF |
| 580 | |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 581 | # All of the source code files. |
| 582 | # |
| 583 | SRC = \ |
| 584 | $(TOP)\src\alter.c \ |
| 585 | $(TOP)\src\analyze.c \ |
| 586 | $(TOP)\src\attach.c \ |
| 587 | $(TOP)\src\auth.c \ |
| 588 | $(TOP)\src\backup.c \ |
| 589 | $(TOP)\src\bitvec.c \ |
| 590 | $(TOP)\src\btmutex.c \ |
| 591 | $(TOP)\src\btree.c \ |
| 592 | $(TOP)\src\btree.h \ |
| 593 | $(TOP)\src\btreeInt.h \ |
| 594 | $(TOP)\src\build.c \ |
| 595 | $(TOP)\src\callback.c \ |
| 596 | $(TOP)\src\complete.c \ |
| 597 | $(TOP)\src\ctime.c \ |
| 598 | $(TOP)\src\date.c \ |
| 599 | $(TOP)\src\delete.c \ |
| 600 | $(TOP)\src\expr.c \ |
| 601 | $(TOP)\src\fault.c \ |
| 602 | $(TOP)\src\fkey.c \ |
| 603 | $(TOP)\src\func.c \ |
| 604 | $(TOP)\src\global.c \ |
| 605 | $(TOP)\src\hash.c \ |
| 606 | $(TOP)\src\hash.h \ |
| 607 | $(TOP)\src\hwtime.h \ |
| 608 | $(TOP)\src\insert.c \ |
| 609 | $(TOP)\src\journal.c \ |
| 610 | $(TOP)\src\legacy.c \ |
| 611 | $(TOP)\src\loadext.c \ |
| 612 | $(TOP)\src\main.c \ |
| 613 | $(TOP)\src\malloc.c \ |
| 614 | $(TOP)\src\mem0.c \ |
| 615 | $(TOP)\src\mem1.c \ |
| 616 | $(TOP)\src\mem2.c \ |
| 617 | $(TOP)\src\mem3.c \ |
| 618 | $(TOP)\src\mem5.c \ |
| 619 | $(TOP)\src\memjournal.c \ |
| 620 | $(TOP)\src\mutex.c \ |
| 621 | $(TOP)\src\mutex.h \ |
| 622 | $(TOP)\src\mutex_noop.c \ |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 623 | $(TOP)\src\mutex_unix.c \ |
| 624 | $(TOP)\src\mutex_w32.c \ |
| 625 | $(TOP)\src\notify.c \ |
| 626 | $(TOP)\src\os.c \ |
| 627 | $(TOP)\src\os.h \ |
| 628 | $(TOP)\src\os_common.h \ |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 629 | $(TOP)\src\os_unix.c \ |
| 630 | $(TOP)\src\os_win.c \ |
| 631 | $(TOP)\src\pager.c \ |
| 632 | $(TOP)\src\pager.h \ |
| 633 | $(TOP)\src\parse.y \ |
| 634 | $(TOP)\src\pcache.c \ |
| 635 | $(TOP)\src\pcache.h \ |
| 636 | $(TOP)\src\pcache1.c \ |
| 637 | $(TOP)\src\pragma.c \ |
| 638 | $(TOP)\src\prepare.c \ |
| 639 | $(TOP)\src\printf.c \ |
| 640 | $(TOP)\src\random.c \ |
| 641 | $(TOP)\src\resolve.c \ |
| 642 | $(TOP)\src\rowset.c \ |
| 643 | $(TOP)\src\select.c \ |
| 644 | $(TOP)\src\status.c \ |
| 645 | $(TOP)\src\shell.c \ |
| 646 | $(TOP)\src\sqlite.h.in \ |
| 647 | $(TOP)\src\sqlite3ext.h \ |
| 648 | $(TOP)\src\sqliteInt.h \ |
| 649 | $(TOP)\src\sqliteLimit.h \ |
| 650 | $(TOP)\src\table.c \ |
| 651 | $(TOP)\src\tclsqlite.c \ |
| 652 | $(TOP)\src\tokenize.c \ |
| 653 | $(TOP)\src\trigger.c \ |
| 654 | $(TOP)\src\utf.c \ |
| 655 | $(TOP)\src\update.c \ |
| 656 | $(TOP)\src\util.c \ |
| 657 | $(TOP)\src\vacuum.c \ |
| 658 | $(TOP)\src\vdbe.c \ |
| 659 | $(TOP)\src\vdbe.h \ |
| 660 | $(TOP)\src\vdbeapi.c \ |
| 661 | $(TOP)\src\vdbeaux.c \ |
| 662 | $(TOP)\src\vdbeblob.c \ |
| 663 | $(TOP)\src\vdbemem.c \ |
mistachkin | 81c428a | 2011-08-17 02:19:54 +0000 | [diff] [blame] | 664 | $(TOP)\src\vdbesort.c \ |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 665 | $(TOP)\src\vdbetrace.c \ |
| 666 | $(TOP)\src\vdbeInt.h \ |
| 667 | $(TOP)\src\vtab.c \ |
| 668 | $(TOP)\src\wal.c \ |
| 669 | $(TOP)\src\wal.h \ |
| 670 | $(TOP)\src\walker.c \ |
drh | e54df42 | 2013-11-12 18:37:25 +0000 | [diff] [blame] | 671 | $(TOP)\src\where.c \ |
| 672 | $(TOP)\src\whereInt.h |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 673 | |
| 674 | # Source code for extensions |
| 675 | # |
| 676 | SRC = $(SRC) \ |
| 677 | $(TOP)\ext\fts1\fts1.c \ |
| 678 | $(TOP)\ext\fts1\fts1.h \ |
| 679 | $(TOP)\ext\fts1\fts1_hash.c \ |
| 680 | $(TOP)\ext\fts1\fts1_hash.h \ |
| 681 | $(TOP)\ext\fts1\fts1_porter.c \ |
| 682 | $(TOP)\ext\fts1\fts1_tokenizer.h \ |
| 683 | $(TOP)\ext\fts1\fts1_tokenizer1.c |
| 684 | SRC = $(SRC) \ |
| 685 | $(TOP)\ext\fts2\fts2.c \ |
| 686 | $(TOP)\ext\fts2\fts2.h \ |
| 687 | $(TOP)\ext\fts2\fts2_hash.c \ |
| 688 | $(TOP)\ext\fts2\fts2_hash.h \ |
| 689 | $(TOP)\ext\fts2\fts2_icu.c \ |
| 690 | $(TOP)\ext\fts2\fts2_porter.c \ |
| 691 | $(TOP)\ext\fts2\fts2_tokenizer.h \ |
| 692 | $(TOP)\ext\fts2\fts2_tokenizer.c \ |
| 693 | $(TOP)\ext\fts2\fts2_tokenizer1.c |
| 694 | SRC = $(SRC) \ |
| 695 | $(TOP)\ext\fts3\fts3.c \ |
| 696 | $(TOP)\ext\fts3\fts3.h \ |
| 697 | $(TOP)\ext\fts3\fts3Int.h \ |
| 698 | $(TOP)\ext\fts3\fts3_aux.c \ |
| 699 | $(TOP)\ext\fts3\fts3_expr.c \ |
| 700 | $(TOP)\ext\fts3\fts3_hash.c \ |
| 701 | $(TOP)\ext\fts3\fts3_hash.h \ |
| 702 | $(TOP)\ext\fts3\fts3_icu.c \ |
| 703 | $(TOP)\ext\fts3\fts3_porter.c \ |
| 704 | $(TOP)\ext\fts3\fts3_snippet.c \ |
| 705 | $(TOP)\ext\fts3\fts3_tokenizer.h \ |
| 706 | $(TOP)\ext\fts3\fts3_tokenizer.c \ |
| 707 | $(TOP)\ext\fts3\fts3_tokenizer1.c \ |
drh | 4d648c7 | 2013-04-22 17:07:56 +0000 | [diff] [blame] | 708 | $(TOP)\ext\fts3\fts3_tokenize_vtab.c \ |
drh | 391d4ba | 2012-05-28 20:22:16 +0000 | [diff] [blame] | 709 | $(TOP)\ext\fts3\fts3_unicode.c \ |
| 710 | $(TOP)\ext\fts3\fts3_unicode2.c \ |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 711 | $(TOP)\ext\fts3\fts3_write.c |
| 712 | SRC = $(SRC) \ |
| 713 | $(TOP)\ext\icu\sqliteicu.h \ |
| 714 | $(TOP)\ext\icu\icu.c |
| 715 | SRC = $(SRC) \ |
| 716 | $(TOP)\ext\rtree\rtree.h \ |
| 717 | $(TOP)\ext\rtree\rtree.c |
| 718 | |
| 719 | |
| 720 | # Generated source code files |
| 721 | # |
| 722 | SRC = $(SRC) \ |
| 723 | keywordhash.h \ |
| 724 | opcodes.c \ |
| 725 | opcodes.h \ |
| 726 | parse.c \ |
| 727 | parse.h \ |
| 728 | sqlite3.h |
| 729 | |
| 730 | # Source code to the test files. |
| 731 | # |
| 732 | TESTSRC = \ |
| 733 | $(TOP)\src\test1.c \ |
| 734 | $(TOP)\src\test2.c \ |
| 735 | $(TOP)\src\test3.c \ |
| 736 | $(TOP)\src\test4.c \ |
| 737 | $(TOP)\src\test5.c \ |
| 738 | $(TOP)\src\test6.c \ |
| 739 | $(TOP)\src\test7.c \ |
| 740 | $(TOP)\src\test8.c \ |
| 741 | $(TOP)\src\test9.c \ |
| 742 | $(TOP)\src\test_autoext.c \ |
| 743 | $(TOP)\src\test_async.c \ |
| 744 | $(TOP)\src\test_backup.c \ |
| 745 | $(TOP)\src\test_btree.c \ |
| 746 | $(TOP)\src\test_config.c \ |
| 747 | $(TOP)\src\test_demovfs.c \ |
| 748 | $(TOP)\src\test_devsym.c \ |
mistachkin | 413c63b | 2013-01-17 03:18:14 +0000 | [diff] [blame] | 749 | $(TOP)\src\test_fs.c \ |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 750 | $(TOP)\src\test_func.c \ |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 751 | $(TOP)\src\test_hexio.c \ |
| 752 | $(TOP)\src\test_init.c \ |
| 753 | $(TOP)\src\test_intarray.c \ |
| 754 | $(TOP)\src\test_journal.c \ |
| 755 | $(TOP)\src\test_malloc.c \ |
| 756 | $(TOP)\src\test_multiplex.c \ |
| 757 | $(TOP)\src\test_mutex.c \ |
| 758 | $(TOP)\src\test_onefile.c \ |
| 759 | $(TOP)\src\test_osinst.c \ |
| 760 | $(TOP)\src\test_pcache.c \ |
| 761 | $(TOP)\src\test_quota.c \ |
| 762 | $(TOP)\src\test_rtree.c \ |
| 763 | $(TOP)\src\test_schema.c \ |
| 764 | $(TOP)\src\test_server.c \ |
| 765 | $(TOP)\src\test_superlock.c \ |
| 766 | $(TOP)\src\test_syscall.c \ |
| 767 | $(TOP)\src\test_stat.c \ |
| 768 | $(TOP)\src\test_tclvar.c \ |
| 769 | $(TOP)\src\test_thread.c \ |
| 770 | $(TOP)\src\test_vfs.c \ |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 771 | $(TOP)\src\test_wsd.c \ |
| 772 | $(TOP)\ext\fts3\fts3_term.c \ |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 773 | $(TOP)\ext\fts3\fts3_test.c |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 774 | |
drh | e50db1c | 2013-04-25 14:31:46 +0000 | [diff] [blame] | 775 | # Statically linked extensions |
| 776 | # |
drh | 1fb64af | 2013-04-25 14:36:28 +0000 | [diff] [blame] | 777 | TESTEXT = \ |
drh | 8416fc7 | 2013-04-25 16:42:55 +0000 | [diff] [blame] | 778 | $(TOP)\ext\misc\amatch.c \ |
| 779 | $(TOP)\ext\misc\closure.c \ |
drh | e50db1c | 2013-04-25 14:31:46 +0000 | [diff] [blame] | 780 | $(TOP)\ext\misc\fuzzer.c \ |
drh | 8416fc7 | 2013-04-25 16:42:55 +0000 | [diff] [blame] | 781 | $(TOP)\ext\misc\ieee754.c \ |
drh | ea41dc4 | 2013-04-25 19:31:33 +0000 | [diff] [blame] | 782 | $(TOP)\ext\misc\nextchar.c \ |
drh | def3367 | 2013-05-28 20:25:54 +0000 | [diff] [blame] | 783 | $(TOP)\ext\misc\percentile.c \ |
drh | e50db1c | 2013-04-25 14:31:46 +0000 | [diff] [blame] | 784 | $(TOP)\ext\misc\regexp.c \ |
drh | b7045ab | 2013-04-25 14:59:01 +0000 | [diff] [blame] | 785 | $(TOP)\ext\misc\spellfix.c \ |
drh | 5f8cdac | 2013-10-14 21:14:42 +0000 | [diff] [blame] | 786 | $(TOP)\ext\misc\totype.c \ |
drh | e50db1c | 2013-04-25 14:31:46 +0000 | [diff] [blame] | 787 | $(TOP)\ext\misc\wholenumber.c |
| 788 | |
| 789 | |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 790 | # Source code to the library files needed by the test fixture |
| 791 | # |
| 792 | TESTSRC2 = \ |
| 793 | $(TOP)\src\attach.c \ |
| 794 | $(TOP)\src\backup.c \ |
| 795 | $(TOP)\src\bitvec.c \ |
| 796 | $(TOP)\src\btree.c \ |
| 797 | $(TOP)\src\build.c \ |
| 798 | $(TOP)\src\ctime.c \ |
| 799 | $(TOP)\src\date.c \ |
| 800 | $(TOP)\src\expr.c \ |
| 801 | $(TOP)\src\func.c \ |
| 802 | $(TOP)\src\insert.c \ |
| 803 | $(TOP)\src\wal.c \ |
mistachkin | 0600663 | 2013-05-15 20:35:13 +0000 | [diff] [blame] | 804 | $(TOP)\src\main.c \ |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 805 | $(TOP)\src\mem5.c \ |
| 806 | $(TOP)\src\os.c \ |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 807 | $(TOP)\src\os_unix.c \ |
| 808 | $(TOP)\src\os_win.c \ |
| 809 | $(TOP)\src\pager.c \ |
| 810 | $(TOP)\src\pragma.c \ |
| 811 | $(TOP)\src\prepare.c \ |
| 812 | $(TOP)\src\printf.c \ |
| 813 | $(TOP)\src\random.c \ |
| 814 | $(TOP)\src\pcache.c \ |
| 815 | $(TOP)\src\pcache1.c \ |
| 816 | $(TOP)\src\select.c \ |
| 817 | $(TOP)\src\tokenize.c \ |
| 818 | $(TOP)\src\utf.c \ |
| 819 | $(TOP)\src\util.c \ |
| 820 | $(TOP)\src\vdbeapi.c \ |
| 821 | $(TOP)\src\vdbeaux.c \ |
| 822 | $(TOP)\src\vdbe.c \ |
| 823 | $(TOP)\src\vdbemem.c \ |
mistachkin | 81c428a | 2011-08-17 02:19:54 +0000 | [diff] [blame] | 824 | $(TOP)\src\vdbesort.c \ |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 825 | $(TOP)\src\vdbetrace.c \ |
| 826 | $(TOP)\src\where.c \ |
| 827 | parse.c \ |
| 828 | $(TOP)\ext\fts3\fts3.c \ |
| 829 | $(TOP)\ext\fts3\fts3_aux.c \ |
| 830 | $(TOP)\ext\fts3\fts3_expr.c \ |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 831 | $(TOP)\ext\fts3\fts3_tokenizer.c \ |
drh | 4d648c7 | 2013-04-22 17:07:56 +0000 | [diff] [blame] | 832 | $(TOP)\ext\fts3\fts3_tokenize_vtab.c \ |
drh | 391d4ba | 2012-05-28 20:22:16 +0000 | [diff] [blame] | 833 | $(TOP)\ext\fts3\fts3_unicode.c \ |
| 834 | $(TOP)\ext\fts3\fts3_unicode2.c \ |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 835 | $(TOP)\ext\fts3\fts3_write.c \ |
| 836 | $(TOP)\ext\async\sqlite3async.c |
| 837 | |
| 838 | # Header files used by all library source files. |
| 839 | # |
| 840 | HDR = \ |
| 841 | $(TOP)\src\btree.h \ |
| 842 | $(TOP)\src\btreeInt.h \ |
| 843 | $(TOP)\src\hash.h \ |
| 844 | $(TOP)\src\hwtime.h \ |
| 845 | keywordhash.h \ |
| 846 | $(TOP)\src\mutex.h \ |
| 847 | opcodes.h \ |
| 848 | $(TOP)\src\os.h \ |
| 849 | $(TOP)\src\os_common.h \ |
| 850 | $(TOP)\src\pager.h \ |
| 851 | $(TOP)\src\pcache.h \ |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 852 | parse.h \ |
| 853 | sqlite3.h \ |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 854 | $(TOP)\src\sqlite3ext.h \ |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 855 | $(TOP)\src\sqliteInt.h \ |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 856 | $(TOP)\src\sqliteLimit.h \ |
| 857 | $(TOP)\src\vdbe.h \ |
drh | e54df42 | 2013-11-12 18:37:25 +0000 | [diff] [blame] | 858 | $(TOP)\src\vdbeInt.h \ |
| 859 | $(TOP)\src\whereInt.h |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 860 | |
| 861 | # Header files used by extensions |
| 862 | # |
| 863 | EXTHDR = $(EXTHDR) \ |
| 864 | $(TOP)\ext\fts1\fts1.h \ |
| 865 | $(TOP)\ext\fts1\fts1_hash.h \ |
| 866 | $(TOP)\ext\fts1\fts1_tokenizer.h |
| 867 | EXTHDR = $(EXTHDR) \ |
| 868 | $(TOP)\ext\fts2\fts2.h \ |
| 869 | $(TOP)\ext\fts2\fts2_hash.h \ |
| 870 | $(TOP)\ext\fts2\fts2_tokenizer.h |
| 871 | EXTHDR = $(EXTHDR) \ |
| 872 | $(TOP)\ext\fts3\fts3.h \ |
| 873 | $(TOP)\ext\fts3\fts3Int.h \ |
| 874 | $(TOP)\ext\fts3\fts3_hash.h \ |
| 875 | $(TOP)\ext\fts3\fts3_tokenizer.h |
| 876 | EXTHDR = $(EXTHDR) \ |
| 877 | $(TOP)\ext\rtree\rtree.h |
| 878 | EXTHDR = $(EXTHDR) \ |
| 879 | $(TOP)\ext\icu\sqliteicu.h |
| 880 | EXTHDR = $(EXTHDR) \ |
| 881 | $(TOP)\ext\rtree\sqlite3rtree.h |
| 882 | |
| 883 | # This is the default Makefile target. The objects listed here |
| 884 | # are what get build when you type just "make" with no arguments. |
| 885 | # |
mistachkin | 5b0b6fd | 2011-06-25 01:14:36 +0000 | [diff] [blame] | 886 | all: dll libsqlite3.lib sqlite3.exe libtclsqlite3.lib |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 887 | |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 888 | libsqlite3.lib: $(LIBOBJ) |
shaneh | 29ebea8 | 2011-06-21 18:12:07 +0000 | [diff] [blame] | 889 | $(LTLIB) $(LTLIBOPTS) /OUT:$@ $(LIBOBJ) $(TLIBS) |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 890 | |
| 891 | libtclsqlite3.lib: tclsqlite.lo libsqlite3.lib |
mistachkin | c756ded | 2011-10-02 05:23:16 +0000 | [diff] [blame] | 892 | $(LTLIB) $(LTLIBOPTS) $(LTLIBPATHS) /OUT:$@ tclsqlite.lo libsqlite3.lib $(LIBTCL:tcl=tclstub) $(TLIBS) |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 893 | |
mistachkin | 08c1c31 | 2012-10-06 03:48:25 +0000 | [diff] [blame] | 894 | sqlite3.exe: $(TOP)\src\shell.c libsqlite3.lib $(LIBRESOBJS) sqlite3.h |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 895 | $(LTLINK) $(READLINE_FLAGS) \ |
shaneh | 2a0b9ef | 2011-06-20 20:52:32 +0000 | [diff] [blame] | 896 | $(TOP)\src\shell.c \ |
mistachkin | 08c1c31 | 2012-10-06 03:48:25 +0000 | [diff] [blame] | 897 | /link $(LTLINKOPTS) $(LTLIBPATHS) libsqlite3.lib $(LIBRESOBJS) $(LIBREADLINE) $(LTLIBS) $(TLIBS) |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 898 | |
drh | bc94dbb | 2013-04-08 14:28:33 +0000 | [diff] [blame] | 899 | mptester.exe: $(TOP)\mptest\mptest.c libsqlite3.lib $(LIBRESOBJS) sqlite3.h |
| 900 | $(LTLINK) $(TOP)\mptest\mptest.c \ |
| 901 | /link $(LTLINKOPTS) $(LTLIBPATHS) libsqlite3.lib $(LIBRESOBJS) $(LIBREADLINE) $(LTLIBS) $(TLIBS) |
| 902 | |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 903 | # This target creates a directory named "tsrc" and fills it with |
| 904 | # copies of all of the C source code and header files needed to |
| 905 | # build on the target system. Some of the C source code and header |
| 906 | # files are automatically generated. This target takes care of |
| 907 | # all that automatic generation. |
| 908 | # |
| 909 | .target_source: $(SRC) $(TOP)\tool\vdbe-compress.tcl |
| 910 | -rmdir /S/Q tsrc |
| 911 | -mkdir tsrc |
| 912 | for %i in ($(SRC)) do copy /Y %i tsrc |
| 913 | del /Q tsrc\sqlite.h.in tsrc\parse.y |
drh | 2dc0648 | 2013-12-11 00:59:10 +0000 | [diff] [blame] | 914 | $(TCLSH_CMD) $(TOP)\tool\vdbe-compress.tcl $(OPTS) < tsrc\vdbe.c > vdbe.new |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 915 | move vdbe.new tsrc\vdbe.c |
| 916 | echo > .target_source |
| 917 | |
| 918 | sqlite3.c: .target_source $(TOP)\tool\mksqlite3c.tcl |
| 919 | $(TCLSH_CMD) $(TOP)\tool\mksqlite3c.tcl |
drh | 339d6c6 | 2013-03-19 16:12:40 +0000 | [diff] [blame] | 920 | copy tsrc\shell.c . |
| 921 | copy tsrc\sqlite3ext.h . |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 922 | |
mistachkin | 48dd9de | 2012-12-06 04:33:13 +0000 | [diff] [blame] | 923 | sqlite3-all.c: sqlite3.c $(TOP)\tool\split-sqlite3c.tcl |
| 924 | $(TCLSH_CMD) $(TOP)\tool\split-sqlite3c.tcl |
drh | 75e7bc1 | 2011-07-22 11:23:49 +0000 | [diff] [blame] | 925 | |
mistachkin | 7651091 | 2013-10-11 23:01:18 +0000 | [diff] [blame] | 926 | # Set the source code file to be used by executables and libraries when |
| 927 | # they need the amalgamation. |
| 928 | # |
| 929 | !IF $(SPLIT_AMALGAMATION)!=0 |
| 930 | SQLITE3C = sqlite3-all.c |
| 931 | !ELSE |
| 932 | SQLITE3C = sqlite3.c |
| 933 | !ENDIF |
| 934 | |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 935 | # Rule to build the amalgamation |
| 936 | # |
mistachkin | 7651091 | 2013-10-11 23:01:18 +0000 | [diff] [blame] | 937 | sqlite3.lo: $(SQLITE3C) |
| 938 | $(LTCOMPILE) -c $(SQLITE3C) |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 939 | |
| 940 | # Rules to build the LEMON compiler generator |
| 941 | # |
| 942 | lempar.c: $(TOP)\src\lempar.c |
| 943 | copy $(TOP)\src\lempar.c . |
| 944 | |
| 945 | lemon.exe: $(TOP)\tool\lemon.c lempar.c |
mistachkin | bd58d5f | 2012-06-30 22:22:34 +0000 | [diff] [blame] | 946 | $(BCC) -Daccess=_access -Fe$@ $(TOP)\tool\lemon.c /link $(NLTLIBPATHS) |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 947 | |
| 948 | # Rules to build individual *.lo files from generated *.c files. This |
| 949 | # applies to: |
| 950 | # |
| 951 | # parse.lo |
| 952 | # opcodes.lo |
| 953 | # |
| 954 | parse.lo: parse.c $(HDR) |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 955 | $(LTCOMPILE) -c parse.c |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 956 | |
| 957 | opcodes.lo: opcodes.c |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 958 | $(LTCOMPILE) -c opcodes.c |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 959 | |
mistachkin | 4d9d1f4 | 2012-09-03 10:32:32 +0000 | [diff] [blame] | 960 | # Rule to build the Win32 resources object file. |
| 961 | # |
mistachkin | 08c1c31 | 2012-10-06 03:48:25 +0000 | [diff] [blame] | 962 | !IF $(USE_RC)!=0 |
| 963 | $(LIBRESOBJS): $(TOP)\src\sqlite3.rc $(HDR) |
mistachkin | 4d9d1f4 | 2012-09-03 10:32:32 +0000 | [diff] [blame] | 964 | echo #ifndef SQLITE_RESOURCE_VERSION > sqlite3rc.h |
mistachkin | 8ccc6d4 | 2012-09-27 21:03:53 +0000 | [diff] [blame] | 965 | for /F %%V in ('type "$(TOP)\VERSION"') do ( \ |
mistachkin | 4d9d1f4 | 2012-09-03 10:32:32 +0000 | [diff] [blame] | 966 | echo #define SQLITE_RESOURCE_VERSION %%V \ |
mistachkin | 597a8c5 | 2012-09-03 11:14:53 +0000 | [diff] [blame] | 967 | | $(NAWK) "/.*/ { gsub(/[.]/,\",\");print }" >> sqlite3rc.h \ |
mistachkin | 4d9d1f4 | 2012-09-03 10:32:32 +0000 | [diff] [blame] | 968 | ) |
| 969 | echo #endif >> sqlite3rc.h |
mistachkin | 08c1c31 | 2012-10-06 03:48:25 +0000 | [diff] [blame] | 970 | $(LTRCOMPILE) -fo $(LIBRESOBJS) $(TOP)\src\sqlite3.rc |
| 971 | !ENDIF |
mistachkin | 4d9d1f4 | 2012-09-03 10:32:32 +0000 | [diff] [blame] | 972 | |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 973 | # Rules to build individual *.lo files from files in the src directory. |
| 974 | # |
| 975 | alter.lo: $(TOP)\src\alter.c $(HDR) |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 976 | $(LTCOMPILE) -c $(TOP)\src\alter.c |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 977 | |
| 978 | analyze.lo: $(TOP)\src\analyze.c $(HDR) |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 979 | $(LTCOMPILE) -c $(TOP)\src\analyze.c |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 980 | |
| 981 | attach.lo: $(TOP)\src\attach.c $(HDR) |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 982 | $(LTCOMPILE) -c $(TOP)\src\attach.c |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 983 | |
| 984 | auth.lo: $(TOP)\src\auth.c $(HDR) |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 985 | $(LTCOMPILE) -c $(TOP)\src\auth.c |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 986 | |
| 987 | backup.lo: $(TOP)\src\backup.c $(HDR) |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 988 | $(LTCOMPILE) -c $(TOP)\src\backup.c |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 989 | |
| 990 | bitvec.lo: $(TOP)\src\bitvec.c $(HDR) |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 991 | $(LTCOMPILE) -c $(TOP)\src\bitvec.c |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 992 | |
| 993 | btmutex.lo: $(TOP)\src\btmutex.c $(HDR) |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 994 | $(LTCOMPILE) -c $(TOP)\src\btmutex.c |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 995 | |
| 996 | btree.lo: $(TOP)\src\btree.c $(HDR) $(TOP)\src\pager.h |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 997 | $(LTCOMPILE) -c $(TOP)\src\btree.c |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 998 | |
| 999 | build.lo: $(TOP)\src\build.c $(HDR) |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 1000 | $(LTCOMPILE) -c $(TOP)\src\build.c |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1001 | |
| 1002 | callback.lo: $(TOP)\src\callback.c $(HDR) |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 1003 | $(LTCOMPILE) -c $(TOP)\src\callback.c |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1004 | |
| 1005 | complete.lo: $(TOP)\src\complete.c $(HDR) |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 1006 | $(LTCOMPILE) -c $(TOP)\src\complete.c |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1007 | |
| 1008 | ctime.lo: $(TOP)\src\ctime.c $(HDR) |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 1009 | $(LTCOMPILE) -c $(TOP)\src\ctime.c |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1010 | |
| 1011 | date.lo: $(TOP)\src\date.c $(HDR) |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 1012 | $(LTCOMPILE) -c $(TOP)\src\date.c |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1013 | |
| 1014 | delete.lo: $(TOP)\src\delete.c $(HDR) |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 1015 | $(LTCOMPILE) -c $(TOP)\src\delete.c |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1016 | |
| 1017 | expr.lo: $(TOP)\src\expr.c $(HDR) |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 1018 | $(LTCOMPILE) -c $(TOP)\src\expr.c |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1019 | |
| 1020 | fault.lo: $(TOP)\src\fault.c $(HDR) |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 1021 | $(LTCOMPILE) -c $(TOP)\src\fault.c |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1022 | |
| 1023 | fkey.lo: $(TOP)\src\fkey.c $(HDR) |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 1024 | $(LTCOMPILE) -c $(TOP)\src\fkey.c |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1025 | |
| 1026 | func.lo: $(TOP)\src\func.c $(HDR) |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 1027 | $(LTCOMPILE) -c $(TOP)\src\func.c |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1028 | |
| 1029 | global.lo: $(TOP)\src\global.c $(HDR) |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 1030 | $(LTCOMPILE) -c $(TOP)\src\global.c |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1031 | |
| 1032 | hash.lo: $(TOP)\src\hash.c $(HDR) |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 1033 | $(LTCOMPILE) -c $(TOP)\src\hash.c |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1034 | |
| 1035 | insert.lo: $(TOP)\src\insert.c $(HDR) |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 1036 | $(LTCOMPILE) -c $(TOP)\src\insert.c |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1037 | |
| 1038 | journal.lo: $(TOP)\src\journal.c $(HDR) |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 1039 | $(LTCOMPILE) -c $(TOP)\src\journal.c |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1040 | |
| 1041 | legacy.lo: $(TOP)\src\legacy.c $(HDR) |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 1042 | $(LTCOMPILE) -c $(TOP)\src\legacy.c |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1043 | |
| 1044 | loadext.lo: $(TOP)\src\loadext.c $(HDR) |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 1045 | $(LTCOMPILE) -c $(TOP)\src\loadext.c |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1046 | |
| 1047 | main.lo: $(TOP)\src\main.c $(HDR) |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 1048 | $(LTCOMPILE) -c $(TOP)\src\main.c |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1049 | |
| 1050 | malloc.lo: $(TOP)\src\malloc.c $(HDR) |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 1051 | $(LTCOMPILE) -c $(TOP)\src\malloc.c |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1052 | |
| 1053 | mem0.lo: $(TOP)\src\mem0.c $(HDR) |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 1054 | $(LTCOMPILE) -c $(TOP)\src\mem0.c |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1055 | |
| 1056 | mem1.lo: $(TOP)\src\mem1.c $(HDR) |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 1057 | $(LTCOMPILE) -c $(TOP)\src\mem1.c |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1058 | |
| 1059 | mem2.lo: $(TOP)\src\mem2.c $(HDR) |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 1060 | $(LTCOMPILE) -c $(TOP)\src\mem2.c |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1061 | |
| 1062 | mem3.lo: $(TOP)\src\mem3.c $(HDR) |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 1063 | $(LTCOMPILE) -c $(TOP)\src\mem3.c |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1064 | |
| 1065 | mem5.lo: $(TOP)\src\mem5.c $(HDR) |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 1066 | $(LTCOMPILE) -c $(TOP)\src\mem5.c |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1067 | |
| 1068 | memjournal.lo: $(TOP)\src\memjournal.c $(HDR) |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 1069 | $(LTCOMPILE) -c $(TOP)\src\memjournal.c |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1070 | |
| 1071 | mutex.lo: $(TOP)\src\mutex.c $(HDR) |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 1072 | $(LTCOMPILE) -c $(TOP)\src\mutex.c |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1073 | |
| 1074 | mutex_noop.lo: $(TOP)\src\mutex_noop.c $(HDR) |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 1075 | $(LTCOMPILE) -c $(TOP)\src\mutex_noop.c |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1076 | |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1077 | mutex_unix.lo: $(TOP)\src\mutex_unix.c $(HDR) |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 1078 | $(LTCOMPILE) -c $(TOP)\src\mutex_unix.c |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1079 | |
| 1080 | mutex_w32.lo: $(TOP)\src\mutex_w32.c $(HDR) |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 1081 | $(LTCOMPILE) -c $(TOP)\src\mutex_w32.c |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1082 | |
| 1083 | notify.lo: $(TOP)\src\notify.c $(HDR) |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 1084 | $(LTCOMPILE) -c $(TOP)\src\notify.c |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1085 | |
| 1086 | pager.lo: $(TOP)\src\pager.c $(HDR) $(TOP)\src\pager.h |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 1087 | $(LTCOMPILE) -c $(TOP)\src\pager.c |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1088 | |
| 1089 | pcache.lo: $(TOP)\src\pcache.c $(HDR) $(TOP)\src\pcache.h |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 1090 | $(LTCOMPILE) -c $(TOP)\src\pcache.c |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1091 | |
| 1092 | pcache1.lo: $(TOP)\src\pcache1.c $(HDR) $(TOP)\src\pcache.h |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 1093 | $(LTCOMPILE) -c $(TOP)\src\pcache1.c |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1094 | |
| 1095 | os.lo: $(TOP)\src\os.c $(HDR) |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 1096 | $(LTCOMPILE) -c $(TOP)\src\os.c |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1097 | |
| 1098 | os_unix.lo: $(TOP)\src\os_unix.c $(HDR) |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 1099 | $(LTCOMPILE) -c $(TOP)\src\os_unix.c |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1100 | |
| 1101 | os_win.lo: $(TOP)\src\os_win.c $(HDR) |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 1102 | $(LTCOMPILE) -c $(TOP)\src\os_win.c |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1103 | |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1104 | pragma.lo: $(TOP)\src\pragma.c $(HDR) |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 1105 | $(LTCOMPILE) -c $(TOP)\src\pragma.c |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1106 | |
| 1107 | prepare.lo: $(TOP)\src\prepare.c $(HDR) |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 1108 | $(LTCOMPILE) -c $(TOP)\src\prepare.c |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1109 | |
| 1110 | printf.lo: $(TOP)\src\printf.c $(HDR) |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 1111 | $(LTCOMPILE) -c $(TOP)\src\printf.c |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1112 | |
| 1113 | random.lo: $(TOP)\src\random.c $(HDR) |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 1114 | $(LTCOMPILE) -c $(TOP)\src\random.c |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1115 | |
| 1116 | resolve.lo: $(TOP)\src\resolve.c $(HDR) |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 1117 | $(LTCOMPILE) -c $(TOP)\src\resolve.c |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1118 | |
| 1119 | rowset.lo: $(TOP)\src\rowset.c $(HDR) |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 1120 | $(LTCOMPILE) -c $(TOP)\src\rowset.c |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1121 | |
| 1122 | select.lo: $(TOP)\src\select.c $(HDR) |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 1123 | $(LTCOMPILE) -c $(TOP)\src\select.c |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1124 | |
| 1125 | status.lo: $(TOP)\src\status.c $(HDR) |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 1126 | $(LTCOMPILE) -c $(TOP)\src\status.c |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1127 | |
| 1128 | table.lo: $(TOP)\src\table.c $(HDR) |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 1129 | $(LTCOMPILE) -c $(TOP)\src\table.c |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1130 | |
| 1131 | tokenize.lo: $(TOP)\src\tokenize.c keywordhash.h $(HDR) |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 1132 | $(LTCOMPILE) -c $(TOP)\src\tokenize.c |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1133 | |
| 1134 | trigger.lo: $(TOP)\src\trigger.c $(HDR) |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 1135 | $(LTCOMPILE) -c $(TOP)\src\trigger.c |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1136 | |
| 1137 | update.lo: $(TOP)\src\update.c $(HDR) |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 1138 | $(LTCOMPILE) -c $(TOP)\src\update.c |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1139 | |
| 1140 | utf.lo: $(TOP)\src\utf.c $(HDR) |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 1141 | $(LTCOMPILE) -c $(TOP)\src\utf.c |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1142 | |
| 1143 | util.lo: $(TOP)\src\util.c $(HDR) |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 1144 | $(LTCOMPILE) -c $(TOP)\src\util.c |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1145 | |
| 1146 | vacuum.lo: $(TOP)\src\vacuum.c $(HDR) |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 1147 | $(LTCOMPILE) -c $(TOP)\src\vacuum.c |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1148 | |
| 1149 | vdbe.lo: $(TOP)\src\vdbe.c $(HDR) |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 1150 | $(LTCOMPILE) -c $(TOP)\src\vdbe.c |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1151 | |
| 1152 | vdbeapi.lo: $(TOP)\src\vdbeapi.c $(HDR) |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 1153 | $(LTCOMPILE) -c $(TOP)\src\vdbeapi.c |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1154 | |
| 1155 | vdbeaux.lo: $(TOP)\src\vdbeaux.c $(HDR) |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 1156 | $(LTCOMPILE) -c $(TOP)\src\vdbeaux.c |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1157 | |
| 1158 | vdbeblob.lo: $(TOP)\src\vdbeblob.c $(HDR) |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 1159 | $(LTCOMPILE) -c $(TOP)\src\vdbeblob.c |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1160 | |
| 1161 | vdbemem.lo: $(TOP)\src\vdbemem.c $(HDR) |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 1162 | $(LTCOMPILE) -c $(TOP)\src\vdbemem.c |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1163 | |
mistachkin | 81c428a | 2011-08-17 02:19:54 +0000 | [diff] [blame] | 1164 | vdbesort.lo: $(TOP)\src\vdbesort.c $(HDR) |
| 1165 | $(LTCOMPILE) -c $(TOP)\src\vdbesort.c |
| 1166 | |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1167 | vdbetrace.lo: $(TOP)\src\vdbetrace.c $(HDR) |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 1168 | $(LTCOMPILE) -c $(TOP)\src\vdbetrace.c |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1169 | |
| 1170 | vtab.lo: $(TOP)\src\vtab.c $(HDR) |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 1171 | $(LTCOMPILE) -c $(TOP)\src\vtab.c |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1172 | |
| 1173 | wal.lo: $(TOP)\src\wal.c $(HDR) |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 1174 | $(LTCOMPILE) -c $(TOP)\src\wal.c |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1175 | |
| 1176 | walker.lo: $(TOP)\src\walker.c $(HDR) |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 1177 | $(LTCOMPILE) -c $(TOP)\src\walker.c |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1178 | |
| 1179 | where.lo: $(TOP)\src\where.c $(HDR) |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 1180 | $(LTCOMPILE) -c $(TOP)\src\where.c |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1181 | |
| 1182 | tclsqlite.lo: $(TOP)\src\tclsqlite.c $(HDR) |
| 1183 | $(LTCOMPILE) -DUSE_TCL_STUBS=1 -DBUILD_sqlite -I$(TCLINCDIR) -c $(TOP)\src\tclsqlite.c |
| 1184 | |
| 1185 | tclsqlite-shell.lo: $(TOP)\src\tclsqlite.c $(HDR) |
| 1186 | $(LTCOMPILE) -DTCLSH=1 -DBUILD_sqlite -I$(TCLINCDIR) -c $(TOP)\src\tclsqlite.c |
| 1187 | |
mistachkin | 08c1c31 | 2012-10-06 03:48:25 +0000 | [diff] [blame] | 1188 | tclsqlite3.exe: tclsqlite-shell.lo libsqlite3.lib $(LIBRESOBJS) |
| 1189 | $(LD) $(LDFLAGS) $(LTLINKOPTS) $(LTLIBPATHS) /OUT:$@ libsqlite3.lib tclsqlite-shell.lo $(LIBRESOBJS) $(LTLIBS) $(TLIBS) |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1190 | |
| 1191 | # Rules to build opcodes.c and opcodes.h |
| 1192 | # |
| 1193 | opcodes.c: opcodes.h $(TOP)\mkopcodec.awk |
drh | 307ff30 | 2011-08-30 01:29:04 +0000 | [diff] [blame] | 1194 | $(NAWK) -f $(TOP)\mkopcodec.awk opcodes.h > opcodes.c |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1195 | |
| 1196 | opcodes.h: parse.h $(TOP)\src\vdbe.c $(TOP)\mkopcodeh.awk |
mistachkin | 5b0b6fd | 2011-06-25 01:14:36 +0000 | [diff] [blame] | 1197 | type parse.h $(TOP)\src\vdbe.c | $(NAWK) -f $(TOP)\mkopcodeh.awk > opcodes.h |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1198 | |
| 1199 | # Rules to build parse.c and parse.h - the outputs of lemon. |
| 1200 | # |
| 1201 | parse.h: parse.c |
| 1202 | |
| 1203 | parse.c: $(TOP)\src\parse.y lemon.exe $(TOP)\addopcodes.awk |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 1204 | del /Q parse.y parse.h parse.h.temp |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1205 | copy $(TOP)\src\parse.y . |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1206 | .\lemon.exe $(OPT_FEATURE_FLAGS) $(OPTS) parse.y |
| 1207 | move parse.h parse.h.temp |
mistachkin | 5b0b6fd | 2011-06-25 01:14:36 +0000 | [diff] [blame] | 1208 | $(NAWK) -f $(TOP)\addopcodes.awk parse.h.temp > parse.h |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1209 | |
| 1210 | sqlite3.h: $(TOP)\src\sqlite.h.in $(TOP)\manifest.uuid $(TOP)\VERSION |
mistachkin | 5b0b6fd | 2011-06-25 01:14:36 +0000 | [diff] [blame] | 1211 | $(TCLSH_CMD) $(TOP)\tool\mksqlite3h.tcl $(TOP) > sqlite3.h |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1212 | |
| 1213 | mkkeywordhash.exe: $(TOP)\tool\mkkeywordhash.c |
mistachkin | bd58d5f | 2012-06-30 22:22:34 +0000 | [diff] [blame] | 1214 | $(BCC) -Fe$@ $(OPT_FEATURE_FLAGS) $(OPTS) $(TOP)\tool\mkkeywordhash.c /link $(NLTLIBPATHS) |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1215 | |
| 1216 | keywordhash.h: $(TOP)\tool\mkkeywordhash.c mkkeywordhash.exe |
mistachkin | 5b0b6fd | 2011-06-25 01:14:36 +0000 | [diff] [blame] | 1217 | .\mkkeywordhash.exe > keywordhash.h |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1218 | |
| 1219 | |
| 1220 | |
| 1221 | # Rules to build the extension objects. |
| 1222 | # |
| 1223 | icu.lo: $(TOP)\ext\icu\icu.c $(HDR) $(EXTHDR) |
| 1224 | $(LTCOMPILE) -DSQLITE_CORE -c $(TOP)\ext\icu\icu.c |
| 1225 | |
| 1226 | fts2.lo: $(TOP)\ext\fts2\fts2.c $(HDR) $(EXTHDR) |
| 1227 | $(LTCOMPILE) -DSQLITE_CORE -c $(TOP)\ext\fts2\fts2.c |
| 1228 | |
| 1229 | fts2_hash.lo: $(TOP)\ext\fts2\fts2_hash.c $(HDR) $(EXTHDR) |
| 1230 | $(LTCOMPILE) -DSQLITE_CORE -c $(TOP)\ext\fts2\fts2_hash.c |
| 1231 | |
| 1232 | fts2_icu.lo: $(TOP)\ext\fts2\fts2_icu.c $(HDR) $(EXTHDR) |
| 1233 | $(LTCOMPILE) -DSQLITE_CORE -c $(TOP)\ext\fts2\fts2_icu.c |
| 1234 | |
| 1235 | fts2_porter.lo: $(TOP)\ext\fts2\fts2_porter.c $(HDR) $(EXTHDR) |
| 1236 | $(LTCOMPILE) -DSQLITE_CORE -c $(TOP)\ext\fts2\fts2_porter.c |
| 1237 | |
| 1238 | fts2_tokenizer.lo: $(TOP)\ext\fts2\fts2_tokenizer.c $(HDR) $(EXTHDR) |
| 1239 | $(LTCOMPILE) -DSQLITE_CORE -c $(TOP)\ext\fts2\fts2_tokenizer.c |
| 1240 | |
| 1241 | fts2_tokenizer1.lo: $(TOP)\ext\fts2\fts2_tokenizer1.c $(HDR) $(EXTHDR) |
| 1242 | $(LTCOMPILE) -DSQLITE_CORE -c $(TOP)\ext\fts2\fts2_tokenizer1.c |
| 1243 | |
| 1244 | fts3.lo: $(TOP)\ext\fts3\fts3.c $(HDR) $(EXTHDR) |
| 1245 | $(LTCOMPILE) -DSQLITE_CORE -c $(TOP)\ext\fts3\fts3.c |
| 1246 | |
| 1247 | fts3_aux.lo: $(TOP)\ext\fts3\fts3_aux.c $(HDR) $(EXTHDR) |
| 1248 | $(LTCOMPILE) -DSQLITE_CORE -c $(TOP)\ext\fts3\fts3_aux.c |
| 1249 | |
| 1250 | fts3_expr.lo: $(TOP)\ext\fts3\fts3_expr.c $(HDR) $(EXTHDR) |
| 1251 | $(LTCOMPILE) -DSQLITE_CORE -c $(TOP)\ext\fts3\fts3_expr.c |
| 1252 | |
| 1253 | fts3_hash.lo: $(TOP)\ext\fts3\fts3_hash.c $(HDR) $(EXTHDR) |
| 1254 | $(LTCOMPILE) -DSQLITE_CORE -c $(TOP)\ext\fts3\fts3_hash.c |
| 1255 | |
| 1256 | fts3_icu.lo: $(TOP)\ext\fts3\fts3_icu.c $(HDR) $(EXTHDR) |
| 1257 | $(LTCOMPILE) -DSQLITE_CORE -c $(TOP)\ext\fts3\fts3_icu.c |
| 1258 | |
| 1259 | fts3_snippet.lo: $(TOP)\ext\fts3\fts3_snippet.c $(HDR) $(EXTHDR) |
| 1260 | $(LTCOMPILE) -DSQLITE_CORE -c $(TOP)\ext\fts3\fts3_snippet.c |
| 1261 | |
| 1262 | fts3_porter.lo: $(TOP)\ext\fts3\fts3_porter.c $(HDR) $(EXTHDR) |
| 1263 | $(LTCOMPILE) -DSQLITE_CORE -c $(TOP)\ext\fts3\fts3_porter.c |
| 1264 | |
| 1265 | fts3_tokenizer.lo: $(TOP)\ext\fts3\fts3_tokenizer.c $(HDR) $(EXTHDR) |
| 1266 | $(LTCOMPILE) -DSQLITE_CORE -c $(TOP)\ext\fts3\fts3_tokenizer.c |
| 1267 | |
| 1268 | fts3_tokenizer1.lo: $(TOP)\ext\fts3\fts3_tokenizer1.c $(HDR) $(EXTHDR) |
| 1269 | $(LTCOMPILE) -DSQLITE_CORE -c $(TOP)\ext\fts3\fts3_tokenizer1.c |
| 1270 | |
drh | 4d648c7 | 2013-04-22 17:07:56 +0000 | [diff] [blame] | 1271 | fts3_tokenize_vtab.lo: $(TOP)\ext\fts3\fts3_tokenize_vtab.c $(HDR) $(EXTHDR) |
| 1272 | $(LTCOMPILE) -DSQLITE_CORE -c $(TOP)\ext\fts3\fts3_tokenize_vtab.c |
| 1273 | |
drh | 391d4ba | 2012-05-28 20:22:16 +0000 | [diff] [blame] | 1274 | fts3_unicode.lo: $(TOP)\ext\fts3\fts3_unicode.c $(HDR) $(EXTHDR) |
| 1275 | $(LTCOMPILE) -DSQLITE_CORE -c $(TOP)\ext\fts3\fts3_unicode.c |
| 1276 | |
| 1277 | fts3_unicode2.lo: $(TOP)\ext\fts3\fts3_unicode2.c $(HDR) $(EXTHDR) |
| 1278 | $(LTCOMPILE) -DSQLITE_CORE -c $(TOP)\ext\fts3\fts3_unicode2.c |
| 1279 | |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1280 | fts3_write.lo: $(TOP)\ext\fts3\fts3_write.c $(HDR) $(EXTHDR) |
| 1281 | $(LTCOMPILE) -DSQLITE_CORE -c $(TOP)\ext\fts3\fts3_write.c |
| 1282 | |
| 1283 | rtree.lo: $(TOP)\ext\rtree\rtree.c $(HDR) $(EXTHDR) |
| 1284 | $(LTCOMPILE) -DSQLITE_CORE -c $(TOP)\ext\rtree\rtree.c |
| 1285 | |
| 1286 | |
| 1287 | # Rules to build the 'testfixture' application. |
| 1288 | # |
| 1289 | # If using the amalgamation, use sqlite3.c directly to build the test |
| 1290 | # fixture. Otherwise link against libsqlite3.lib. (This distinction is |
| 1291 | # necessary because the test fixture requires non-API symbols which are |
| 1292 | # hidden when the library is built via the amalgamation). |
| 1293 | # |
| 1294 | TESTFIXTURE_FLAGS = -DTCLSH=1 -DSQLITE_TEST=1 -DSQLITE_CRASH_TEST=1 |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 1295 | TESTFIXTURE_FLAGS = $(TESTFIXTURE_FLAGS) -DSQLITE_SERVER=1 -DSQLITE_PRIVATE="" -DSQLITE_CORE |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1296 | |
drh | 1fb64af | 2013-04-25 14:36:28 +0000 | [diff] [blame] | 1297 | TESTFIXTURE_SRC0 = $(TESTEXT) $(TESTSRC2) libsqlite3.lib |
mistachkin | 7651091 | 2013-10-11 23:01:18 +0000 | [diff] [blame] | 1298 | TESTFIXTURE_SRC1 = $(TESTEXT) $(SQLITE3C) |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1299 | !IF $(USE_AMALGAMATION)==0 |
| 1300 | TESTFIXTURE_SRC = $(TESTSRC) $(TOP)\src\tclsqlite.c $(TESTFIXTURE_SRC0) |
| 1301 | !ELSE |
| 1302 | TESTFIXTURE_SRC = $(TESTSRC) $(TOP)\src\tclsqlite.c $(TESTFIXTURE_SRC1) |
| 1303 | !ENDIF |
| 1304 | |
mistachkin | 08c1c31 | 2012-10-06 03:48:25 +0000 | [diff] [blame] | 1305 | testfixture.exe: $(TESTFIXTURE_SRC) $(LIBRESOBJS) $(HDR) |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 1306 | $(LTLINK) -DSQLITE_NO_SYNC=1 $(TESTFIXTURE_FLAGS) \ |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1307 | -DBUILD_sqlite -I$(TCLINCDIR) \ |
shaneh | 2a0b9ef | 2011-06-20 20:52:32 +0000 | [diff] [blame] | 1308 | $(TESTFIXTURE_SRC) \ |
mistachkin | 08c1c31 | 2012-10-06 03:48:25 +0000 | [diff] [blame] | 1309 | /link $(LTLINKOPTS) $(LTLIBPATHS) $(LIBRESOBJS) $(LTLIBS) $(TLIBS) |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1310 | |
| 1311 | fulltest: testfixture.exe sqlite3.exe |
| 1312 | .\testfixture.exe $(TOP)\test\all.test |
| 1313 | |
| 1314 | soaktest: testfixture.exe sqlite3.exe |
| 1315 | .\testfixture.exe $(TOP)\test\all.test -soak=1 |
| 1316 | |
mistachkin | c60941f | 2012-09-13 01:51:02 +0000 | [diff] [blame] | 1317 | fulltestonly: testfixture.exe sqlite3.exe |
| 1318 | .\testfixture.exe $(TOP)\test\full.test |
| 1319 | |
mistachkin | 036acf3 | 2013-07-20 00:34:31 +0000 | [diff] [blame] | 1320 | queryplantest: testfixture.exe sqlite3.exe |
| 1321 | .\testfixture.exe $(TOP)\test\permutations.test queryplanner |
| 1322 | |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1323 | test: testfixture.exe sqlite3.exe |
| 1324 | .\testfixture.exe $(TOP)\test\veryquick.test |
| 1325 | |
mistachkin | 7651091 | 2013-10-11 23:01:18 +0000 | [diff] [blame] | 1326 | sqlite3_analyzer.c: $(SQLITE3C) $(TOP)\src\test_stat.c $(TOP)\src\tclsqlite.c $(TOP)\tool\spaceanal.tcl |
| 1327 | copy $(SQLITE3C) + $(TOP)\src\test_stat.c + $(TOP)\src\tclsqlite.c $@ |
mistachkin | 9a55e31 | 2011-09-22 00:06:44 +0000 | [diff] [blame] | 1328 | echo static const char *tclsh_main_loop(void){ >> $@ |
| 1329 | echo static const char *zMainloop = >> $@ |
| 1330 | $(NAWK) -f $(TOP)\tool\tostr.awk $(TOP)\tool\spaceanal.tcl >> $@ |
| 1331 | echo ; return zMainloop; } >> $@ |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1332 | |
mistachkin | 08c1c31 | 2012-10-06 03:48:25 +0000 | [diff] [blame] | 1333 | sqlite3_analyzer.exe: sqlite3_analyzer.c $(LIBRESOBJS) |
mistachkin | 9a55e31 | 2011-09-22 00:06:44 +0000 | [diff] [blame] | 1334 | $(LTLINK) -DBUILD_sqlite -DTCLSH=2 -I$(TCLINCDIR) sqlite3_analyzer.c \ |
mistachkin | 08c1c31 | 2012-10-06 03:48:25 +0000 | [diff] [blame] | 1335 | /link $(LTLINKOPTS) $(LTLIBPATHS) $(LIBRESOBJS) $(LTLIBS) $(TLIBS) |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1336 | |
mistachkin | 1617577 | 2013-11-23 04:22:19 +0000 | [diff] [blame] | 1337 | showdb.exe: $(TOP)\tool\showdb.c sqlite3.c |
drh | 9ac3c1e | 2013-11-07 18:37:31 +0000 | [diff] [blame] | 1338 | $(LTLINK) -DSQLITE_THREADSAFE=0 -DSQLITE_OMIT_LOAD_EXTENSION -o $@ \ |
mistachkin | 1617577 | 2013-11-23 04:22:19 +0000 | [diff] [blame] | 1339 | $(TOP)\tool\showdb.c sqlite3.c |
drh | 9ac3c1e | 2013-11-07 18:37:31 +0000 | [diff] [blame] | 1340 | |
mistachkin | 1617577 | 2013-11-23 04:22:19 +0000 | [diff] [blame] | 1341 | wordcount.exe: $(TOP)\test\wordcount.c sqlite3.c |
drh | 9ac3c1e | 2013-11-07 18:37:31 +0000 | [diff] [blame] | 1342 | $(LTLINK) -DSQLITE_THREADSAFE=0 -DSQLITE_OMIT_LOAD_EXTENSION -o $@ \ |
mistachkin | 1617577 | 2013-11-23 04:22:19 +0000 | [diff] [blame] | 1343 | $(TOP)\test\wordcount.c sqlite3.c |
drh | 9ac3c1e | 2013-11-07 18:37:31 +0000 | [diff] [blame] | 1344 | |
mistachkin | 1617577 | 2013-11-23 04:22:19 +0000 | [diff] [blame] | 1345 | speedtest1.exe: $(TOP)\test\speedtest1.c sqlite3.c |
drh | ad1ca9a | 2013-11-23 04:16:58 +0000 | [diff] [blame] | 1346 | $(LTLINK) -DSQLITE_OMIT_LOAD_EXTENSION -o $@ \ |
mistachkin | 1617577 | 2013-11-23 04:22:19 +0000 | [diff] [blame] | 1347 | $(TOP)\test\speedtest1.c sqlite3.c |
drh | ad1ca9a | 2013-11-23 04:16:58 +0000 | [diff] [blame] | 1348 | |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 1349 | clean: |
mistachkin | 649591a | 2011-09-11 10:14:37 +0000 | [diff] [blame] | 1350 | del /Q *.lo *.ilk *.lib *.obj *.pdb sqlite3.exe libsqlite3.lib |
mistachkin | 0157e01 | 2013-09-06 21:41:11 +0000 | [diff] [blame] | 1351 | del /Q *.cod *.da *.bb *.bbg gmon.out |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1352 | del /Q sqlite3.h opcodes.c opcodes.h |
| 1353 | del /Q lemon.exe lempar.c parse.* |
| 1354 | del /Q mkkeywordhash.exe keywordhash.h |
mistachkin | b482a44 | 2012-02-11 22:19:26 +0000 | [diff] [blame] | 1355 | -rmdir /Q/S .deps |
| 1356 | -rmdir /Q/S .libs |
mistachkin | f8a7846 | 2012-03-08 20:00:36 +0000 | [diff] [blame] | 1357 | -rmdir /Q/S quota2a |
| 1358 | -rmdir /Q/S quota2b |
| 1359 | -rmdir /Q/S quota2c |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1360 | -rmdir /Q/S tsrc |
| 1361 | del /Q .target_source |
mistachkin | 0f104d5 | 2012-09-03 11:01:21 +0000 | [diff] [blame] | 1362 | del /Q tclsqlite3.exe tclsqlite3.exp |
shaneh | 603e426 | 2011-06-17 18:52:07 +0000 | [diff] [blame] | 1363 | del /Q testfixture.exe testfixture.exp test.db |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 1364 | del /Q sqlite3.dll sqlite3.lib sqlite3.exp sqlite3.def |
mistachkin | 7651091 | 2013-10-11 23:01:18 +0000 | [diff] [blame] | 1365 | del /Q sqlite3.c sqlite3-*.c |
mistachkin | 4d9d1f4 | 2012-09-03 10:32:32 +0000 | [diff] [blame] | 1366 | del /Q sqlite3rc.h |
mistachkin | fde3b1c7 | 2013-03-29 19:52:04 +0000 | [diff] [blame] | 1367 | del /Q shell.c sqlite3ext.h |
mistachkin | 9a55e31 | 2011-09-22 00:06:44 +0000 | [diff] [blame] | 1368 | del /Q sqlite3_analyzer.exe sqlite3_analyzer.exp sqlite3_analyzer.c |
mistachkin | 29b75bd | 2012-10-20 09:35:57 +0000 | [diff] [blame] | 1369 | del /Q sqlite-*-output.vsix |
drh | bc94dbb | 2013-04-08 14:28:33 +0000 | [diff] [blame] | 1370 | del /Q mptester.exe |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1371 | |
mistachkin | 4d9d1f4 | 2012-09-03 10:32:32 +0000 | [diff] [blame] | 1372 | # Dynamic link library section. |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1373 | # |
| 1374 | dll: sqlite3.dll |
| 1375 | |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 1376 | sqlite3.def: libsqlite3.lib |
mistachkin | 5b0b6fd | 2011-06-25 01:14:36 +0000 | [diff] [blame] | 1377 | echo EXPORTS > sqlite3.def |
shaneh | 6e7850c | 2011-06-17 15:57:07 +0000 | [diff] [blame] | 1378 | dumpbin /all libsqlite3.lib \ |
mistachkin | 6a3eb4a | 2011-08-17 07:46:48 +0000 | [diff] [blame] | 1379 | | $(NAWK) "/ 1 _?sqlite3_/ { sub(/^.* _?/,\"\");print }" \ |
mistachkin | 5b0b6fd | 2011-06-25 01:14:36 +0000 | [diff] [blame] | 1380 | | sort >> sqlite3.def |
shaneh | b2f20bf | 2011-06-17 07:07:24 +0000 | [diff] [blame] | 1381 | |
mistachkin | 08c1c31 | 2012-10-06 03:48:25 +0000 | [diff] [blame] | 1382 | sqlite3.dll: $(LIBOBJ) $(LIBRESOBJS) sqlite3.def |
| 1383 | $(LD) $(LDFLAGS) $(LTLINKOPTS) $(LTLIBPATHS) /DLL /DEF:sqlite3.def /OUT:$@ $(LIBOBJ) $(LIBRESOBJS) $(LTLIBS) $(TLIBS) |