diff --git a/gdb/ChangeLog b/gdb/ChangeLog index 870ee54a96..25127af90f 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,3 +1,7 @@ +2010-09-01 Joel Brobecker + + * Makefile.in (memmem.o): Build with -Wno-error. + 2010-09-01 Joel Brobecker * utils.c (xsnprintf): Make non-static. diff --git a/gdb/gdbserver/Makefile.in b/gdb/gdbserver/Makefile.in index e397bd7682..ffbb14a88e 100644 --- a/gdb/gdbserver/Makefile.in +++ b/gdb/gdbserver/Makefile.in @@ -94,8 +94,10 @@ WERROR_CFLAGS = @WERROR_CFLAGS@ CFLAGS = @CFLAGS@ # INTERNAL_CFLAGS is the aggregate of all other *CFLAGS macros. -INTERNAL_CFLAGS = $(WARN_CFLAGS) $(WERROR_CFLAGS) ${CFLAGS} ${GLOBAL_CFLAGS} \ +INTERNAL_CFLAGS_BASE = ${CFLAGS} ${GLOBAL_CFLAGS} \ ${PROFILE_CFLAGS} ${INCLUDE_CFLAGS} +INTERNAL_WARN_CFLAGS = ${INTERNAL_CFLAGS_BASE} $(WARN_CFLAGS) +INTERNAL_CFLAGS = ${INTERNAL_WARN_CFLAGS} $(WERROR_CFLAGS) # LDFLAGS is specifically reserved for setting from the command line # when running make. @@ -347,8 +349,13 @@ gdbreplay.o: gdbreplay.c config.h signals.o: ../common/signals.c $(server_h) $(signals_def) $(CC) -c $(CPPFLAGS) $(INTERNAL_CFLAGS) $< -DGDBSERVER +# We build memmem.c without -Werror because this file is not under +# our control. On LynxOS, the compiler generates some warnings +# because str-two-way.h uses a constant (MAX_SIZE) whose definition +# makes it ambiguous whether it is signed or unsigned ("warning: this +# decimal constant is unsigned only in ISO C90"). memmem.o: ../gnulib/memmem.c - $(CC) -o memmem.o -c $(CPPFLAGS) $(INTERNAL_CFLAGS) $< + $(CC) -o memmem.o -c $(CPPFLAGS) $(INTERNAL_WARN_CFLAGS) $< i386_low_h = $(srcdir)/i386-low.h