This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC 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]

bootstrap/7184: GCC 3.0.x and 3.1 failed to compile on HP-UX 11.11


>Number:         7184
>Category:       bootstrap
>Synopsis:       GCC 3.0.x and 3.1 failed to compile on HP-UX 11.11
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    unassigned
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Tue Jul 02 05:56:03 PDT 2002
>Closed-Date:
>Last-Modified:
>Originator:     Tim Yunaev
>Release:        GCC 3.0.x GCC 3.1
>Organization:
>Environment:
bash-2.05# uname -a
HP-UX hpuxdev B.11.11 U 9000/785 2005081778 unlimited-user license
>Description:
If you download a precompiled GCC 3.1 and try to recompile any of GCC 3.x compilers, it will fail with an error complaining about an unknown type "size_t" in file libiberty/floatformat.c 
This error is caused by a system header stddef.h, which doesn't contain typedef related to size_t.
>How-To-Repeat:
Download the precompiled GCC 3.1 package for HPUX from HP or from http://hpux.cs.utah.edu/hppd/hpux/Gnu/gcc-3.1/
unpack it, type "configure" and "gmake"
>Fix:
I replaced two lines with size_t:
extern void *memcpy (void *s1, const void *s2, size_t n);
extern void *memset (void *s, int c, size_t n);
to 
extern void *memcpy (void *s1, const void *s2, unsigned int n);
extern void *memcpy (void *s1, const void *s2, unsigned int n);

(you must not just define the size_t type, because during the next pass it will use its own stddef.h, which contains a size_t declaration, and you'll get a type redifinition.
>Release-Note:
>Audit-Trail:
>Unformatted:


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