This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: Patch: gcc/unwind-dw2{-fde,}.c: Warning removal.
- From: "Kaveh R. Ghazi" <ghazi at caip dot rutgers dot edu>
- To: rbrown64 at csc dot com dot au
- Cc: gcc-patches at gcc dot gnu dot org
- Date: Wed, 6 Nov 2002 09:36:52 -0500 (EST)
- Subject: Re: Patch: gcc/unwind-dw2{-fde,}.c: Warning removal.
- References: <OF3590EC33.0ACCF653-ONCA256C69.002FEE1D@int.csc.com.au>
> 2002-11-06 Rodney Brown <rbrown64@csc.com.au>
>
> * unwind-dw2-fde.c: Include string.h.
> * unwind-dw2.c: Include string.h.
>
> --- unwind-dw2-fde.c.orig Sat Jun 1 08:15:39 2002
> +++ unwind-dw2-fde.c Wed Nov 6 17:54:15 2002
> @@ -37,6 +37,9 @@ Software Foundation, 59 Temple Place - S
> #include "unwind-pe.h"
> #include "unwind-dw2-fde.h"
> #include "gthr.h"
> +#ifndef inhibit_libc
> +#include <string.h>
> +#endif
> #endif
I believe this is the wrong approach. Instead try setting
xm_defines=POSIX in the x86 & ppc darwin entries in config.gcc.
(That's how every other port fixes this issue.)
This will trigger an include of string.h in tsystem.h. All target
files (should) include tsystem.h. I checked and unwind-dw2*.c do, so
it should work.
Thanks,
--Kaveh
--
Kaveh R. Ghazi ghazi@caip.rutgers.edu