Skip to content

Commit fc32648

Browse files
authored
Add documentation for enabling extensions (#399)
1 parent 751f164 commit fc32648

File tree

1 file changed

+14
-0
lines changed

1 file changed

+14
-0
lines changed

README.md

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -285,3 +285,17 @@ For each [release](https://github.com/sql-js/sql.js/releases/), you will find a
285285

286286
- Install the EMSDK, [as described here](https://emscripten.org/docs/getting_started/downloads.html)
287287
- Run `npm run rebuild`
288+
289+
In order to enable extensions like JSON1 or FTS5, change the CFLAGS in the [Makefile](Makefile) and rebuild:
290+
291+
``` diff
292+
CFLAGS = \
293+
-O2 \
294+
-DSQLITE_OMIT_LOAD_EXTENSION \
295+
-DSQLITE_DISABLE_LFS \
296+
-DSQLITE_ENABLE_FTS3 \
297+
-DSQLITE_ENABLE_FTS3_PARENTHESIS \
298+
+ -DSQLITE_ENABLE_FTS5 \
299+
+ -DSQLITE_ENABLE_JSON1 \
300+
-DSQLITE_THREADSAFE=0
301+
```

0 commit comments

Comments
 (0)