This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [patch, testsuite] check for UTF-32 target wide charset support in gdb.base/wchar.exp


Sandra Loosemore <sandra@codesourcery.com> writes:
> On 09/16/2015 11:07 PM, Eli Zaretskii wrote:
>>> Date: Wed, 16 Sep 2015 21:24:13 -0600
>>> From: Sandra Loosemore <sandra@codesourcery.com>
>>>
>>> If GDB is configured without ICONV support, the target wide charset
>>> defaults to "ISO-8859-1" (which isn't even a wide charset), and all the
>>> wide strings in this test print as gibberish.  Otherwise, GDB seems to
>>> think the default is "auto; currently UTF-32", so let's make the
>>> dependency on UTF-32 explicit here and bail out if it's not available.
>>
>> Why UTF-32, hard-coded?  Why not allow also UTF-16, for example?
>
> It looked to me like the default target wide charset is UTF-32 if you
> don't pick one explicitly.  Since the test as currently written
> doesn't, the patterns the .exp file is trying to match must assume the
> default target wide charset, and not some other wide charset that
> might happen to be supported.
>
> If I'm confused and the default charset might not always be UTF-32 if
> ICONV is present, how about changing the testcase to bail if it sees
> the default wide charset is ISO-8859-1?  That means either ICONV is
> not present or GDB's default is otherwise wrongly configured.

The question I have is what's the intent behind PHONY_ICONV?
[The fact that it apparently tries to provide some minimal wide char
support but defines GDB_DEFAULT_TARGET_WIDE_CHARSET as "ISO-8859-1"
seems like a bug to me.]

Is it intended that it provide some minimal wide char support?
And if so, my preference would be to keep the test if it's easy.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]