package/util-linux: fix detection of ncurses
PATCH 1/1 package/util-linux: fix detection of ncurses
the configure script seems to use the NCURSES6_CONFIG variable, however it will still check for a system ncurses6-config and prefer this script if available.
Change to using ac_cv_prog_NCURSES[W]6_CONFIG override which works always
--- package/util-linux/util-linux.mk | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-)
package/util-linux/util-linux.mk +2 -4
@@ -77,11 +77,9 @@ endif ifeq ($(BR2_PACKAGE_NCURSES),y) UTIL_LINUX_DEPENDENCIES += ncurses ifeq ($(BR2_PACKAGE_NCURSES_WCHAR),y) -UTIL_LINUX_CONF_OPTS += --with-ncursesw -UTIL_LINUX_CONF_ENV += NCURSESW6_CONFIG=$(STAGING_DIR)/usr/bin/$(NCURSES_CONFIG_SCRIPTS) +UTIL_LINUX_CONF_OPTS += --with-ncursesw ac_cv_prog_NCURSESW6_CONFIG=$(STAGING_DIR)/usr/bin/$(NCURSES_CONFIG_SCRIPTS) else -UTIL_LINUX_CONF_OPTS += --without-ncursesw --with-ncurses --disable-widechar -UTIL_LINUX_CONF_ENV += NCURSES6_CONFIG=$(STAGING_DIR)/usr/bin/$(NCURSES_CONFIG_SCRIPTS) +UTIL_LINUX_CONF_OPTS += --without-ncursesw --with-ncurses --disable-widechar ac_cv_prog_NCURSES6_CONFIG=$(STAGING_DIR)/usr/bin/$(NCURSES_CONFIG_SCRIPTS) endif else ifeq ($(BR2_USE_WCHAR),y)
Signature · 6 lines
2.39.2 _______________________________________________ buildroot mailing list [email protected] https://lists.buildroot.org/mailman/listinfo/buildroot
Quoted 5 lines
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
"Norbert" == Norbert Lange <[email protected]> writes:
the configure script seems to use the
NCURSES6_CONFIGvariable, however it will still check for a system ncurses6-config and prefer this script if available.
Where do you see that? Looking at configure I see the normal ac_cv_prog_FOO / check FOO / fallback to program:
if test ${ac_cv_prog_NCURSESW6_CONFIG+y}
then :
printf %s "(cached) " >&6
else $as_nop
if test -n "$NCURSESW6_CONFIG"; then ac_cv_prog_NCURSESW6_CONFIG="$NCURSESW6_CONFIG" # Let the user override the test.
else
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
for as_dir in $PATH
do
IFS=$as_save_IFS
case $as_dir in #(((
'') as_dir=./ ;;
*/) ;;
*) as_dir=$as_dir/ ;;
esac
for ac_exec_ext in '' $ac_executable_extensions; do
if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
ac_cv_prog_NCURSESW6_CONFIG="${ac_tool_prefix}ncursesw6-config"
printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
break 2 fi
done
What is the error you are seeing exactly?
Signature · 5 lines
Bye, Peter Korsgaard _______________________________________________ buildroot mailing list [email protected] https://lists.buildroot.org/mailman/listinfo/buildroot
Am Mi., 6. Sept. 2023 um 19:20 Uhr schrieb Peter Korsgaard <[email protected]>:
Quoted 32 lines
Quoted 6 lines
Quoted 2 lines
Quoted 2 lines
Quoted 2 lines
Quoted 2 lines
"Norbert" == Norbert Lange <[email protected]> writes:
the configure script seems to use the
NCURSES6_CONFIGvariable, however it will still check for a system ncurses6-config and prefer this script if available.Where do you see that? Looking at configure I see the normal
ac_cv_prog_FOO/ check FOO / fallback to program:if test ${ac_cv_prog_NCURSESW6_CONFIG+y}
then :
printf %s "(cached) " >&6
else $as_nop
if test -n "$NCURSESW6_CONFIG"; then ac_cv_prog_NCURSESW6_CONFIG="$NCURSESW6_CONFIG" # Let the user override the test.
else
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
foras_dirin $PATH
do
IFS=$as_save_IFS
case $as_dir in #((('') as_dir=./ ;; */) ;; *) as_dir=$as_dir/ ;; esac for ac_exec_ext in '' $ac_executable_extensions; do if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then ac_cv_prog_NCURSESW6_CONFIG="${ac_tool_prefix}ncursesw6-config" printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 break 2
Quoted 4 lines
fi
doneWhat is the error you are seeing exactly?
I see in the config log, that buildroots ncursesw6-config is used, and then following that /usr/bin/ncursesw6-config is detected. Then the build fails as libtinfo.so is missing.
By setting ac_cv_prog_NCURSESW6_CONFIG (applying this patch),
I see in the config log, that buildroots ncursesw6-config is used. Then the build succeeds.
If you asked me about where the error is buried in configure hell-script, I demand the certainly following psychological harm compensated.
Quoted 3 lines
--
Bye, Peter Korsgaard
Norbert
_______________________________________________
buildroot mailing list
[email protected]
https://lists.buildroot.org/mailman/listinfo/buildroot