diff --git a/local/recipes/kde/kf6-kio/recipe.toml b/local/recipes/kde/kf6-kio/recipe.toml index bff9516b5c..5883a03eff 100644 --- a/local/recipes/kde/kf6-kio/recipe.toml +++ b/local/recipes/kde/kf6-kio/recipe.toml @@ -165,6 +165,23 @@ if start != -1 and end != -1 and start < end: askuser.write_text(text) PY +# --- Redox source fixes (applied at build time so restore-sources.sh cannot +# --- revert them) --- +# previewjob.cpp: a prior port left an unterminated `#if defined(Q_OS_UNIX) && +# ... && !defined(Q_OS_REDOX)` in place of the pristine `#include ` +# (the edit also dropped that include), giving "unterminated #if". Restore it. +sed -i 's|^#if defined(Q_OS_UNIX) && !defined(Q_OS_ANDROID) && !defined(Q_OS_HAIKU) && !defined(Q_OS_REDOX)$|#include |' \ + "${COOKBOOK_SOURCE}/src/gui/previewjob.cpp" 2>/dev/null || true + +# hostinfo.cpp: relibc has no BIND resolver headers; only _PATH_RESCONF is used +# and it has a "/etc/resolv.conf" fallback, so drop the includes (redox target). +sed -i '/#include /d; /#include /d' \ + "${COOKBOOK_SOURCE}/src/core/hostinfo.cpp" 2>/dev/null || true + +# Qt6::Test is autotests-only (BUILD_TESTING) and not built for the cross target. +sed -i 's|CONFIG REQUIRED Widgets Network Concurrent Xml Test)|CONFIG REQUIRED Widgets Network Concurrent Xml)|' \ + "${COOKBOOK_SOURCE}/CMakeLists.txt" 2>/dev/null || true + rm -f CMakeCache.txt rm -rf CMakeFiles