aboutsummaryrefslogtreecommitdiff
path: root/src/os_common.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/os_common.h')
-rw-r--r--src/os_common.h13
1 files changed, 8 insertions, 5 deletions
diff --git a/src/os_common.h b/src/os_common.h
index f6c3e7ff8..837f94714 100644
--- a/src/os_common.h
+++ b/src/os_common.h
@@ -29,13 +29,16 @@
# error "The MEMORY_DEBUG macro is obsolete. Use SQLITE_DEBUG instead."
#endif
-#if defined(SQLITE_TEST) && defined(SQLITE_DEBUG)
-# ifndef SQLITE_DEBUG_OS_TRACE
-# define SQLITE_DEBUG_OS_TRACE 0
-# endif
- int sqlite3OSTrace = SQLITE_DEBUG_OS_TRACE;
+/*
+** Declarations used for tracing the operating system interfaces.
+*/
+#if (defined(SQLITE_DEBUG) && SQLITE_OS_WIN) || \
+ defined(SQLITE_TEST) || defined(SQLITE_FORCE_OS_TRACE)
+ extern int sqlite3OSTrace;
# define OSTRACE(X) if( sqlite3OSTrace ) sqlite3DebugPrintf X
+# define SQLITE_HAVE_OS_TRACE
#else
+# undef SQLITE_HAVE_OS_TRACE
# define OSTRACE(X)
#endif