Skip to content

TotalCross/totalcross-sqlite3-build

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

TotalCross SQLite3 Static Build

This project builds SQLite3 as a static library using the same SQLite compile options used by the TotalCross VM build.

It produces two variants:

  • plain: SQLite3 without SQLITE_HAS_CODEC
  • crypto: SQLite3 with SQLITE_HAS_CODEC

All other SQLite compile definitions match the current TotalCross CMake build.

Source Inputs

The build accepts one of these source inputs:

  • -DSQLITE3_SOURCE_DIR=/path/to/source
  • -DSQLITE3_SOURCE_ARCHIVE=/path/to/sqlite.tar.gz
  • -DSQLITE3_SOURCE_URL=https://.../sqlite.tar.gz

If none is provided, the plain upstream SQLite amalgamation sqlite-amalgamation-3320300.zip is downloaded from sqlite.org.

The source directory or archive must contain exactly one sqlite3.c and one sqlite3.h.

Local Build

cmake -S . -B build -G Ninja \
  -DCMAKE_BUILD_TYPE=Release \
  -DSQLITE3_VARIANT=plain
cmake --build build
cmake --install build --prefix build/install

For the crypto variant:

cmake -S . -B build-crypto -G Ninja \
  -DCMAKE_BUILD_TYPE=Release \
  -DSQLITE3_VARIANT=crypto \
  -DSQLITE3_SOURCE_ARCHIVE=/path/to/sqlite-see.tar.gz
cmake --build build-crypto
cmake --install build-crypto --prefix build-crypto/install

SQLite SEE Download

The helper script supports the cookie-based SQLite SEE login flow:

SQLITE_SEE_USER=... SQLITE_SEE_PASSWORD=... \
  scripts/fetch-see.sh \
  --url https://sqlite.org/see/tarball/sqlite_encryption_extension-20200618142025-7bff7d2607.tar.gz \
  --output build/sqlite-see.tar.gz

The script validates the result with tar -tzf so an HTML login page fails early.

Artifact Layout

Packaged artifacts use this layout:

sqlite3/
  plain|crypto/
    <platform>/<arch>/
      include/
        sqlite3.h
        sqlite3ext.h
      lib/
        libsqlite3.a
      manifest.txt

About

This project builds SQLite3 as a static library using the same SQLite compile options used by the TotalCross VM build.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors