This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug rtl-optimization/52785] Compile with -O fails in gcc 4.7
- From: "sergio at serjux dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Fri, 30 Mar 2012 02:39:25 +0000
- Subject: [Bug rtl-optimization/52785] Compile with -O fails in gcc 4.7
- Auto-submitted: auto-generated
- References: <bug-52785-4@http.gcc.gnu.org/bugzilla/>
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52785
--- Comment #5 from SÃrgio Basto <sergio at serjux dot com> 2012-03-30 02:39:25 UTC ---
(In reply to comment #4)
> strndup is a macro in glibc header files. Use (strndup) to disable the macro
> function.
>
> This is not a GCC bug or a glibc bug (since you supply _GNU_SOURCE which says
> define this macro) as the header is using something in the GNU_SOURCE
> namespace.
Sorry , could you help me try solve this
the code is :
#ifndef HAVE_STRNDUP
extern _X_EXPORT char * strndup(const char *str, size_t n);
#endif
so -DHAVE_STRNDUP make source compile , what or how I fix the source ?