<<< Date Index >>>     <<< Thread Index >>>

Re: [Mutt] #3341: mutt 1.5.20 - case insensitive limits do not work



#3341: mutt 1.5.20 - case insensitive limits do not work
-----------------------+----------------------------------------------------
 Reporter:  massysett  |       Owner:  mutt-dev
     Type:  defect     |      Status:  new     
 Priority:  critical   |   Milestone:          
Component:  mutt       |     Version:  1.5.20  
 Keywords:             |  
-----------------------+----------------------------------------------------
Changes (by erAck):

  * priority:  major => critical


Comment:

 I experienced the same, case sensitivity not only with limits but also
 with hooks, mutt 1.5.20 compiled using gcc 3.4.3:

 Short story: _XOPEN_SOURCE clashes with C99, if you see -HAVE_WC_FUNCS
 with mutt -v and compiled with C99 it may help to use --with-wc-funcs

 Long story follows:

 {{{
 System: SunOS 5.10 (i86pc)
 ncurses: ncurses 5.6.20061217 (compiled with 5.6)
 libiconv: 1.11
 hcache backend: tokyocabinet 1.4.45
 Compile options:
 +USE_POP  +USE_IMAP  -USE_SMTP
 -USE_SSL_OPENSSL  +USE_SSL_GNUTLS  -USE_SASL  -USE_GSS  +HAVE_GETADDRINFO
 +HAVE_REGCOMP  -USE_GNU_REGEX
 +ENABLE_NLS  -LOCALES_HACK  -HAVE_WC_FUNCS  +HAVE_LANGINFO_CODESET
 +HAVE_LANGINFO_YESEXPR
 +HAVE_ICONV  -ICONV_NONTRANS  -HAVE_LIBIDN  +HAVE_GETSID  +USE_HCACHE
 }}}

 Note that HAVE_WC_FUNCS is not enabled. I boiled this down to having
 CFLAGS="-std=c99" set because Tokyo Cabinet 1.4.45 used with --enable-
 hcache needs that. Removing --enable-hcache did not change anything, but
 when then unsetting -std=c99 everything was fine. The underlying cause is
 that the configure test has
 {{{
 #define _XOPEN_SOURCE 1
 }}}
 that is not allowed with STDC99, extract from
 /usr/include/sys/feature_tests.h:

 {{{
 #if defined(_XOPEN_SOURCE) || defined(_POSIX_C_SOURCE)
 #define __XOPEN_OR_POSIX
 #endif
 /*
  * It is invalid to compile an XPG3, XPG4, XPG4v2, or XPG5 application
  * using c99.  The same is true for POSIX.1-1990, POSIX.2-1992, POSIX.1b,
  * and POSIX.1c applications. Likewise, it is invalid to compile an XPG6
  * or a POSIX.1-2001 application with anything other than a c99 or later
  * compiler.  Therefore, we force an error in both cases.
  */
 #if defined(_STDC_C99) && (defined(__XOPEN_OR_POSIX) && !defined(_XPG6))
 #error "Compiler or options invalid for pre-UNIX 03 X/Open applications \
         and pre-2001 POSIX applications"
 #elif !defined(_STDC_C99) && \
         (defined(__XOPEN_OR_POSIX) && defined(_XPG6))
 #error "Compiler or options invalid; UNIX 03 and POSIX.1-2001 applications
 \
         require the use of c99"
 #endif
 }}}


 Configure --with-wc-funcs helps around and enables HAVE_WC_FUNCS again,
 but configure should be fixed to not set _XOPEN_SOURCE with C99, probably
 not if
 {{{
 #if __STDC_VERSION__ - 0 >= 199901L
 }}}

 However, setting _XOPEN_SOURCE to 1 may be wrong as well. Values indicate
 a specific X/Open CAE Specification or Open Group Technical Standard, i.e.
 Issue 6 with (_XOPEN_SOURCE - 0 == 600).

-- 
Ticket URL: <http://dev.mutt.org/trac/ticket/3341#comment:2>
Mutt <http://www.mutt.org/>
The Mutt mail user agent