This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: PATCH: Provide stdint.h for IRIX 5/6
Bruce,
>> * The fixes in hpux_c99_intptr originally matched the IRIX testcases as
>> well. It turned out that the only difference between the HP-UX and
>> IRIX 6 is whitespace: while HP-UX only uses tabs between definition
>> and value, IRIX 6 uses blanks. I've changed the hpux_c99_intptr fix
>> to be somewhat less generic, although I realize this is fragile. The
>> proper fix for the testsuite (bootstrap should be unaffected since the
>> different mach clauses prevent application of the other fix) would be
>> to support select clauses in check.tpl, too, and add a discriminating
>> string to the HP-UX testcase. Unfortunately, I've no idea how to do
>> this (I don't speak autogen. Bruce?) and don't have access to a HP-UX
>> system to check what regex could be used as a discriminator.
>
> You can specify a bogus file name as the first file that gets the fix.
> e.g. files = hpux11-3-stdint.h, stdint.h;
> The result will be that the test header will be "hpux11-3-stdint.h"
> instead of "stdint.h". As for a discriminator, usually the headers
> have some sort of source control marker in them. Require that marker
> for your fix to fire:
> select = 'some sort of hpux11 stdint.h header marker';
> then add that marker to your "test-text". This technique is used for
> a number of the Solaris headers. These two changes should effectively
> isolate your fix. The AIX, Darwin and newlib fixes should have similar
> discriminators.
Unfortunately, using select with check.tpl doesn't work:
e.g. newlib_stdint_1 has
select = "@todo - Add support for wint_t types";
which doesn't occur in the irix_stdint_c99_{types, mode} test_text, yet
the fix is still applied. That's what I think should be fixed, but it
will probably be much easier for you who breathes autogen than me. If
this were fixed, using e.g. source control markers can be a good
approach, although they break Solaris 11 fixes at the moment:
Sun/OpenSolaris moved from TeamWare/SCCS to Mercurial as their VCS, so
SCCS markers arent' expanded any longer, although the fixes are still
needed ;-( I'll fix this separately, though. It's probably safer to
use a problematic part of the header as discriminator directly.
On HP-UX vs. IRIX, there's only a whitespace (TAB vs. SPC) difference in
the test_text, which I've used for the moment to key off the fixes, but
that seems fragile. Not having access to any HP-UX system or even a
copy of their stdint.h, I cannot fix this properly myself, so I've used
the whitespace difference for now. Maybe Steve (Cc:ed) can speak up and
suggest something more appropriate.
>> I'm including the revised fixincludes part of the patch (which needs
>> approval) below. It now passes make check; a fresh bootstrap on
>> mips-sgi-irix6.5 is in progress.
>>
>> Ok if it passes?
>
> If it passes and if no base results for other fixes need twiddling
> to get it to pass. :) Thanks - Bruce
I only needed to twiddle the base results for fixes that incorrectly
used the newlib_stdint_1 fix instead of their own to properly match
their native fixes instead. Perhaps the platform maintainers can
double-check this? I've Cc:ed David for AIX, but MAINTAINERS only lists
Apple folks for Darwin (which probably won't/mustn't respond anymore)
and no one for newlib.
Rainer
--
-----------------------------------------------------------------------------
Rainer Orth, Center for Biotechnology, Bielefeld University