Index: src/test4.c ================================================================== --- src/test4.c +++ src/test4.c @@ -11,11 +11,11 @@ ************************************************************************* ** Code for testing the the SQLite library in a multithreaded environment. */ #include "sqliteInt.h" #include "tcl.h" -#if defined(SQLITE_OS_UNIX) && OS_UNIX==1 && SQLITE_THREADSAFE +#if SQLITE_OS_UNIX && SQLITE_THREADSAFE #include #include #include #include #include Index: src/test7.c ================================================================== --- src/test7.c +++ src/test7.c @@ -18,11 +18,11 @@ /* ** This test only works on UNIX with a SQLITE_THREADSAFE build that includes ** the SQLITE_SERVER option. */ #if defined(SQLITE_SERVER) && !defined(SQLITE_OMIT_SHARED_CACHE) && \ - defined(SQLITE_OS_UNIX) && OS_UNIX && SQLITE_THREADSAFE + SQLITE_OS_UNIX && SQLITE_THREADSAFE #include #include #include #include Index: src/test_demovfs.c ================================================================== --- src/test_demovfs.c +++ src/test_demovfs.c @@ -113,11 +113,11 @@ ** ** Much more efficient if the underlying OS is not caching write ** operations. */ -#if !defined(SQLITE_TEST) || defined(SQLITE_OS_UNIX) +#if !defined(SQLITE_TEST) || SQLITE_OS_UNIX #include #include #include @@ -635,18 +635,18 @@ demoCurrentTime, /* xCurrentTime */ }; return &demovfs; } -#endif /* !defined(SQLITE_TEST) || defined(SQLITE_OS_UNIX) */ +#endif /* !defined(SQLITE_TEST) || SQLITE_OS_UNIX */ #ifdef SQLITE_TEST #include -#ifdef SQLITE_OS_UNIX +#if SQLITE_OS_UNIX static int register_demovfs( ClientData clientData, /* Pointer to sqlite3_enable_XXX function */ Tcl_Interp *interp, /* The TCL interpreter that invoked this command */ int objc, /* Number of arguments */ Tcl_Obj *CONST objv[] /* Command arguments */ Index: src/test_osinst.c ================================================================== --- src/test_osinst.c +++ src/test_osinst.c @@ -211,18 +211,18 @@ vfslogShmLock, /* xShmLock */ vfslogShmBarrier, /* xShmBarrier */ vfslogShmUnmap /* xShmUnmap */ }; -#if defined(SQLITE_OS_UNIX) && !defined(NO_GETTOD) +#if SQLITE_OS_UNIX && !defined(NO_GETTOD) #include static sqlite3_uint64 vfslog_time(){ struct timeval sTime; gettimeofday(&sTime, 0); return sTime.tv_usec + (sqlite3_uint64)sTime.tv_sec * 1000000; } -#elif defined(SQLITE_OS_WIN) +#elif SQLITE_OS_WIN #include #include static sqlite3_uint64 vfslog_time(){ FILETIME ft; sqlite3_uint64 u64time = 0; Index: src/test_server.c ================================================================== --- src/test_server.c +++ src/test_server.c @@ -204,11 +204,11 @@ /* ** Only compile the code in this file on UNIX with a SQLITE_THREADSAFE build ** and only if the SQLITE_SERVER macro is defined. */ #if defined(SQLITE_SERVER) && !defined(SQLITE_OMIT_SHARED_CACHE) -#if defined(SQLITE_OS_UNIX) && OS_UNIX && SQLITE_THREADSAFE +#if SQLITE_OS_UNIX && SQLITE_THREADSAFE /* ** We require only pthreads and the public interface of SQLite. */ #include @@ -485,7 +485,7 @@ pthread_cond_broadcast(&g.serverWakeup); pthread_mutex_lock(&g.serverMutex); pthread_mutex_unlock(&g.serverMutex); } -#endif /* defined(SQLITE_OS_UNIX) && OS_UNIX && SQLITE_THREADSAFE */ +#endif /* SQLITE_OS_UNIX && SQLITE_THREADSAFE */ #endif /* defined(SQLITE_SERVER) */ Index: src/test_syscall.c ================================================================== --- src/test_syscall.c +++ src/test_syscall.c @@ -74,11 +74,11 @@ #include #include #include #include "sqliteInt.h" -#ifdef SQLITE_OS_UNIX +#if SQLITE_OS_UNIX /* From test1.c */ extern const char *sqlite3TestErrorName(int); #include Index: src/test_thread.c ================================================================== --- src/test_thread.c +++ src/test_thread.c @@ -51,11 +51,11 @@ Tcl_Interp *interp; /* The interpreter to execute it in. */ }; static Tcl_ObjCmdProc sqlthread_proc; static Tcl_ObjCmdProc clock_seconds_proc; -#if defined(SQLITE_OS_UNIX) && defined(SQLITE_ENABLE_UNLOCK_NOTIFY) +#if SQLITE_OS_UNIX && defined(SQLITE_ENABLE_UNLOCK_NOTIFY) static Tcl_ObjCmdProc blocking_step_proc; static Tcl_ObjCmdProc blocking_prepare_v2_proc; #endif int Sqlitetest1_Init(Tcl_Interp *); int Sqlite3_Init(Tcl_Interp *); @@ -114,11 +114,11 @@ extern int Sqlitetest_mutex_Init(Tcl_Interp*); interp = Tcl_CreateInterp(); Tcl_CreateObjCommand(interp, "clock_seconds", clock_seconds_proc, 0, 0); Tcl_CreateObjCommand(interp, "sqlthread", sqlthread_proc, pSqlThread, 0); -#if defined(SQLITE_OS_UNIX) && defined(SQLITE_ENABLE_UNLOCK_NOTIFY) +#if SQLITE_OS_UNIX && defined(SQLITE_ENABLE_UNLOCK_NOTIFY) Tcl_CreateObjCommand(interp, "sqlite3_blocking_step", blocking_step_proc,0,0); Tcl_CreateObjCommand(interp, "sqlite3_blocking_prepare_v2", blocking_prepare_v2_proc, (void *)1, 0); Tcl_CreateObjCommand(interp, "sqlite3_nonblocking_prepare_v2", blocking_prepare_v2_proc, 0, 0); @@ -390,11 +390,11 @@ ** automatically extracted from this file and used as part of the ** documentation for the sqlite3_unlock_notify() API function. This ** should be considered if these functions are to be extended (i.e. to ** support windows) in the future. */ -#if defined(SQLITE_OS_UNIX) && defined(SQLITE_ENABLE_UNLOCK_NOTIFY) +#if SQLITE_OS_UNIX && defined(SQLITE_ENABLE_UNLOCK_NOTIFY) /* BEGIN_SQLITE_BLOCKING_STEP */ /* This example uses the pthreads API */ #include @@ -612,11 +612,11 @@ ** Register commands with the TCL interpreter. */ int SqlitetestThread_Init(Tcl_Interp *interp){ Tcl_CreateObjCommand(interp, "sqlthread", sqlthread_proc, 0, 0); Tcl_CreateObjCommand(interp, "clock_seconds", clock_seconds_proc, 0, 0); -#if defined(SQLITE_OS_UNIX) && defined(SQLITE_ENABLE_UNLOCK_NOTIFY) +#if SQLITE_OS_UNIX && defined(SQLITE_ENABLE_UNLOCK_NOTIFY) Tcl_CreateObjCommand(interp, "sqlite3_blocking_step", blocking_step_proc,0,0); Tcl_CreateObjCommand(interp, "sqlite3_blocking_prepare_v2", blocking_prepare_v2_proc, (void *)1, 0); Tcl_CreateObjCommand(interp, "sqlite3_nonblocking_prepare_v2", blocking_prepare_v2_proc, 0, 0); Index: test/releasetest.tcl ================================================================== --- test/releasetest.tcl +++ test/releasetest.tcl @@ -62,11 +62,10 @@ } "Unlock-Notify" { -O2 -DSQLITE_ENABLE_UNLOCK_NOTIFY -DSQLITE_THREADSAFE - -DOS_UNIX -DSQLITE_TCL_DEFAULT_FULLMUTEX=1 } "Secure-Delete" { -O2 -DSQLITE_SECURE_DELETE=1