mirror of
https://github.com/asg017/sqlite-vec.git
synced 2026-04-25 08:46:49 +02:00
update patch
This commit is contained in:
parent
a27153c107
commit
c6cd03ef26
1 changed files with 20 additions and 13 deletions
|
|
@ -1,32 +1,39 @@
|
|||
diff --git a/embed/build.sh b/embed/build.sh
|
||||
index 014bd22..f9ccc7d 100755
|
||||
index 6141efd..b4f0ebe 100755
|
||||
--- a/embed/build.sh
|
||||
+++ b/embed/build.sh
|
||||
@@ -21,6 +21,7 @@ WASI_SDK="$ROOT/tools/wasi-sdk-23.0/bin"
|
||||
@@ -23,6 +23,7 @@ trap 'rm -f sqlite3.tmp' EXIT
|
||||
-Wl,--initial-memory=327680 \
|
||||
-D_HAVE_SQLITE_CONFIG_H \
|
||||
-DSQLITE_CUSTOM_INCLUDE=sqlite_opt.h \
|
||||
+ -DSQLITE_VEC_OMIT_FS=1 \
|
||||
+ -DSQLITE_VEC_OMIT_FS=1 \
|
||||
$(awk '{print "-Wl,--export="$0}' exports.txt)
|
||||
|
||||
trap 'rm -f sqlite3.tmp' EXIT
|
||||
|
||||
"$BINARYEN/wasm-ctor-eval" -g -c _initialize sqlite3.wasm -o sqlite3.tmp
|
||||
@@ -30,4 +31,4 @@ trap 'rm -f sqlite3.tmp' EXIT
|
||||
sqlite3.tmp -o sqlite3.wasm \
|
||||
--enable-simd --enable-mutable-globals --enable-multivalue \
|
||||
--enable-bulk-memory --enable-reference-types \
|
||||
- --enable-nontrapping-float-to-int --enable-sign-ext
|
||||
\ No newline at end of file
|
||||
+ --enable-nontrapping-float-to-int --enable-sign-ext
|
||||
diff --git a/sqlite3/main.c b/sqlite3/main.c
|
||||
index 4fb926b..4cade42 100644
|
||||
index 4fb926b..869d38b 100644
|
||||
--- a/sqlite3/main.c
|
||||
+++ b/sqlite3/main.c
|
||||
@@ -16,7 +16,7 @@
|
||||
#include "time.c"
|
||||
@@ -17,6 +17,7 @@
|
||||
#include "vfs.c"
|
||||
#include "vtab.c"
|
||||
-
|
||||
|
||||
+#include "../../sqlite-vec.c"
|
||||
sqlite3_destructor_type malloc_destructor = &free;
|
||||
|
||||
|
||||
__attribute__((constructor)) void init() {
|
||||
@@ -28,4 +28,5 @@ __attribute__((constructor)) void init() {
|
||||
@@ -28,4 +29,5 @@ __attribute__((constructor)) void init() {
|
||||
sqlite3_auto_extension((void (*)(void))sqlite3_series_init);
|
||||
sqlite3_auto_extension((void (*)(void))sqlite3_uint_init);
|
||||
sqlite3_auto_extension((void (*)(void))sqlite3_time_init);
|
||||
+ sqlite3_auto_extension((void (*)(void))sqlite3_vec_init);
|
||||
}
|
||||
-}
|
||||
\ No newline at end of file
|
||||
+ sqlite3_auto_extension((void (*)(void))sqlite3_vec_init);
|
||||
+}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue