fix: Qt host build — pre-create ninja .d dependency directories

CMake ninja generator may not create *.dir output directories
before the first compilation pass, causing 'fatal error: opening
dependency file ... No such file or directory' during the Qt host
tools build (moc, uic, qtwaylandscanner). Add a find+mkdir loop
between cmake configure and cmake --build to pre-create them.
This commit is contained in:
2026-07-09 21:11:47 +03:00
parent b079fc8ef6
commit f1cf01b222
+6
View File
@@ -221,6 +221,12 @@ if [ ! -f "${HOST_BUILD}/libexec/moc" ] || [ ! -f "${HOST_STAMP}" ]; then
-DFEATURE_wayland=ON \
-DFEATURE_qtwaylandscanner=ON \
-Wno-dev
# CMake ninja generator may not create .d dependency directories
# before the first compilation pass. Pre-create them to avoid
# "fatal error: opening dependency file ... No such file or directory".
find "${HOST_QTBASE_BUILD}" -name "*.dir" -type d 2>/dev/null | while read dir; do
test -d "$dir" || mkdir -p "$dir"
done
(
cd "${HOST_QTBASE_BUILD}"
env -i \