diff --git a/codex-cli/scripts/install_native_deps.py b/codex-cli/scripts/install_native_deps.py index 413f66859c..de157334cd 100755 --- a/codex-cli/scripts/install_native_deps.py +++ b/codex-cli/scripts/install_native_deps.py @@ -157,16 +157,6 @@ def parse_args() -> argparse.Namespace: "built-in default workflow." ), ) - parser.add_argument( - "--allow-legacy-codex-package", - action="store_true", - # This legacy installer already consumes per-binary artifacts; keep the - # flag so newer staging workflows can call older PR branches. - help=( - "Accepted as a no-op compatibility flag for staging workflows that " - "may synthesize codex-package layouts from legacy per-binary artifacts." - ), - ) parser.add_argument( "root", nargs="?", diff --git a/codex-rs/state/BUILD.bazel b/codex-rs/state/BUILD.bazel index ec952cbad5..318fc61ff4 100644 --- a/codex-rs/state/BUILD.bazel +++ b/codex-rs/state/BUILD.bazel @@ -1,8 +1,26 @@ +load("@rules_cc//cc:defs.bzl", "cc_library") load("//:defs.bzl", "codex_rust_crate") codex_rust_crate( name = "state", crate_name = "codex_state", - build_script_data = glob(["vendor/sqlite-recover/**"]), + # Cargo uses build.rs to compile the SQLite recovery extension. Bazel wires + # the same C sources directly so the native archive is a normal dependency. + build_script_enabled = False, compile_data = glob(["goals_migrations/**", "logs_migrations/**", "migrations/**"]), + deps_extra = [":sqlite-recover"], +) + +cc_library( + name = "sqlite-recover", + srcs = [ + "vendor/sqlite-recover/dbdata.c", + "vendor/sqlite-recover/sqlite3recover.c", + ], + hdrs = [ + "vendor/sqlite-recover/sqlite3.h", + "vendor/sqlite-recover/sqlite3recover.h", + ], + includes = ["vendor/sqlite-recover"], + visibility = ["//visibility:private"], )