Get SQLite to build

* changed headers
* removed redundant declarations
* ran clang-format
* added sqlite3.mk
This commit is contained in:
ahgamut 2021-05-04 20:09:59 +05:30 committed by Justine Tunney
parent 644f290035
commit 919b6fec10
156 changed files with 2847 additions and 6772 deletions

View file

@ -12,18 +12,19 @@
**
** This file contains code that is specific to Windows.
*/
#include "sqliteInt.h"
#if SQLITE_OS_WIN /* This file is used for Windows only */
#include "third_party/sqlite3/sqliteInt.h"
#if SQLITE_OS_WIN /* This file is used for Windows only */
/* clang-format off */
/*
** Include code that is common to all os_*.c files
*/
#include "os_common.h"
#include "third_party/sqlite3/os_common.h"
/*
** Include the header file for the Windows VFS.
*/
#include "os_win.h"
#include "third_party/sqlite3/os_win.h"
/*
** Compiling and using WAL mode requires several APIs that are only
@ -2193,9 +2194,8 @@ static void winLogIoerr(int nRetry, int lineno){
** The MSVC CRT on Windows CE may not have a localtime() function.
** So define a substitute.
*/
# include <time.h>
struct tm *__cdecl localtime(const time_t *t)
{
#include "libc/time/time.h"
struct tm *__cdecl localtime(const time_t *t) {
static struct tm y;
FILETIME uTm, lTm;
SYSTEMTIME pTm;