Compare commits

..

No commits in common. "4e7d73dd4e1584e9ad6046c86820feb1a8283123" and "e5c1ddcfc33d194fdba4ea96549eae24c377cf43" have entirely different histories.

6 changed files with 2792 additions and 5553 deletions

View File

@ -2,19 +2,17 @@ package sqlite
when ODIN_OS == .Windows { when ODIN_OS == .Windows {
foreign import sqlite "lib/sqlite3.lib" foreign import sqlite "lib/sqlite3.lib"
} else when ODIN_OS == .Darwin { } else when ODIN_OS == .Darwin && ODIN_ARCH == .arm64 {
when ODIN_ARCH == .arm64 { foreign import sqlite "lib/libsqlite3_arm64.a"
foreign import sqlite "lib/libsqlite3_arm64.a" // } else when ODIN_OS == .Darwin && ODIN_ARCH == .amd64 {
} else when ODIN_ARCH == .amd64 { // foreign import sqlite "lib/libsqlite3_x64.a"
foreign import sqlite "lib/libsqlite3_x64.a"
}
} else { } else {
foreign import sqlite "system:sqlite3" foreign import sqlite "system:sqlite3"
} }
VERSION :: "3.47.0" VERSION :: "3.46.1"
VERSION_NUMBER :: 3047000 VERSION_NUMBER :: 3046001
SOURCE_ID :: "2024-10-21 16:30:22 03a9703e27c44437c39363d0baf82db4ebc94538a0f28411c85dda156f82636e" SOURCE_ID :: "2024-08-13 09:16:08 c9c2ab54ba1f5f46360f1b4f35d849cd3f080e6fc2b6c60e91b16c63f69a1e33"
@(default_calling_convention = "cdecl", link_prefix = "sqlite3_") @(default_calling_convention = "cdecl", link_prefix = "sqlite3_")
@ -63,7 +61,7 @@ foreign sqlite {
complete :: proc(sql: cstring) -> (success: b32) --- complete :: proc(sql: cstring) -> (success: b32) ---
// omit complete16 :: proc(rawptr sql) --- // omit complete16 :: proc(rawptr sql) ---
busy_handler :: proc(db: ^sqlite3, busy: proc(arg: rawptr, proc_event_call_count: i32) -> i32, arg: rawptr) -> Result --- busy_handler :: proc(db: ^sqlite3, busy: proc(arg: rawptr, proc_event_call_count: i32) -> i32,arg: rawptr) -> Result ---
busy_timeout :: proc(db: ^sqlite3, ms: i32) -> Result --- busy_timeout :: proc(db: ^sqlite3, ms: i32) -> Result ---
@(deprecated = "This is a legacy interface that is preserved for backwards compatibility. Use of this interface is not recommended.") @(deprecated = "This is a legacy interface that is preserved for backwards compatibility. Use of this interface is not recommended.")
@ -772,7 +770,6 @@ Function_Flag :: enum i32 {
SUBTYPE = 0x000100000, SUBTYPE = 0x000100000,
INNOCUOUS = 0x000200000, INNOCUOUS = 0x000200000,
RESULT_SUBTYPE = 0x001000000, RESULT_SUBTYPE = 0x001000000,
SELFORDER1 = 0x002000000,
} }
Txn_State :: enum i32 { Txn_State :: enum i32 {
@ -1001,7 +998,7 @@ mutex :: struct {}
backup :: struct {} backup :: struct {}
index_info :: struct {} index_info :: struct {}
callback :: proc "c" (db: rawptr, col: i32, vals: [^]cstring, cols: [^]cstring) -> Result callback :: proc(db: rawptr, col: i32, vals: [^]cstring, cols: [^]cstring) -> Result
value :: struct { value :: struct {
u: struct #raw_union {}, // MemValue u: struct #raw_union {}, // MemValue

Binary file not shown.

Binary file not shown.

Binary file not shown.

View File

@ -1,11 +1,11 @@
#!/usr/bin/env bash #!/usr/bin/env bash
set -eu set -eu
OS="$(uname -o)"
LIB_A="libsqlite3"
pushd "$(dirname "$0")" pushd "$(dirname "$0")"
ARCH="$(uname -m)"
OS="$(uname -o)"
LIB_A="libsqlite3_${ARCH}"
if clang -v &> /dev/null; then if clang -v &> /dev/null; then
CC=clang CC=clang
@ -17,13 +17,14 @@ else
fi fi
if [ $OS == "Darwin" ]; then if [ $OS == "Darwin" ]; then
libtool -V &> /dev/null || ( echo "Missing 'libtool'"; exit 2 ) libtool -V &> /dev/null || { echo "Missing 'libtool'"; exit 2 }
$CC -c -O3 -Qn -arch x86_64 -o "x86_64.o" "./sqlite3.c" -DSQLITE_OMIT_DEPRECATED -DSQLITE_OMIT_UTF16 -DSQLITE_OMIT_TEST_CONTROL
libtool -static "x86_64.o" -o "../lib/${LIB_A}_x64.a"
$CC -c -O3 -Qn -arch arm64 -o "arm64.o" "./sqlite3.c" -DSQLITE_OMIT_DEPRECATED -DSQLITE_OMIT_UTF16 -DSQLITE_OMIT_TEST_CONTROL
libtool -static "arm64.o" -o "../lib/${LIB_A}_arm64.a"
fi fi
$CC -c -O3 -Qn "./sqlite3.c" -DSQLITE_OMIT_DEPRECATED -DSQLITE_OMIT_UTF16 -DSQLITE_OMIT_TEST_CONTROL
if [ $OS == "Darwin" ]; then
libtool -static "sqlite3.o" -o "../lib/${LIB_A}.a"
fi
rm *.o &> /dev/null rm *.o &> /dev/null
rm *.tmp &> /dev/null rm *.tmp &> /dev/null

File diff suppressed because it is too large Load Diff