Clarify GDBSERVER use in linux-waitpid.c
authorGary Benson <gbenson@redhat.com>
Fri, 12 Sep 2014 09:57:46 +0000 (10:57 +0100)
committerGary Benson <gbenson@redhat.com>
Fri, 12 Sep 2014 10:03:49 +0000 (11:03 +0100)
This commit makes linux-waitpid.c include common-defs.h.  GDB's
inclusion of defs.h is removed, but gdbserver's inclusion of
server.h remains to support some gdbserver-specific debug code
that cannot presently be merged.  A new FIXME documents this.

gdb/ChangeLog:

* nat/linux-waitpid.c: Include common-defs.h.
[GDBSERVER]: Add FIXME comment.
[!GDBSERVER]: Don't include defs.h or signal.h.
(linux_debug) [!GDBSERVER]: Remove empty block.

gdb/ChangeLog
gdb/nat/linux-waitpid.c

index e2f33351aa93d681a919d0ad24bb87780365fc80..56f676dc118f6e2ab67573b39fec1464ab74088a 100644 (file)
@@ -1,3 +1,10 @@
+2014-09-12  Gary Benson  <gbenson@redhat.com>
+
+       * nat/linux-waitpid.c: Include common-defs.h.
+       [GDBSERVER]: Add FIXME comment.
+       [!GDBSERVER]: Don't include defs.h or signal.h.
+       (linux_debug) [!GDBSERVER]: Remove empty block.
+
 2014-09-12  Gary Benson  <gbenson@redhat.com>
 
        * nat/x86-dregs.c: Include common-defs.h and break-common.h.
index 53847ac0518540a148a4fecaec97c41d841891dc..04cdc3d5cef56ee02f1572a46002f948e20af2c3 100644 (file)
    You should have received a copy of the GNU General Public License
    along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
 
+#include "common-defs.h"
+
 #ifdef GDBSERVER
+/* FIXME: server.h is required for the definition of debug_threads
+   which is used in the gdbserver-specific debug printing in
+   linux_debug.  This code should be made available to GDB also,
+   but the lack of a suitable flag to enable it prevents this.  */
 #include "server.h"
-#else
-#include "defs.h"
-#include "signal.h"
 #endif
 
 #include "linux-nat.h"
@@ -42,8 +45,6 @@ linux_debug (const char *format, ...)
       vfprintf (stderr, format, args);
       va_end (args);
     }
-#else
-  /* GDB-specific debugging output.  */
 #endif
 }
 
This page took 0.030331 seconds and 4 git commands to generate.