package/icu: disable icu-config for host package
PATCH 1/1 package/icu: disable icu-config for host package
Fixes:
http://autobuild.buildroot.net/results/6a2/6a2a4ed90c1a829e7b9442aaaaa1cd6e5efd9aab/
python-pyicu picks up ldflags from host version of icu-config
---
Building PyICU 2.10.2 for ICU 70.1 (max ICU major version supported: 72)
(running 'icu-config --cxxflags --cppflags')
Adding CFLAGS="-std=c++11 -I/home/buildroot/autobuild/instance-1/output-1/host/include" from /home/buildroot/autobuild/instance-1/output-1/host/bin/icu-config (running 'icu-config --ldflags')
Adding LFLAGS="-L/home/buildroot/autobuild/instance-1/output-1/host/lib -licui18n -licuuc -licudata" from /home/buildroot/autobuild/instance-1/output-1/host/bin/icu-config running build
---
leading to linking errors:/home/buildroot/autobuild/instance-1/output-1/host/lib/libicui18n.so: file not recognized: file format not recognized
The icu-config script was deprecated upstream:
https://unicode-org.github.io/icu/userguide/icu/howtouseicu.html#notes-on-icu-config
To fix the build error we do not install the host version anymore:
---
Building PyICU 2.10.2 for ICU 70.1 (max ICU major version supported: 72)
(running 'icu-config --cxxflags --cppflags')
Could not configure CFLAGS with icu-config
(running 'pkg-config --cflags icu-i18n')
(running 'icu-config --ldflags')
Could not configure LFLAGS with icu-config
(running 'pkg-config --libs icu-i18n')
Adding LFLAGS="-licui18n -L/home/bernd/buildroot/output/per-package/python-pyicu/host/bin/../sh4-buildroot-linux-gnu/sysroot/usr/lib -licuuc -licudata" from /home/bernd/buildroot/output/per-package/python-pyicu/host/bin/pkg-config running build
---
--- package/icu/icu.mk | 1 + 1 file changed, 1 insertion(+)
package/icu/icu.mk +1 -0
@@ -48,6 +48,7 @@ ICU_CONF_ENV += ac_cv_func_strtod_l=no endif HOST_ICU_CONF_OPTS = \ + --disable-icu-config \ --disable-samples \ --disable-tests \ --disable-extras \
Signature · 6 lines
2.39.2 _______________________________________________ buildroot mailing list [email protected] https://lists.buildroot.org/mailman/listinfo/buildroot
Bernd, All,
On 2023-05-16 19:34 +0200, Bernd Kuhls spake thusly:
Quoted 23 lines
Fixes:
http://autobuild.buildroot.net/results/6a2/6a2a4ed90c1a829e7b9442aaaaa1cd6e5efd9aab/python-pyicu picks up ldflags from host version of icu-config
---
Building PyICU 2.10.2 for ICU 70.1 (max ICU major version supported: 72)(running 'icu-config --cxxflags --cppflags')
Adding CFLAGS="-std=c++11 -I/home/buildroot/autobuild/instance-1/output-1/host/include" from/home/buildroot/autobuild/instance-1/output-1/host/bin/icu-config(running 'icu-config --ldflags')
Adding LFLAGS="-L/home/buildroot/autobuild/instance-1/output-1/host/lib -licui18n -licuuc -licudata" from/home/buildroot/autobuild/instance-1/output-1/host/bin/icu-configrunning build
---
leading to linking errors:/home/buildroot/autobuild/instance-1/output-1/host/lib/libicui18n.so: file not recognized: file format not recognizedThe icu-config script was deprecated upstream:
https://unicode-org.github.io/icu/userguide/icu/howtouseicu.html#notes-on-icu-configTo fix the build error we do not install the host version anymore:
---
Building PyICU 2.10.2 for ICU 70.1 (max ICU major version supported: 72)
Quoted 9 lines
(running 'icu-config --cxxflags --cppflags')
Could not configure CFLAGS with icu-config
(running 'pkg-config --cflags icu-i18n')
(running 'icu-config --ldflags')
Could not configure LFLAGS with icu-config
(running 'pkg-config --libs icu-i18n')
Adding LFLAGS="-licui18n -L/home/bernd/buildroot/output/per-package/python-pyicu/host/bin/../sh4-buildroot-linux-gnu/sysroot/usr/lib -licuuc -licudata" from/home/bernd/buildroot/output/per-package/python-pyicu/host/bin/pkg-configrunning build
---
But that would not fix the build of the host system itself has icu-config in the PATH (for whatever reason).
I think the proper solution would be to make pyicu fully transition to using pkg-config, e.g. with a patch like:
diff --git a/setup.py b/setup.py
index 176c9ab..961a7e9 100644
--- a/setup.py
+++ b/setup.py
@@ -68,7 +68,7 @@ elif platform.startswith('freebsd'):
CONFIGURE_WITH_ICU_CONFIG = {
'darwin': False,
- 'linux': True,
+ 'linux': False,
'freebsd': False, # not tested
'win32': False, # no icu-config
'sunos5': False, # not tested(which is just a cheap way to completely render the icu-config case totally dead-code, as linux is the only platform where icu-config is still used in pyicu).
Regards,
Yann E. MORIN.
Quoted 24 lines
Signed-off-by Bernd Kuhls <[email protected]>--- package/icu/icu.mk | 1 + 1 file changed, 1 insertion(+)package/icu/icu.mk +1
-0@@ -48,6 +48,7 @@ ICU_CONF_ENV += ac_cv_func_strtod_l=no endif HOST_ICU_CONF_OPTS = \ + --disable-icu-config \ --disable-samples \ --disable-tests \ --disable-extras \Signature · 6 lines
2.39.2 _______________________________________________ buildroot mailing list [email protected] https://lists.buildroot.org/mailman/listinfo/buildroot
Signature · 10 lines
.-----------------.--------------------.------------------.--------------------. | Yann E. MORIN | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: | | +33 662 376 056 | Software Designer | \ / CAMPAIGN | ___ | | +33 561 099 427 `------------.-------: X AGAINST | \e/ There is no | | http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL | v conspiracy. | '------------------------------^-------^------------------^--------------------' _______________________________________________ buildroot mailing list [email protected] https://lists.buildroot.org/mailman/listinfo/buildroot
A message that is not in the archive (sent off-list or not yet received): 20230516190356.GP2582048__25958.2416781754$1684263867$gmane$org@scaer
Am Tue, 16 May 2023 21:03:56 +0200 schrieb Yann E. MORIN:
Quoted 10 lines
diff --git a/setup.py b/setup.py
index 176c9ab..961a7e9 100644
--- a/setup.py
+++ b/setup.py
@@ -68,7 +68,7 @@ elif platform.startswith('freebsd'):
CONFIGURE_WITH_ICU_CONFIG = {
'darwin': False,
- 'linux': True,
+ 'linux': False,Hi Yann,
did you run-time test your proposal?
During my tests a similar fix was not enough due to https://
gitlab.pyicu.org/main/pyicu/-/blob/main/setup.py#L93
Regards, Bernd
_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildroot
Bernd, All,
On 2023-05-16 21:08 +0200, Bernd Kuhls spake thusly:
Quoted 7 lines
Am Tue, 16 May 2023 21:03:56 +0200 schrieb Yann E. MORIN:
Quoted 6 lines
diff --git a/setup.py b/setup.py index 176c9ab..961a7e9 100644 --- a/setup.py +++ b/setup.py @@ -68,7 +68,7 @@ elif platform.startswith('freebsd'):
Quoted 5 lines
Quoted 4 lines
CONFIGURE_WITH_ICU_CONFIG= {
'darwin': False,
- 'linux': True,
+ 'linux': False,did you run-time test your proposal?
Nope, it was just a quick analysis to drive you in another direction which I believe is better.
Quoted 2 lines
During my tests a similar fix was not enough due to https://
gitlab.pyicu.org/main/pyicu/-/blob/main/setup.py#L93
Indeed. Then just patch it out too...
If we don't do that, then an icu-config on the host *is* going to cause an issue, even if that's not our icu-config. So pyicu must be fixed.
And since pyicu already has support for using pkg-config, then let's just ensure it uses that instead of icu-config.
And of-sourse, that means pyicu needs to gain a dependency on host-pkgconf...
Regards,
Yann E. MORIN.
Signature · 10 lines
.-----------------.--------------------.------------------.--------------------. | Yann E. MORIN | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: | | +33 662 376 056 | Software Designer | \ / CAMPAIGN | ___ | | +33 561 099 427 `------------.-------: X AGAINST | \e/ There is no | | http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL | v conspiracy. | '------------------------------^-------^------------------^--------------------' _______________________________________________ buildroot mailing list [email protected] https://lists.buildroot.org/mailman/listinfo/buildroot
PATCH 1/1 package/icu: disable icu config
In reply to Bernd KuhlsFrom: Thomas Devoogdt <[email protected]>
Seen while using BR2_PER_PACKAGE_DIRECTORIES, not sure on how to reproduce.
Fixes:
/usr/bin/install: cannot stat 'config/icu-config.1': No such file or directory
2025-10-25T00:09:10 make[2]: *** [Makefile:359: install-manx] Error 1 2025-10-25T00:09:10 make[2]: Leaving directory '/home/thomas/buildroot/build/output/build/host-icu-73-2/source' 2025-10-25T00:09:10 make[1]: *** [Makefile:153: install-recursive] Error 2 2025-10-25T00:09:10 make[1]: *** Waiting for unfinished jobs.... 2025-10-25T00:09:10 make[1]: Leaving directory '/home/thomas/buildroot/build/output/build/host-icu-73-2/source' 2025-10-25T00:09:10 make: *** [package/pkg-generic.mk:283: /home/thomas/buildroot/build/output/build/host-icu-73-2/.stamp_host_installed] Error 2 2025-10-25T00:09:10 make: *** Waiting for unfinished jobs....
There was a proposal in the past to do exactly the same:
https://lore.kernel.org/buildroot/[email protected]/
The icu-config script was deprecated upstream:
https://unicode-org.github.io/icu/userguide/icu/howtouseicu.html#notes-on-icu-config
--- package/icu/icu.mk | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
package/icu/icu.mk +2 -1
@@ -49,7 +49,8 @@ HOST_ICU_CONF_OPTS = \ --disable-tests \ --disable-extras \ --disable-icuio \ - --disable-layout + --disable-layout \ + --disable-icu-config ICU_SUBDIR = source HOST_ICU_SUBDIR = source
Signature · 6 lines
2.43.0 _______________________________________________ buildroot mailing list [email protected] https://lists.buildroot.org/mailman/listinfo/buildroot
Re: [Buildroot] [PATCH v1] package/icu: disable icu config
Hello Thomas,
Quoted 6 lines · On Sat, 25 Oct 2025 16:35:57 +0200 Thomas Devoogdt <[email protected]> wrote:
From: Thomas Devoogdt <[email protected]>
Seen while using
BR2_PER_PACKAGE_DIRECTORIES, not sure on how to reproduce.Fixes:
Quoted 8 lines
/usr/bin/install: cannot stat 'config/icu-config.1': No such file or directory2025-10-25T00:09:10 make[2]: *** [Makefile:359: install-manx] Error 1 2025-10-25T00:09:10 make[2]: Leaving directory '/home/thomas/buildroot/build/output/build/host-icu-73-2/source' 2025-10-25T00:09:10 make[1]: *** [Makefile:153: install-recursive] Error 2 2025-10-25T00:09:10 make[1]: *** Waiting for unfinished jobs.... 2025-10-25T00:09:10 make[1]: Leaving directory '/home/thomas/buildroot/build/output/build/host-icu-73-2/source' 2025-10-25T00:09:10 make: *** [package/pkg-generic.mk:283: /home/thomas/buildroot/build/output/build/host-icu-73-2/.stamp_host_installed] Error 2 2025-10-25T00:09:10 make: *** Waiting for unfinished jobs....
Thanks for the patch, but the explanation is a bit weak I'm afraid. Is this a parallel build issue within the icu build system?
The thing is that even if icu-config might be deprecated by the ICU developers, how many packages using ICU still use icu-config?
Such a change would need at least a bit of analysis of how many Buildroot packages rely on icu, and a test build of those packages after removing icu-config. We don't need a 100% coverage testing on this, but at least some sanity checking with a majority of packages using icu, to see how bad the breakage might be (or not).
Thanks!
Thomas
Signature · 7 lines
Thomas Petazzoni, co-owner and CEO, Bootlin Embedded Linux and Kernel engineering and training https://bootlin.com _______________________________________________ buildroot mailing list [email protected] https://lists.buildroot.org/mailman/listinfo/buildroot
PATCH v2 1/1 package/icu: disable icu-config
From: Thomas Devoogdt <[email protected]>
Seen while using BR2_PER_PACKAGE_DIRECTORIES (parallel package building). The exact reproduction steps are unclear.
Fixes:
/usr/bin/install: cannot stat 'config/icu-config.1': No such file or directory
2025-10-25T00:09:10 make[2]: *** [Makefile:359: install-manx] Error 1 2025-10-25T00:09:10 make[2]: Leaving directory '/home/thomas/buildroot/build/output/build/host-icu-73-2/source' 2025-10-25T00:09:10 make[1]: *** [Makefile:153: install-recursive] Error 2 2025-10-25T00:09:10 make[1]: *** Waiting for unfinished jobs.... 2025-10-25T00:09:10 make[1]: Leaving directory '/home/thomas/buildroot/build/output/build/host-icu-73-2/source' 2025-10-25T00:09:10 make: *** [package/pkg-generic.mk:283: /home/thomas/buildroot/build/output/build/host-icu-73-2/.stamp_host_installed] Error 2 2025-10-25T00:09:10 make: *** Waiting for unfinished jobs....
A similar proposal was made in the past for a different reason:
https://lore.kernel.org/buildroot/[email protected]/
The icu-config script is deprecated upstream:
https://unicode-org.github.io/icu/userguide/icu/howtouseicu.html#notes-on-icu-config
Therefore, it should be disabled entirely.
Testing coverage (all packages directly selecting BR2_PACKAGE_ICU):
$ cat icu.config BR2_PACKAGE_MESA3D=y BR2_PACKAGE_MESA3D_GALLIUM_DRIVER_SOFTPIPE=y BR2_PACKAGE_MESA3D_OPENGL_EGL=y BR2_PACKAGE_MESA3D_OPENGL_GLX=y BR2_PACKAGE_MESA3D_OPENGL_ES=y BR2_PACKAGE_LIBGTK3=y BR2_PACKAGE_LIBGTK3_X11=y BR2_PACKAGE_XORG7=y BR2_PACKAGE_CPPCMS=y BR2_PACKAGE_GERBERA=y BR2_PACKAGE_PHP=y BR2_PACKAGE_PYTHON_PYICU=y BR2_PACKAGE_QT5=y BR2_PACKAGE_QT5BASE=y BR2_PACKAGE_QT5WEBKIT=y BR2_PACKAGE_WEBKITGTK=y BR2_PACKAGE_WPEWEBKIT=y BR2_PACKAGE_PYTHON3=y
$ ./utils/test-pkg -c icu.config -p icu
bootlin-armv5-uclibc [1/6]: OK
bootlin-armv7-glibc [2/6]: OK
bootlin-armv7m-uclibc [3/6]: SKIPPED
bootlin-x86-64-musl [4/6]: OK
br-arm-full-static [5/6]: SKIPPED
arm-aarch64 [6/6]: OK---
v2: Tested with minimal config covering all packages that select BR2_PACKAGE_ICU.
Updated commit message with test results.
--- package/icu/icu.mk | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
package/icu/icu.mk +2 -1
@@ -49,7 +49,8 @@ HOST_ICU_CONF_OPTS = \ --disable-tests \ --disable-extras \ --disable-icuio \ - --disable-layout + --disable-layout \ + --disable-icu-config ICU_SUBDIR = source HOST_ICU_SUBDIR = source
Signature · 6 lines
2.43.0 _______________________________________________ buildroot mailing list [email protected] https://lists.buildroot.org/mailman/listinfo/buildroot