Include header for enum target_stop_reason
authorPedro Alves <palves@redhat.com>
Fri, 15 May 2015 15:00:40 +0000 (16:00 +0100)
committerPedro Alves <palves@redhat.com>
Fri, 15 May 2015 15:00:40 +0000 (16:00 +0100)
Building in C++ mode errors with:

 ~~~
 g++ -fpermissive (...) /home/pedro/gdb/mygit/src/gdb/gdbserver/../nat/x86-linux.c
 In file included from /home/pedro/gdb/mygit/src/gdb/gdbserver/../nat/x86-linux.h:23:0,
  from /home/pedro/gdb/mygit/src/gdb/gdbserver/../nat/x86-linux.c:21:
 /home/pedro/gdb/mygit/src/gdb/gdbserver/../nat/linux-nat.h:74:13: error: use of enum ‘target_stop_reason’ without previous declaration
  extern enum target_stop_reason lwp_stop_reason (struct lwp_info *lwp);
      ^
 /home/pedro/gdb/mygit/src/gdb/gdbserver/../nat/linux-nat.h:74:70: error: invalid type in declaration before ‘;’ token
  extern enum target_stop_reason lwp_stop_reason (struct lwp_info *lwp);
       ^
 ~~~

gdb/ChangeLog:
2015-05-15  Pedro Alves  <palves@redhat.com>

* nat/linux-nat.h: Include "target/waitstatus.h".

gdb/ChangeLog
gdb/nat/linux-nat.h

index 1fdc4f47713aaf5cd27f198f8a40caf11e04edfa..63c015f6365b8f5c6a0a82f4c9e2853e8fc8e39c 100644 (file)
@@ -1,3 +1,7 @@
+2015-05-15  Pedro Alves  <palves@redhat.com>
+
+       * nat/linux-nat.h: Include "target/waitstatus.h".
+
 2015-05-15  Yuanhui Zhang  <asmwarrior@gmail.com>
 
        * python/py-unwind.c (struct reg_info): Move out of ...
index 7cdaf4075cc778f1f2a32c57fc60849bbf931935..0633fa93f98cc9e42e217d392b4a27d61d916bd5 100644 (file)
@@ -20,6 +20,8 @@
 #ifndef LINUX_NAT_H
 #define LINUX_NAT_H
 
+#include "target/waitstatus.h"
+
 struct lwp_info;
 struct arch_lwp_info;