[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: coreutils-7.1.81-9b653 test results
From: |
Eric Blake |
Subject: |
Re: coreutils-7.1.81-9b653 test results |
Date: |
Fri, 27 Mar 2009 17:06:44 +0000 (UTC) |
User-agent: |
Loom/3.14 (http://gmane.org/) |
Matthew Woehlke <mw_triad <at> users.sourceforge.net> writes:
> >>> ==== sparc/Solaris ====
Which version of Solaris?
> ...okay, trying again after some Makefile hacking:
'make clean' followed by 'make CFLAGS=-g' eliminates the need for Makefile
hacking. Or use ./configure CFLAGS=-g from the get-go.
>
> #0 0xff31a480 in _libc_kill () from /usr/lib/libc.so.1
> #1 0xff2b95c0 in abort () from /usr/lib/libc.so.1
> #2 0x00011984 in compare (a=0x21348 "«»", la=4, b=0x31ed0 "`'", lb=2)
> at test-quotearg.c:182
> #3 0x00011ad4 in compare_strings (func=0x11c9c <use_quotearg_buffer>,
> results=0x31db0) at test-quotearg.c:196
> #4 0x000123c8 in main (argc=1, argv=0xffbef32c) at test-quotearg.c:309
>
> Need more?
That helps. I've made some progress, but still don't fully understand the
failure. The failure happens on the very first attempt to translate a string
containing ` and ', with a message catalog installed that would translate it
to «», and the failure means that the translation did not occur. Somehow the
message catalog is not being consulted properly, and it may be related to the
fact that your gettext installation is old.
I first tried the m4 testsuite (m4 is simpler than coreutils for creating a
tarball that exercises the same gnulib unit test for quotearg). But on a
similarly old Solaris platform that I have access to, I didn't see a failure on
my first attempt:
$ uname -a
SunOS perth 5.8 Generic_108528-15 sun4u sparc SUNW,Sun-Blade-100 Solaris
$ gettext --version | head -n1
gettext (GNU gettext-runtime) 0.14
I finally figured out that the reason is that ENABLE_NLS is defined by default
for coreutils (which uses gettext) but not for m4 (which has not been through
the i18n process yet).
A quick run of:
$ make clean
$ make CFLAGS='-g2 -DENABLE_NLS=1' check
...
test-quotearg.c:182: assertion failed
Abort
...
so I can see a similar failure. However, I'm wondering if there is an automake
bug where specifying TESTS changes the environment passed to the tests, because
I see the failure for a full run but not on an individual run:
$ make -C tests TESTS=test-quotearg CFLAGS='-g2 -DENABLE_NLS=1' check
PASS: test-quotearg
=============
1 test passed
=============
I also noticed this during compilation:
gcc -std=gnu99 -I. -I../lib -I. -I. -I.. -I./.. -I../lib -I./../lib -
I../intl -g2 -DENABLE_NLS=1 -MT test-quotearg.o -MD -MP -MF .deps/test-
quotearg.Tpo -c -o test-quotearg.o test-quotearg.c
In file included from test-quotearg.c:33:
../lib/gettext.h: In function `npgettext_aux':
../lib/gettext.h:158: warning: implicit declaration of function `dcngettext'
../lib/gettext.h:158: warning: initialization makes pointer from integer
without a cast
../lib/gettext.h: In function `dcnpgettext_expr':
../lib/gettext.h:259: warning: assignment makes pointer from integer without a
cast
mv -f .deps/test-quotearg.Tpo .deps/test-quotearg.Po
Maybe this points to evidence that gettext 0.14 may be too old compared to what
gnulib was expecting?
Next, I tried running things in the debugger:
$ cd tests
$ ldd test-quotearg
libm.so.1 => /usr/lib/libm.so.1
libc.so.1 => /usr/lib/libc.so.1
libdl.so.1 => /usr/lib/libdl.so.1
/usr/platform/SUNW,Sun-Blade-100/lib/libc_psr.so.1
$ env LOCALE=fr_FR.UTF-8 LOCALEDIR=locale gdb test-quotearg
...
(gdb) p unibyte_locale
$1 = false
(gdb) n
207 switch (quoting_style)
(gdb)
249 char const *left = gettext_quote (N_("`"), quoting_style);
(gdb) s
gettext_quote (msgid=0x17078 "`", s=locale_quoting_style) at quotearg.c:165
165 char const *translation = _(msgid);
(gdb) s
166 if (translation == msgid && s == clocale_quoting_style)
(gdb) p translation
$2 = 0x17078 "`"
(gdb) bt
#0 gettext_quote (msgid=0x17078 "`", s=locale_quoting_style) at quotearg.c:166
#1 0x00013220 in quotearg_buffer_restyled (
buffer=0x279b8 '¥' <repeats 100 times>, buffersize=100, arg=0x16d38 "",
argsize=0, quoting_style=locale_quoting_style, flags=0,
quote_these_too=0x27e38) at quotearg.c:249
#2 0x00014528 in quotearg_buffer (buffer=0x279b8 '¥' <repeats 100 times>,
buffersize=100, arg=0x16d38 "", argsize=0, o=0x0) at quotearg.c:585
#3 0x000119d8 in use_quotearg_buffer (str=0x16d38 "", len=0xffbeed34)
at test-quotearg.c:225
#4 0x0001174c in compare_strings (func=0x11990 <use_quotearg_buffer>,
results=0x278bc) at test-quotearg.c:195
#5 0x00012094 in main (argc=1, argv=0xffbeee24) at test-quotearg.c:309
(gdb) p gettext
$3 = {<text variable, no debug info>} 0xff2fa49c <gettext>
so the call to gettext didn't return any translation. But I guess that's kind
of expected, since I don't see libintl.so in the list of libraries linked into
the image, and Solaris native gettext is not as full-featured as GNU gettext.
And that's where I'm stuck. Maybe Bruno has some better ideas at what to look
at next, since he maintains GNU gettext, and rewrote that portion of test-
quotearg to force the use of a .mo file with locale-specific quotes?
--
Eric Blake
- coreutils-7.1.81-9b653 test results (was: new snapshot available), (continued)
- coreutils-7.1.81-9b653 test results (was: new snapshot available), Matthew Woehlke, 2009/03/26
- Re: coreutils-7.1.81-9b653 test results, Matthew Woehlke, 2009/03/26
- gnulib build failure on risc/HP-UX (was: coreutils-7.1.81-9b653 test results), Matthew Woehlke, 2009/03/26
- Re: coreutils-7.1.81-9b653 test results, Matthew Woehlke, 2009/03/26
- Re: coreutils-7.1.81-9b653 test results, Matthew Woehlke, 2009/03/26
- Re: coreutils-7.1.81-9b653 test results, Matthew Woehlke, 2009/03/26
- Re: coreutils-7.1.81-9b653 test results, Matthew Woehlke, 2009/03/26
- Re: coreutils-7.1.81-9b653 test results, Eric Blake, 2009/03/26
- Re: coreutils-7.1.81-9b653 test results, Matthew Woehlke, 2009/03/27
- Re: coreutils-7.1.81-9b653 test results, Matthew Woehlke, 2009/03/27
- Re: coreutils-7.1.81-9b653 test results,
Eric Blake <=
- Re: coreutils-7.1.81-9b653 test results, Matthew Woehlke, 2009/03/27
Re: new snapshot available: coreutils-7.1.81-9b653, Elbert_Pol, 2009/03/27