Browse Source

Moved the configuration options to the SRC directory

geniusgogo 11 years ago
parent
commit
26e0137f15

+ 6 - 4
components/external/SQLite-3.8.1/SQLiteLib/README

@@ -10,6 +10,8 @@
     * SQLite compile macro
     */
     #define RT_USING_SQLITE
+2.
+    关注SQLite目录下的src/sqlite_config_rtthread.h
     #define SQLITE_MINIMUM_FILE_DESCRIPTOR  0
     #define SQLITE_OMIT_LOAD_EXTENSION 1 
     #define SQLITE_OMIT_WAL 
@@ -20,11 +22,11 @@
     #define SQLITE_THREADSAFE 1
     #define HAVE_READLINE 0 
     #define NDEBUG
-    #define _HAVE_SQLITE_CONFIG_H 
+    #define _HAVE_SQLITE_CONFIG_H
     #define BUILD_sqlite
-    #define SQLITE_OS_OTHER 1 
-    #define SQLITE_OS_RTT 1
-2.
+    #define SQLITE_OS_OTHER 1
+    #define SQLITE_OS_RTTHREAD 1
+3.
     用test目录下的test10.c来进行测试.
     推荐用mini2440bsp,因为板子的ram较大。
 

+ 2 - 0
components/external/SQLite-3.8.1/make/Makefile

@@ -346,6 +346,8 @@ SRC += \
   parse.h \
   config.h \
   sqlite3.h
+  
+SRC += $(TOP)/src/sqlite_config_rtthread.h
 
 # Source code to the test files.
 #

+ 62 - 0
components/external/SQLite-3.8.1/src/sqlite_config_rtthread.h

@@ -0,0 +1,62 @@
+#ifndef _SQLITE_CONFIG_RTTHREAD_H_
+#define _SQLITE_CONFIG_RTTHREAD_H_
+/*
+* SQLite compile macro
+*/
+#ifndef SQLITE_MINIMUM_FILE_DESCRIPTOR
+#define SQLITE_MINIMUM_FILE_DESCRIPTOR  0
+#endif
+
+#ifndef SQLITE_OMIT_LOAD_EXTENSION
+#define SQLITE_OMIT_LOAD_EXTENSION 1
+#endif
+
+//#ifndef #define SQLITE_OMIT_WAL
+#define SQLITE_OMIT_WAL
+//#endif
+
+#ifndef SQLITE_RTTHREAD_NO_WIDE
+#define SQLITE_RTTHREAD_NO_WIDE 1
+#endif
+
+#ifndef SQLITE_ENABLE_LOCKING_STYLE
+#define SQLITE_ENABLE_LOCKING_STYLE 0
+#endif
+
+#ifndef SQLITE_DISABLE_LOCKING_STYLE
+#define SQLITE_DISABLE_LOCKING_STYLE 1
+#endif
+
+#ifndef SQLITE_TEMP_STORE
+#define SQLITE_TEMP_STORE 1
+#endif
+
+#ifndef SQLITE_THREADSAFE
+#define SQLITE_THREADSAFE 1
+#endif
+
+#ifndef HAVE_READLINE
+#define HAVE_READLINE 0
+#endif
+
+#ifndef NDEBUG
+#define NDEBUG
+#endif
+
+#ifndef _HAVE_SQLITE_CONFIG_H
+#define _HAVE_SQLITE_CONFIG_H
+#endif
+
+#ifndef BUILD_sqlite
+#define BUILD_sqlite
+#endif
+
+#ifndef SQLITE_OS_OTHER
+#define SQLITE_OS_OTHER 1
+#endif
+
+#ifndef SQLITE_OS_RTTHREAD
+#define SQLITE_OS_RTTHREAD 1
+#endif
+
+#endif

+ 1 - 0
components/external/SQLite-3.8.1/tool/mksqlite3c.tcl

@@ -228,6 +228,7 @@ proc copy_file {filename} {
 # inlining opportunities.
 #
 foreach file {
+   sqlite_config_rtthread.h 
    sqlite3.h
    sqliteInt.h