mirror of
https://github.com/sqlite/sqlite.git
synced 2025-10-24 09:53:10 +03:00
Fix the amalgamation so that it works with -DSQLITE_ENABLE_REDEF_IO. Change
tclsqlite.c so that it can be appended to the amalgamation. Create a new amalgamation of header files for use by projects that want to redefine their own I/O interface using -DSQLITE_ENABLE_REDEF_IO. (CVS 3817) FossilOrigin-Name: f2caff870c81c08ec85aae72986c231ee986b251
This commit is contained in:
1
src/os.c
1
src/os.c
@@ -16,6 +16,7 @@
|
||||
#define _SQLITE_OS_C_ 1
|
||||
#include "sqliteInt.h"
|
||||
#include "os.h"
|
||||
#undef _SQLITE_OS_C_
|
||||
|
||||
/*
|
||||
** The following routines are convenience wrappers around methods
|
||||
|
||||
5
src/os.h
5
src/os.h
@@ -447,9 +447,12 @@ struct sqlite3OsVtbl {
|
||||
#endif
|
||||
|
||||
|
||||
#ifdef _SQLITE_OS_C_
|
||||
#if defined(_SQLITE_OS_C_) || defined(SQLITE_AMALGAMATION)
|
||||
/*
|
||||
** The os.c file implements the global virtual function table.
|
||||
** We have to put this file here because the initializers
|
||||
** (ex: sqlite3OsRandomSeed) are macros that are about to be
|
||||
** redefined.
|
||||
*/
|
||||
struct sqlite3OsVtbl sqlite3Os = {
|
||||
IF_DISKIO( sqlite3OsOpenReadWrite ),
|
||||
|
||||
@@ -9,19 +9,25 @@
|
||||
** May you share freely, never taking more than you give.
|
||||
**
|
||||
*************************************************************************
|
||||
** A TCL Interface to SQLite
|
||||
** A TCL Interface to SQLite. Append this file to sqlite3.c and
|
||||
** compile the whole thing to build a TCL-enabled version of SQLite.
|
||||
**
|
||||
** $Id: tclsqlite.c,v 1.177 2007/03/29 12:19:12 danielk1977 Exp $
|
||||
** $Id: tclsqlite.c,v 1.178 2007/04/05 21:58:33 drh Exp $
|
||||
*/
|
||||
#ifndef NO_TCL /* Omit this whole file if TCL is unavailable */
|
||||
|
||||
#include "sqliteInt.h"
|
||||
#include "hash.h"
|
||||
#include "tcl.h"
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
#include <assert.h>
|
||||
#include <ctype.h>
|
||||
|
||||
/*
|
||||
** Some additional include files are needed if this file is not
|
||||
** appended to the amalgamation.
|
||||
*/
|
||||
#ifndef SQLITE_AMALGAMATION
|
||||
# include "sqliteInt.h"
|
||||
# include "hash.h"
|
||||
# include <stdlib.h>
|
||||
# include <string.h>
|
||||
# include <assert.h>
|
||||
# include <ctype.h>
|
||||
#endif
|
||||
|
||||
/*
|
||||
* Windows needs to know which symbols to export. Unix does not.
|
||||
@@ -2256,5 +2262,3 @@ int TCLSH_MAIN(int argc, char **argv){
|
||||
return 0;
|
||||
}
|
||||
#endif /* TCLSH */
|
||||
|
||||
#endif /* !defined(NO_TCL) */
|
||||
|
||||
Reference in New Issue
Block a user