[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Compiling RTEMS 4.9.5 on Cygwin, needed to remove -Werror



On 03/03/2011 10:03 PM, Antoine Lacroix wrote:
> Hi to all,
>
> Just to report something I've seen: while compiling gdb for RTEMS 4.9.5
> on Cygwin (latest version 1.7.x) I had this error (it was for arm target
> but I had the same problem for other targets):
>
> gcc -c -g -O2 -I. -I../../gdb-6.8/gdb -I../../gdb-6.8/gdb/config
> -DLOCALEDIR="\"/cygdrive/p/Antoine/tools/armtools/share/locale\""
> -DHAVE_CONFIG_H -I../../gdb-6.8/gdb/../include/opcode
> -I../../gdb-6.8/gdb/../readline/.. -I../bfd -I../../gdb-6.8/gdb/../bfd
> -I../../gdb-6.8/gdb/../include -I../libdecnumber
> -I../../gdb-6.8/gdb/../libdecnumber -DMI_OUT=1 -DTUI=1 -Wall
> -Wdeclaration-after-statement -Wpointer-arith -Wformat-nonliteral
> -Wno-pointer-sign -Wno-unused -Wno-switch -Wno-char-subscripts -Werror
> ../../gdb-6.8/gdb/remote-fileio.c
> cc1: warnings being treated as errors
> ../../gdb-6.8/gdb/remote-fileio.c: In function 'remote_fileio_func_rename':
> ../../gdb-6.8/gdb/remote-fileio.c:1007: error:
> 'cygwin_conv_to_full_posix_path' is deprecated (declared at
> /usr/include/sys/cygwin.h:40)
> ../../gdb-6.8/gdb/remote-fileio.c:1008: error:
> 'cygwin_conv_to_full_posix_path' is deprecated (declared at
> /usr/include/sys/cygwin.h:40)
> make[2]: *** [remote-fileio.o] Error 1
>
> I confirm that the cygwin.h line above announces in its comments that
> this is a deprecated primitive.
> Just removing -Werror option in the Makefile (in gdb directory) solves
> the problem and the compilation goes till the end.

Any reason why you don't use the prebuilt rpms?

Anyway, the appropriate workaround to this kind of issues is to append 
--disable-werror to configure.

gdb is hardly compilable on any platform without it.

Ralf