Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: zsh-4.3.4-dev-2.tar.gz
- X-seq: zsh-workers 24109
- From: Vincent Lefevre <vincent@xxxxxxxxxx>
- To: "Zsh Hackers' List" <zsh-workers@xxxxxxxxxx>
- Subject: Re: zsh-4.3.4-dev-2.tar.gz
- Date: Wed, 21 Nov 2007 10:40:37 +0100
- In-reply-to: <20071120154246.30388170@news01>
- Mail-followup-to: "Zsh Hackers' List" <zsh-workers@xxxxxxxxxx>
- Mailing-list: contact zsh-workers-help@xxxxxxxxxx; run by ezmlm
- References: <11649.1195558694@xxxxxxx> <4742DC87.5030901@xxxxxxxxxxxxxxxxxxx> <20071120141442.55f7ac28@news01> <4742F733.4030908@xxxxxxxxxxxxxxxxxxx> <20071120154246.30388170@news01>
On 2007-11-20 15:42:46 +0000, Peter Stephenson wrote:
> +#ifdef ZSH_IGNORE_NCURSES
> +# ifdef HAVE_CURSES_H
> +# include <curses.h>
> +# endif
> +#else
> +# ifdef HAVE_NCURSESW_NCURSES_H
> +# include <ncursesw/ncurses.h>
> +# else
> +# ifdef HAVE_NCURSES_H
> +# include <ncurses.h>
> +# else
> +# ifdef HAVE_NCURSES_NCURSES_H
> +# include <ncurses/ncurses.h>
> +# else
> +# ifdef HAVE_CURSES_H
> +# include <curses.h>
> +# endif
> +# endif
> +# endif
> +# endif
> #endif
Shouldn't HAVE_NCURSES_NCURSES_H and HAVE_NCURSES_H be reversed,
in case both are defined? Indeed I assume that <ncurses/ncurses.h>
should have the precedence over <ncurses.h> since the former is
the canonical place, isn't it?
FYI, on my Mac OS X machine:
prunille:~> locate ncurses.h
/Developer/SDKs/MacOSX10.3.9.sdk/usr/include/ncurses.h
/Developer/SDKs/MacOSX10.4u.sdk/usr/include/ncurses.h
/opt/local/include/ncurses/ncurses.h
/opt/local/include/ncursesw/ncurses.h
/opt/local/var/macports/software/ncurses/5.6_0+darwin_8/opt/local/include/ncurses/ncurses.h
/opt/local/var/macports/software/ncursesw/5.6_0+darwin_8/opt/local/include/ncursesw/ncurses.h
/usr/include/ncurses.h
prunille:~> locate libncurses.dylib
/Applications/Gimp.app/Contents/Resources/lib/libncurses.dylib
/Developer/SDKs/MacOSX10.3.9.sdk/usr/lib/libncurses.dylib
/Developer/SDKs/MacOSX10.4u.sdk/usr/lib/libncurses.dylib
/opt/local/lib/libncurses.dylib
/opt/local/var/macports/software/ncurses/5.6_0+darwin_8/opt/local/lib/libncurses.dylib
/usr/lib/libncurses.dylib
So, if libncursesw isn't installed, zsh will currently be built
using /usr/include/ncurses.h (the old Mac OS X header file) and
/opt/local/lib/libncurses.dylib (the new ncurses library installed
via MacPorts). If the ncurses ABI has changed, this can lead to
a broken zsh binary.
BTW, since
gr -r 'include.*curses' .
on zsh 4.3.4 only gives #include <curses.h> lines, I suppose that my
current zsh 4.3.4 version has been built using /usr/include/curses.h,
but it is linked with /opt/local/lib/libncurses.5.dylib:
prunille:~> otool -L =zsh
/opt/local/bin/zsh:
/opt/local/lib/libiconv.2.dylib (compatibility version 7.0.0, current version 7.0.0)
/usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 88.1.10)
/opt/local/lib/libncurses.5.dylib (compatibility version 5.0.0, current version 5.0.0)
I wonder if this can explain the crashes I get.
--
Vincent Lefèvre <vincent@xxxxxxxxxx> - Web: <http://www.vinc17.org/>
100% accessible validated (X)HTML - Blog: <http://www.vinc17.org/blog/>
Work: CR INRIA - computer arithmetic / Arenaire project (LIP, ENS-Lyon)
Messages sorted by:
Reverse Date,
Date,
Thread,
Author