Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: 4.3.4-dev-4 and 4.2.6-dev-2 available



Pea wrote:
> > Thanks for investigating.  OK, so that has to come out for openbsd.
> > I hope the following patch does the trick:  it's a bit complicated in
> > order to ensure we get the definition before any system header files.
> 
> Thank you for your patch. It works like a charm !
> But if you don't to complicate your code, i can do a patch only for
> OpenBSD (just to remove the line #define _XOPEN_SOURCE_EXTENDED 1) (i
> am the maintainer of zsh port). Just tell me..

I'm perfectly happy to have it in the main shell; by our standards this
isn't even particularly complicated.

> I test on my two machines (@i386 and @amd64): compilation OK. But now,
> one regression test fail:
> 
> ./A03quoting.ztst: starting.
> Test ./A03quoting.ztst failed: bad status 1, expected 0 from:
>   print '<\u0041>'
>   printf '%s\n' $'<\u0042>'
>   print '<\u0043>'
>   printf '%s\n' $'<\u0044>'
> Error output:
> (eval):1: cannot do charset conversion
> Was testing: \u in both print and printf
> ./A03quoting.ztst: test failed.

Urk...  that means it hasn't found a suitable library for character set
conversion.  This isn't necessarily wrong if you actually don't have
those facilities.  The two main possibilities are

- environment supports ISO 10646 (plus wchar_t plus wctomb()).
- iconv is present (plus NLS).

See the code around line 4851 of Src/utils.c; you should be able to work
out which preprocessor tests are failing.

It's possible HAVE_WCHAR_H isn't defined if you don't have <wchar.h>
(I'm suggesting this because of the previous difficulties over finding
wchar_t).  It's possible then that wctomb() is actually somewhere else
and we don't need wchar.h at all.  Otherwise, we may have to make do
with what we've got, which compiles and is basically functioning.

-- 
Peter Stephenson <pws@xxxxxxx>                  Software Engineer
CSR PLC, Churchill House, Cambridge Business Park, Cowley Road
Cambridge, CB4 0WZ, UK                          Tel: +44 (0)1223 692070



Messages sorted by: Reverse Date, Date, Thread, Author