bits/wordsize.h

Ralf Corsepius ralf.corsepius at rtems.org
Thu Apr 14 15:20:08 UTC 2011


On 04/14/2011 04:37 PM, Sebastien Bourdeauducq wrote:
> Hi,
>
> RTEMS lacks the header file<bits/wordsize.h>

bits/wordsize.h is not a standardized header. Likely it's Linux specific.

>  which poses a problem e.g.
> with applications that include ftconfig.h from Freetype.
Well, then tell upstream that their sources are non-portable.

> I propose that such a header be added to RTEMS, which would contain only
> this line (it is done the same on Linux/x86):
>
> #define __WORDSIZE 32

Whether this would be correct would depend upon the definition of "WORD" 
being used here.

Probably, they are referring to sizeof(int) in bits, which would be what 
POSIX calls "WORD_BIT" - However, we don't have this, neither.

However, in practice there are many other ways to avoid such defines 
rsp. to work around such defines, e.g. using posix types from stdint.h.

Ralf




More information about the users mailing list