From 1adfc54d0c2b678885eb0a067de7377e3e2b5953 Mon Sep 17 00:00:00 2001 From: Joel Brobecker Date: Mon, 13 Sep 2010 19:10:19 +0000 Subject: [LynxOS] Include sys/ptrace.h instead of ptrace.h. This is one of the changes needed in order to build gdbserver on LynxOS 5.x. Really interesting: On LynxOS 4.x, there is a #warning when sys/ptrace.h is used (explaining that ptrace.h will be used instead), whereas this file was removed from LynxOS 5.x. The contents of sys/ptrace.h on 4.x (or at least the meat of it): #if defined(__GNUC__) || defined(__GNUG__) #if !defined(__NO_INCLUDE_WARN__) #warning Using instead of #endif /* defined(__NO_INCLUDE_WARN__) */ #endif /* defined(__GNUC__) || defined(__GNUG__) */ #include The fix I went for, for now, is to just include unconditionally. I could have done some configury, but we already have to build with -D__NO_INCLUDE_WARN__ to avoid the warnings anyway, and that's unvoidable, due to system includes themselves including the "wrong" header file. Since seems to be the choice that was made for LynxOS, and since it works to include it on LynxOS 4.x, I think that's the simplest solution. gdb/gdbserver/ChangeLog: * lynx-low.c, lynx-ppc-low.c: Include instead of --- gdb/gdbserver/ChangeLog | 5 +++++ gdb/gdbserver/lynx-low.c | 2 +- gdb/gdbserver/lynx-ppc-low.c | 2 +- 3 files changed, 7 insertions(+), 2 deletions(-) (limited to 'gdb') diff --git a/gdb/gdbserver/ChangeLog b/gdb/gdbserver/ChangeLog index b8c8bd7..0a6a71c 100644 --- a/gdb/gdbserver/ChangeLog +++ b/gdb/gdbserver/ChangeLog @@ -1,3 +1,8 @@ +2010-09-13 Joel Brobecker + + * lynx-low.c, lynx-ppc-loc.c: Include instead of + + 2010-09-09 Nathan Sidwell * configure.ac: Add --enable-inprocess-agent option. diff --git a/gdb/gdbserver/lynx-low.c b/gdb/gdbserver/lynx-low.c index 7a949c0..74d2bcd 100644 --- a/gdb/gdbserver/lynx-low.c +++ b/gdb/gdbserver/lynx-low.c @@ -20,7 +20,7 @@ #include "lynx-low.h" #include -#include +#include #include /* Provides PIDGET, TIDGET, BUILDPID, etc. */ #include #include diff --git a/gdb/gdbserver/lynx-ppc-low.c b/gdb/gdbserver/lynx-ppc-low.c index 9caa8ac..97d691a 100644 --- a/gdb/gdbserver/lynx-ppc-low.c +++ b/gdb/gdbserver/lynx-ppc-low.c @@ -21,7 +21,7 @@ #include #include #include -#include +#include /* The following two typedefs are defined in a .h file which is not in the standard include path (/sys/include/family/ppc/ucontext.h), -- cgit v1.1