ziran.toml and ziran.lock pin the Ziran toolchain, Kryon, Game2D, the Daochi client, and the C libraries (as source packages) at the commits the vendor submodules used. scripts/packages.sh bootstraps the locked toolchain, runs ziran fetch, and links each checkout under build/packages/; make, Gradle, and CI run it before building. make package-check replaces no-vendor-edits. Co-Authored-By: Claude Opus 5.5 <[email protected]>
21 lines
688 B
Bash
21 lines
688 B
Bash
#!/bin/sh
|
|
set -eu
|
|
|
|
root=$(CDPATH= cd -- "$(dirname -- "$0")/.." && pwd)
|
|
bin=${1:-"$root/build/ziran-toolchain/bin"}
|
|
work=$root/build/sqlite-text-zi-test
|
|
mkdir -p "$work/generated"
|
|
|
|
"$bin/zi2c" --no-main --root "$root/src" \
|
|
-o "$work/generated" "$root/src/storage/sqlite.zi"
|
|
|
|
"${CC:-cc}" -std=c11 -O0 -Wall -Wextra -Werror \
|
|
-Wno-unused-function -Wno-unused-variable \
|
|
-I"$root/vendor-builds/sqlite" -I"$root/build/packages/ziran/include" \
|
|
-I"$work/generated" \
|
|
"$root/tests/sqlite_text_zi_test.c" "$work/generated/storage/sqlite.c" \
|
|
"$root/vendor-builds/sqlite/sqlite3.c" -ldl -lpthread -lm \
|
|
-o "$work/test"
|
|
|
|
env -u DISPLAY -u WAYLAND_DISPLAY "$work/test"
|