Package: libsqlite3-dev
Version: 3.6.23.1-2
Severity: minor

Hi, the type sqlite3_int64 is defined as long long int. Other int64
types (such as int64_t in stdlib.h or gint64 in glib) are defined as
"long int" on AMD64.

It would be great if sqlite3 could also use "long int" if it already
is 64-bit, as I currently get warnings from gcc when passing an
sqlite3_int64 to a function expecting gint64 or int64_t. It could
also use int64_t for sqlite3_int64 if available.

The same applies to sqlite3_uint64 as well.

The following hack might work, though I think there should be a
better way to do this; for example, in the configure script
(glib2.0 does this).

--- sqlite3-3.6.23.1.orig/src/sqlite.h.in
+++ sqlite3-3.6.23.1/src/sqlite.h.in
@@ -240,6 +240,10 @@ typedef struct sqlite3 sqlite3;
 #ifdef SQLITE_INT64_TYPE
   typedef SQLITE_INT64_TYPE sqlite_int64;
   typedef unsigned SQLITE_INT64_TYPE sqlite_uint64;
+#elif defined(__GLIBC__)
+  #include <stdint.h>
+  typedef int64_t sqlite_int64;
+  typedef uint64_t sqlite_uint64;
 #elif defined(_MSC_VER) || defined(__BORLANDC__)
   typedef __int64 sqlite_int64;
   typedef unsigned __int64 sqlite_uint64;


-- System Information:
Debian Release: lenny/sid
  APT prefers unstable
  APT policy: (990, 'unstable'), (350, 'experimental')
Architecture: amd64 (x86_64)

Kernel: Linux 2.6.32-5-amd64 (SMP w/2 CPU cores)
Locale: LANG=de_DE.UTF-8, LC_CTYPE=de_DE.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash

Versions of packages libsqlite3-dev depends on:
ii  libc6-dev                     2.11-0exp7 Embedded GNU C Library: Developmen
ii  libsqlite3-0                  3.6.23.1-2 SQLite 3 shared library

libsqlite3-dev recommends no packages.

Versions of packages libsqlite3-dev suggests:
pn  sqlite3-doc                   <none>     (no description available)

-- no debconf information

-- 
Julian Andres Klode  - Debian Developer, Ubuntu Member

See http://wiki.debian.org/JulianAndresKlode and http://jak-linux.org/.

Attachment: pgpOjFwhrrLAL.pgp
Description: PGP signature

Reply via email to