termux / termux-packages

A package build system for Termux.
https://termux.dev
Other
13.33k stars 3.06k forks source link

[Bug]: kf6-kconfig not working with the build system (cross compilation) #21647

Closed knyipab closed 1 month ago

knyipab commented 1 month ago

Problem description

For the kf6-kconfig package, the libexec binaries kconfig_compiler_kf6 and kconf_update are executed in compile time with cmake (KF6ConfigMacros.cmake). So there should be a version built for the ubuntu image. Error is encountered when I building kdenlive with Github Actions.

What steps will reproduce the bug?

When building kdenlive, below error is shown and indicates that kconfig_compiler_kf6 should be built for the ubuntu image.

[95/371] Generating ui_vectorscope_ui.h
[96/371] Generating kdenlivesettings.h, kdenlivesettings.cpp
FAILED: src/kdenlivesettings.h src/kdenlivesettings.cpp /home/builder/.termux-build/kdenlive/build/src/kdenlivesettings.h /home/builder/.termux-build/kdenlive/build/src/kdenlivesettings.cpp 
cd /home/builder/.termux-build/kdenlive/build/src && /data/data/com.termux/files/usr/lib/libexec/kf6/kconfig_compiler_kf6 /home/builder/.termux-build/kdenlive/src/src/kdenlivesettings.kcfg /home/builder/.termux-build/kdenlive/src/src/kdenlivesettings.kcfgc -d /home/builder/.termux-build/kdenlive/build/src/
/bin/sh: 1: /data/data/com.termux/files/usr/lib/libexec/kf6/kconfig_compiler_kf6: Exec format error
[97/371] Generating moc_definitions.cpp
[98/371] Generating ui_wipeval_ui.h
[99/371] Generating moc_mainwindowadaptor.cpp
ninja: build stopped: subcommand failed.

What is the expected behavior?

It is also shown in the PR #21646 (kf6-kconfig-cross as a temporary solution) that the built kconfig_compiler_kf6 for ubuntu and dirty patching the lib/cmake/KF6Config/KF6ConfigCompilerTargets-release.cmake will work for kdenlive.

However, it should be better implemented just like qt6-qt*-cross-tools. I tried but extra-cmake-modules does not work for the ubuntu host build. I do not have the expertise and grateful for anyone's help. Thanks.

System information

Not relevant
knyipab commented 1 month ago

Let me do it myself in #21646