GCC 4.8 RTEMS patch

Ralf Corsepius ralf.corsepius at rtems.org
Wed Apr 17 15:10:15 UTC 2013


On 04/17/2013 01:25 PM, Sebastian Huber wrote:
> Hello,
>
> in the current GCC 4.8 RTEMS patch
>
> http://git.rtems.org/rtems-crossrpms.git/tree/patches/gcc-4.8.0-rtems4.11-20130326.diff
>
>
> there are several
>
> +/* Use the defaults */
> +#undef WCHAR_TYPE
> +
> +#undef WCHAR_TYPE_SIZE
>
> with a change log of
>
> +2009-11-04    Ralf Corsépius <ralf.corsepius at rtems.org>
> +
> +    * config/m32c/rtems.h, config/m68k/rtemself.h,
> +    config/m68k/rtemself.h, config/sh/rtemself.h,
> +    config/sparc/rtemself.h: Undef WCHAR_TYPE_SIZE, WCHAR_TYPE.
> +    (Resets WCHAR_TYPE's to defaults. Prevents broken GCC tm_files
> +    to interfere and cause wchar_t/wint_t incompatibilities).
>
> What is the reason for these patches?

These targets at least at some time in their history overrode WCHAR_TYPE 
and WCHAR_TYPE_SIZE to something which breaks GCC at other places 
(Whether they still do needs to be checked).

These undefs reset these targets to using GCC's internal defaults.

AFAICT, these targets set WCHAR_TYPE, WCHAR_TYPE_SIZE to non-defaults 
just to cater some OS's historic conventions, which are irrelevant to 
RTEMS (hence us to default to "defaults").

Ralf







More information about the devel mailing list