| Summary: | mail-client/mutt-1.5.21-r12: idn include breaks on linux because it has idn/assert.h | ||
|---|---|---|---|
| Product: | Gentoo Linux | Reporter: | Petr Pisar <petr.pisar> |
| Component: | Current packages | Assignee: | Fabian Groffen <grobian> |
| Status: | RESOLVED FIXED | ||
| Severity: | normal | CC: | jer |
| Priority: | Normal | ||
| Version: | unspecified | ||
| Hardware: | All | ||
| OS: | Linux | ||
| URL: | http://dev.mutt.org/trac/ticket/3624 | ||
| Whiteboard: | |||
| Package list: | Runtime testing required: | --- | |
It doesn't clash with libc's assert.h at all. Lots of packages install an assert.h and mutt simply needs to properly distinguish between them. Does -r13 still have this problem? The check somewhat changed. No. -r13 builds without hickups. Upstream has changed the CFLAGS generation not to include /usr/include/idn if not necessary and resolved the issue with these two commits: changeset: 5634:acc8b2afdf29 branch: HEAD user: Michael Elkins <me@sigpipe.org> date: Tue Jan 22 02:02:00 2013 +0000 summary: remove PKG_CHECK_MODULE() check and always use AC_CHECK_HEADERS() changeset: 5633:98e031cd81d4 branch: HEAD user: Michael Elkins <me@sigpipe.org> date: Sun Jan 20 21:45:10 2013 +0000 summary: use pkg-config to look for libidn if available. ok, thanks, closing as fixed then. |
While playing with mutt development tree, I found it's not possible link mutt executable if net-dns/idnkit is installed: /home/petr/mutt-devel/curs_main.c:300: undefined reference to `assert' I minimized the problem to: $ printf '#include <assert.h>\nassert(1);' | cpp -I/usr/include/idn -E - # 1 "<stdin>" # 1 "<built-in>" # 1 "<command-line>" # 1 "<stdin>" # 1 "/usr/include/idn/assert.h" 1 # 51 "/usr/include/idn/assert.h" # 1 "/usr/include/idn/assert.h" 1 # 52 "/usr/include/idn/assert.h" 2 # 2 "<stdin>" 2 assert(1); While removing /usr/include/idn fixes the problem: $ printf '#include <assert.h>\nassert(1);' | cpp -E - # 1 "<stdin>" # 1 "<built-in>" # 1 "<command-line>" # 1 "<stdin>" # 1 "/usr/include/assert.h" 1 3 4 # 37 "/usr/include/assert.h" 3 4 [...] extern void __assert_fail (__const char *__assertion, __const char *__file, unsigned int __line, __const char *__function) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__noreturn__)); [...] # 2 "<stdin>" 2 ((1) ? (void) (0) : __assert_fail ("1", "<stdin>", 2, __PRETTY_FUNCTION__)); The problem is idnkit installs assert.h which is not compatible with glibc assert.h: $ qfile -v /usr/include/idn/assert.h net-dns/idnkit-1.0-r2 (/usr/include/idn/assert.h) Solution is not to install /usr/include/idn/assert.h from net-dns/idnkit.