1. Build a gentoo system, including mutt, with the USE flag "unicode" disabled. 2. Change "unicode" to enabled and do "merge -ND @world". This fails to rebuild mutt. Mutt needs rebuilding since it formerly linked with libncurses.so, yet now must link with libncursesW.so. Reproducible: Always Steps to Reproduce: 1.See above 2. 3. Actual Results: The 8-bit mutt in a unicode environment outputs rubbish where non-ASCII characters are output.
In what way exactly does it fail ? Do you mean "mutt needs a 'unicode? (ncurses[unicode=]) ' dep" ?
mutt (built with libncurses.so) fails in a UTF-8 locale thus: Go to the message index screen; in place of the expected line graphics appear ASCIIified strings like "M-b~T~\". Non-ASCII alphabetic characters are also mangled. > Do you mean "mutt needs a 'unicode? (ncurses[unicode=]) ' dep" ? I think so. I don't fully understand the above code snippet.
I don't quite understand yet what you want. Is it that you want an unicode flag which forces mutt to use ncursesw vs ncurses?
I want a _change_ in the unicode flag to trigger a rebuild of mutt.
since mutt doesn't have a unicode flag, it means one has to be added
Yes. This is hopfully straightforward.
I looked briefly at the code, and unfortunately it isn't. I don't consider this to be a common case (what you did), but patches are welcome.
No, this will happen only rarely. Nevertheless it is a bug. Simply inserting "unicode" into IUSE fixes it for me: acm@acm /usr/portage/mail-client/mutt $ diff -u mutt-1.5.21-r1.ebuild{~,} --- mutt-1.5.21-r1.ebuild~ 2011-04-17 18:31:15.000000000 +0000 +++ mutt-1.5.21-r1.ebuild 2011-05-13 18:28:22.000000000 +0000 @@ -13,7 +13,7 @@ SRC_URI="ftp://ftp.mutt.org/mutt/devel/${P}.tar.gz mirror://gentoo/${P}-gentoo-patches${PATCHSET_REV}.tar.bz2 http://dev.gentoo.org/~grobian/distfiles/${P}-gentoo-patches${PATCHSET_REV}.tar.bz2" -IUSE="berkdb crypt debug doc gdbm gnutls gpg idn imap mbox nls nntp pop qdbm sasl sidebar smime smtp ssl tokyocabinet" +IUSE="berkdb crypt debug doc gdbm gnutls gpg idn imap mbox nls nntp pop qdbm sasl sidebar smime smtp ssl tokyocabinet unicode" SLOT="0" LICENSE="GPL-2" KEYWORDS="alpha amd64 hppa ia64 ~mips ppc ppc64 sparc x86 ~x86-fbsd ~x64-freebsd ~x86-freebsd ~x86-interix ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
yeah, but it doesn't do anything USE=unicode emerge mutt doesn't pull in ncurses[unicode], and even if that dep is set, it isn't enforced by the configure script.
IOW: if your ncurses has unicode, USE=-unicode emerge mutt will still give you a mutt linked to ncursesw.
(In reply to comment #9) > yeah, but it doesn't do anything Oh it does. In the situation I was previously in (unicode changing from - to +, mutt still linked with ncurses), the change to the ebuild causes mutt to be rebuilt and linked to (the newly built) ncursesw. > USE=unicode emerge mutt doesn't pull in ncurses[unicode], and even if that dep > is set, it isn't enforced by the configure script. mutt's configure script searches for ncursesw and uses it if it finds it. Otherwise it falls back to using ncurses. If -unicode, ncursesw shouldn't exist.
(In reply to comment #11) > If -unicode, ncursesw shouldn't exist. only if you put it in your global USE, and keep your system in shape...