diff --git a/local/recipes/qt/qtdeclarative/recipe.toml b/local/recipes/qt/qtdeclarative/recipe.toml index 456a3ffb66..f585fab976 100644 --- a/local/recipes/qt/qtdeclarative/recipe.toml +++ b/local/recipes/qt/qtdeclarative/recipe.toml @@ -148,6 +148,18 @@ fi rm -f CMakeCache.txt rm -rf CMakeFiles +# Remove stale qlalr-generated grammar. The QML lexer/parser grammar +# (qqmljsgrammar_p.h + qqmljsgrammar.cpp) is generated by qt_process_qlalr from +# src/qml/parser/qqmljs.g; the source ships none. An incremental rebuild (e.g. +# after a relibc ABI change invalidates the fingerprint) can leave a 1-line empty +# stub that survives CMakeCache/CMakeFiles removal, so ninja considers it up to +# date and skips regeneration — every consumer of qqmljslexer_p.h then fails with +# "expected class-name" / "QQmlJS::Parser has incomplete type". Deleting the +# stale outputs forces qt_process_qlalr to regenerate them (missing output -> +# rule re-runs). This is pattern (j): stale codegen after a toolchain rebuild. +find . -name 'qqmljsgrammar_p.h' -delete 2>/dev/null || true +find . -name 'qqmljsgrammar.cpp' -delete 2>/dev/null || true + redbear_qt_link_sysroot_dirs "${COOKBOOK_SYSROOT}" plugins mkspecs metatypes modules qml # Patch masm/CheckedArithmetic.h: add missing ArithmeticOperations