]> git.ipfire.org Git - thirdparty/openembedded/openembedded-core.git/commit
cmake-native: prevent host libidn2 contamination
authorJaipaul Cheernam <jaipaul.cheernam@est.tech>
Thu, 18 Jun 2026 07:54:05 +0000 (09:54 +0200)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Mon, 29 Jun 2026 09:21:50 +0000 (10:21 +0100)
commit861eaeb79f12273baddd24f615997ac78cfcb2a3
treea780c2d1c42e6bce8aa141a3f0e542d617c6f270
parent4478086b7b13ec365dfb4b2335fb35013e8ceea0
cmake-native: prevent host libidn2 contamination

The bundled cmcurl in CMake 4.3.x unconditionally enables USE_LIBIDN2
and calls find_package(Libidn2). On hosts with libidn2-devel installed
(common on RHEL/EL8), this detects the host library during configure
but the compile fails because the compiler is correctly restricted to
the native sysroot:

  fatal error: idn2.h: No such file or directory

This was introduced in the upgrade from CMake 3.28.x to 4.3.x, where
the bundled cmcurl added find_package(Libidn2) for IDN support.

cmake-native does not need IDN support in its internal curl usage.
Use CMAKE_DISABLE_FIND_PACKAGE_Libidn2 to prevent the host package
from being found without patching the source.

Signed-off-by: Jaipaul Cheernam <jaipaul.cheernam@est.tech>
Reviewed-by: Anders Heimer <anders.heimer@est.tech>
Signed-off-by: Mathieu Dubois-Briand <mathieu.dubois-briand@bootlin.com>
Signed-off-by: Ross Burton <ross.burton@arm.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
meta/recipes-devtools/cmake/cmake-native_4.3.3.bb