Bug 99285 - mutt-devel port WITH_NCURSES_PORT doesn't use ncurses port
Summary: mutt-devel port WITH_NCURSES_PORT doesn't use ncurses port
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: Normal Affects Only Me
Assignee: Renato Botelho
Depends on:
Reported: 2006-06-22 01:20 UTC by Timothy Smith
Modified: 2006-06-23 00:27 UTC (History)
0 users

See Also:

file.diff (856 bytes, patch)
2006-06-22 01:20 UTC, Timothy Smith
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Timothy Smith 2006-06-22 01:20:20 UTC
It's useful to compile mutt with the ncurses port, to get proper support for wide characters (UTF-8 in particular).

The mail/mutt port does this correctly; the mail/mutt-devel port does not.

How-To-Repeat: Add this to /etc/make.conf:

.if ${.CURDIR:M*/mail/mutt-devel*}


cd /usr/ports/mail/mutt-devel

Notice the configure output:

checking for waddnwstr in -lncurses... no
checking for waddnwstr in -lncursesw... no

And 'ldd mutt' shows:
        libncurses.so.6 => /lib/libncurses.so.6 (0x28102000)

Finally, to test, run mutt with LC_ALL=en_US.UTF-8 (or similar), and examine the results.  Multi-byte chars won't display correctly, and formatting will be wrong.

After the patch (see "Fix" section):

checking for waddnwstr in -lncurses... no
checking for waddnwstr in -lncursesw... yes


        libncursesw.so => /usr/local/lib/libncursesw.so (0x280f9000)

The final proof is that running mutt displays all characters correctly, with no formating problems.
Comment 1 Edwin Groothuis freebsd_committer 2006-06-22 02:53:06 UTC
State Changed
From-To: open->feedback

Awaiting maintainers feedback
Comment 2 Udo.Schweigert 2006-06-22 06:55:45 UTC
On Thu, Jun 22, 2006 at 01:53:04 +0000, Edwin Groothuis wrote:
> Maintainer of mail/mutt-devel,
> Please note that PR ports/99285 has just been submitted.

Here is my patch (includes some docu about the new knob):

diff -ru  /usr/ports/mail/mutt-devel/Makefile ./Makefile
--- /usr/ports/mail/mutt-devel/Makefile	Tue Mar 21 11:06:35 2006
+++ ./Makefile	Thu Jun 22 07:47:24 2006
@@ -25,6 +25,9 @@
 # environment to get slang function properly.
 # The default version for slang is 1.x. Define WITH_MUTT_SLANG2 if you want
 # to use the slang version 2.x
+# The default version for ncurses is that which comes with the operating
+# system. If you want to use the ncurses supplied by the ports-system define
 # If you want to install the mutt documentation in html and ps format define:
@@ -279,7 +282,12 @@
 .if defined(NOPORTDOCS)
-.if defined(MUTT_USES_NCURSES) && ${OSVERSION} < 400000
+.if defined(MUTT_USES_NCURSES)
+.if ${OSVERSION} < 400000 || defined(WITH_MUTT_NCURSES_PORT)
 LIB_DEPENDS+=	ncurses.5:${PORTSDIR}/devel/ncurses
 CFLAGS+=	-I${LOCALBASE}/include/ncurses -I${LOCALBASE}/include
 .elif defined(MUTT_USES_SLANG1)
@@ -348,7 +356,7 @@
 CONFIGURE_ARGS+=	--enable-locales-fix
-.if defined(MUTT_USES_NCURSES) && ${OSVERSION} < 400000
 CONFIGURE_ARGS+=	--with-curses=${LOCALBASE}
 .elif defined(MUTT_USES_SLANG)

This fixes the PR which then can be closed.

Best regards

Udo Schweigert, Siemens AG   | Voice      : +49 89 636 42170
CT IC CERT, Siemens CERT     | Fax        : +49 89 636 41166
D-81730 Muenchen / Germany   | email      : udo.schweigert@siemens.com
Comment 3 Renato Botelho freebsd_committer 2006-06-22 17:12:56 UTC
Responsible Changed
From-To: freebsd-ports-bugs->garga

I'll take it.
Comment 4 Renato Botelho freebsd_committer 2006-06-23 00:27:03 UTC
State Changed
From-To: feedback->closed

Committed. Thanks!