Re: dpkg's ability to disable wide char ncurses (patch included)
On Sat, 2009-11-21 at 04:28:55 -0600, Yuri Vasilevski wrote:
> As pointed out by guillem in:
> Gentoo has an obsolete sed substitution to disable Unicode support in
> dselect. This got broken when dpkg's configure script learned how to
> autodetect the availability of wide char enabled ncurces library. The
> problem is that now if there are headers for the wide char ncurses lib,
> they are always used. (The ability to link against narrow char lib is
> there via exporting ac_cv_lib_ncursesw_initscr=no).
> So I made this patch that creates a --disable-unicode ./configure flag,
> that when present will disable checks for the wide char ncurses library
> and use the narrow char variant even on a system with both variants
I modified the patch a bit to avoid the duplication, and did some
other fixes and reformatting. Thanks!
> diff -Naurp dpkg-184.108.40.206.orig/m4/unicode.m4 dpkg-220.127.116.11/m4/unicode.m4
> --- dpkg-18.104.22.168.orig/m4/unicode.m4 1970-01-01 00:00:00.000000000 +0000
> +++ dpkg-22.214.171.124/m4/unicode.m4 2009-11-21 09:46:53.000000000 +0000
> @@ -0,0 +1,21 @@
> +# unicode.m4
> +dnl Copyright (C) 2009 Free Software Foundation, Inc.
> +dnl This file is free software; the Free Software Foundation
> +dnl gives unlimited permission to copy and/or distribute it,
> +dnl with or without modifications, as long as this notice is preserved.
> +dnl Author:
> +dnl Yuri Vasilevski <email@example.com>, 2009
It seems you based this file on the nls.m4 one, so I corrected the
Copyright statement for the FSF and added yours in addition. Hope
Renamed this to DPKG_UNICODE, as we should not be stomping on automake
> + AC_MSG_CHECKING([whether UNICODE is requested])
> + dnl Default: UNICODE is enabled
> + AC_ARG_ENABLE(unicode,
> + [ --disable-unicode do not use Unicode (wide characters) support],
And used AS_HELP_STRING here.
> + USE_UNICODE=$enableval, USE_UNICODE=yes)
> + AC_MSG_RESULT($USE_UNICODE)
> + AC_SUBST(USE_UNICODE)