From eb288d95f12940b3b74d741310fa49afde789484 Mon Sep 17 00:00:00 2001 From: Brad Fitzpatrick Date: Sun, 17 Jul 2011 14:44:33 -0700 Subject: [PATCH] fix sqlite linking Change-Id: I540d45d787df0e18091c26a6961b2ac97e1fac4d --- misc/sqlite/sqlite.go | 1 + misc/sqlite/sqlite3.h | 2 ++ 2 files changed, 3 insertions(+) diff --git a/misc/sqlite/sqlite.go b/misc/sqlite/sqlite.go index e986353df..4ff5d5ec4 100644 --- a/misc/sqlite/sqlite.go +++ b/misc/sqlite/sqlite.go @@ -5,6 +5,7 @@ package sqlite #cgo LDFLAGS: -ldl -lpthread #include +#define SKIP_SQLITE_VERSION 1 #include "sqlite3.h" static int my_bind_text(sqlite3_stmt *stmt, int n, char *p, int np) { diff --git a/misc/sqlite/sqlite3.h b/misc/sqlite/sqlite3.h index a93473b9b..6d5e430e3 100644 --- a/misc/sqlite/sqlite3.h +++ b/misc/sqlite/sqlite3.h @@ -142,7 +142,9 @@ extern "C" { ** ** See also: [sqlite_version()] and [sqlite_source_id()]. */ +#ifndef SKIP_SQLITE_VERSION SQLITE_API const char sqlite3_version[] = SQLITE_VERSION; +#endif SQLITE_API const char *sqlite3_libversion(void); SQLITE_API const char *sqlite3_sourceid(void); SQLITE_API int sqlite3_libversion_number(void);