mirror of
https://github.com/tursodatabase/libsql.git
synced 2025-06-02 03:23:10 +00:00
ffi: blocklist wasm fns from bindgen (#1166)
This commit is contained in:
libsql-ffi
@ -529,6 +529,16 @@ mod bindings {
|
||||
let host_arch = std::env::var("HOST").unwrap();
|
||||
let is_cross_compiling = target_arch != host_arch;
|
||||
|
||||
if !cfg!(feature = "wasmtime-bindings") {
|
||||
bindings = bindings
|
||||
.blocklist_function("run_wasm")
|
||||
.blocklist_function("libsql_run_wasm")
|
||||
.blocklist_function("libsql_wasm_engine_new")
|
||||
.blocklist_function("libsql_compile_wasm_module")
|
||||
.blocklist_function("libsql_free_wasm_module")
|
||||
.blocklist_function("libsql_wasm_engine_free");
|
||||
}
|
||||
|
||||
// Note that when generating the bundled file, we're essentially always
|
||||
// cross compiling.
|
||||
if generating_bundled_bindings() || is_cross_compiling {
|
||||
|
@ -23,7 +23,6 @@ extern "C" {
|
||||
) -> ::std::os::raw::c_int;
|
||||
}
|
||||
|
||||
pub const __GNUC_VA_LIST: i32 = 1;
|
||||
pub const SQLITE_VERSION: &[u8; 7] = b"3.44.0\0";
|
||||
pub const SQLITE_VERSION_NUMBER: i32 = 3044000;
|
||||
pub const SQLITE_SOURCE_ID: &[u8; 85] =
|
||||
@ -500,8 +499,6 @@ pub const FTS5_TOKENIZE_DOCUMENT: i32 = 4;
|
||||
pub const FTS5_TOKENIZE_AUX: i32 = 8;
|
||||
pub const FTS5_TOKEN_COLOCATED: i32 = 1;
|
||||
pub const WAL_SAVEPOINT_NDATA: i32 = 4;
|
||||
pub type va_list = __builtin_va_list;
|
||||
pub type __gnuc_va_list = __builtin_va_list;
|
||||
extern "C" {
|
||||
pub static sqlite3_version: [::std::os::raw::c_char; 0usize];
|
||||
}
|
||||
@ -935,12 +932,6 @@ extern "C" {
|
||||
pub fn sqlite3_mprintf(arg1: *const ::std::os::raw::c_char, ...)
|
||||
-> *mut ::std::os::raw::c_char;
|
||||
}
|
||||
extern "C" {
|
||||
pub fn sqlite3_vmprintf(
|
||||
arg1: *const ::std::os::raw::c_char,
|
||||
arg2: va_list,
|
||||
) -> *mut ::std::os::raw::c_char;
|
||||
}
|
||||
extern "C" {
|
||||
pub fn sqlite3_snprintf(
|
||||
arg1: ::std::os::raw::c_int,
|
||||
@ -949,14 +940,6 @@ extern "C" {
|
||||
...
|
||||
) -> *mut ::std::os::raw::c_char;
|
||||
}
|
||||
extern "C" {
|
||||
pub fn sqlite3_vsnprintf(
|
||||
arg1: ::std::os::raw::c_int,
|
||||
arg2: *mut ::std::os::raw::c_char,
|
||||
arg3: *const ::std::os::raw::c_char,
|
||||
arg4: va_list,
|
||||
) -> *mut ::std::os::raw::c_char;
|
||||
}
|
||||
extern "C" {
|
||||
pub fn sqlite3_malloc(arg1: ::std::os::raw::c_int) -> *mut ::std::os::raw::c_void;
|
||||
}
|
||||
@ -2497,13 +2480,6 @@ extern "C" {
|
||||
extern "C" {
|
||||
pub fn sqlite3_str_appendf(arg1: *mut sqlite3_str, zFormat: *const ::std::os::raw::c_char, ...);
|
||||
}
|
||||
extern "C" {
|
||||
pub fn sqlite3_str_vappendf(
|
||||
arg1: *mut sqlite3_str,
|
||||
zFormat: *const ::std::os::raw::c_char,
|
||||
arg2: va_list,
|
||||
);
|
||||
}
|
||||
extern "C" {
|
||||
pub fn sqlite3_str_append(
|
||||
arg1: *mut sqlite3_str,
|
||||
@ -3504,4 +3480,3 @@ extern "C" {
|
||||
extern "C" {
|
||||
pub static sqlite3_wal_manager: libsql_wal_manager;
|
||||
}
|
||||
pub type __builtin_va_list = *mut ::std::os::raw::c_char;
|
||||
|
Reference in New Issue
Block a user