egcs-1.1.2 on IRIX6.5 __INTADDR__
Doug Semler
doug@seaspace.com
Fri Apr 30 23:15:00 GMT 1999
> Hi,
>
> using egcs-1.1.2 on SGI/IRIX 6.5.2 using X11-includes I encounter the
> following problem.
>
> in (IRIX)
>
> /usr/include/stddef.h
>
> there is
>
> #if defined(_COMPILER_VERSION) && (_COMPILER_VERSION >= 400)
> #define offsetof(t, memb) ((size_t)__INTADDR__(&(((t *)0)->memb)))
> #else
> #define offsetof(s, m) (size_t)(&(((s *)0)->m))
> #endif
>
> Since EGCS defines _COMPILER_VERSION as 601 on IRIX the definition
> including __INTADDR__ becomes effective but EGCS doesn't know about this
> intrinsic macro.
>
> The macro offsetof is used e.g. in
> /usr/include/X11/Intrinsic.h :
> #define XtOffsetOf(s_type,field) offsetof(s_type,field)
>
>
> What can I do about this?
>
> Many thanks for a hint,
> Helmut.
Your installation is busted, because on our 6.5 box stddef.h is
being pulled in from its own directory, which doesn't have this problem...
(egcs 1.1.2)
Make sure you don't put -I/usr/include on your command line, which can
cause you to bring in the "wrong" header files....
---
Doug Semler | doug@seaspace.com
SeaSpace Corporation | Garbage In -- Gospel Out
Least Senior Software Developer; | Minister of things to do Next Quarter
Low Man on the Totem Pole | (but will Never Be Done) DNRC O-
A closed mind is a terrible thing | Bus Error (passengers dumped)
-----BEGIN GEEK CODE BLOCK-----
Version: 3.12
GCS/M d---(pu) s++:- a-- C++ UILSH+++$ P--- L++ E--- W+
N++ o-- K? w--(++$) O- M-- V- PS+ !PE Y PGP t(+) 5+++ X+
R- tv+(-) b+(++) DI++++ D G e++>++++ h!>--- r% y+>+++++**
------END GEEK CODE BLOCK------
More information about the Gcc-bugs
mailing list