From 29e2a1208b9cf6b445c3da95a81d036f62fe5525 Mon Sep 17 00:00:00 2001 From: Boris Batkin Date: Mon, 7 Sep 2026 17:51:05 -0700 Subject: [PATCH] the SDK installs include/daScript/builtin/ast_gen.inc and debugapi_gen.inc - the shipped aot_builtin_ast.h includes ast_gen.inc, so an SDK consumer's AOT translation unit that touched the ast module failed to compile with 'daScript/builtin/ast_gen.inc' file not found (dasProfile's AOT companion on a Debian box), while the tree compiled it from its own include directory; ci/smoke_test_bundle.sh checks that every shipped header's include the table names is in the bundle, MISSING when it is not --- CMakeLists.txt | 7 +++++++ ci/smoke_test_bundle.sh | 15 +++++++++++++++ 2 files changed, 22 insertions(+) diff --git a/CMakeLists.txt b/CMakeLists.txt index 7b9a53c8d9..90197d63e9 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1820,6 +1820,13 @@ file(GLOB DAS_BUILTIN_HEADERS ${PROJECT_SOURCE_DIR}/src/builtin/*.h) install(FILES ${DAS_BUILTIN_HEADERS} DESTINATION include/daScript/builtin ) +# The generated binding tables: the shipped aot_builtin_ast.h includes ast_gen.inc, so without it +# an SDK consumer's AOT translation unit that touches the ast module fails to compile. +install(FILES + ${PROJECT_SOURCE_DIR}/include/daScript/builtin/ast_gen.inc + ${PROJECT_SOURCE_DIR}/include/daScript/builtin/debugapi_gen.inc + DESTINATION include/daScript/builtin +) # libDaScriptNano ships as sources, not as a built library: an embedder cross- # compiles it for their own target with their own flags, which is the whole diff --git a/ci/smoke_test_bundle.sh b/ci/smoke_test_bundle.sh index 542db39648..88811fde1a 100644 --- a/ci/smoke_test_bundle.sh +++ b/ci/smoke_test_bundle.sh @@ -200,6 +200,21 @@ for entry in "${SHIPPED_EXE_TESTS[@]}"; do fi done +echo +echo "Shipped headers' includes:" +# A shipped header that includes a file the install rule leaves out compiles in the tree and +# fails in every SDK consumer; each pair below is a shipped header and a file it includes. +for pair in "include/daScript/simulate/aot_builtin_ast.h:include/daScript/builtin/ast_gen.inc"; do + header="${pair%%:*}"; inc="${pair##*:}" + if [[ -f "$BUNDLE/$header" && -f "$BUNDLE/$inc" ]]; then + printf ' %-52s OK\n' "$inc" + PASS=$((PASS + 1)) + else + printf ' %-52s MISSING (included by %s)\n' "$inc" "$header" + FAIL=$((FAIL + 1)) + fi +done + echo echo "Runtime launch:" run_check "mcp.das (empty stdin)" bash -c \