Store objfiles on a std::list
[deliverable/binutils-gdb.git] / gdb / gnu-nat.h
index 9df479c8506a72ff7f6ebefa2b8f9e71d790a833..a22df89fe2de549649efeb2c415ac2aac29f2d9a 100644 (file)
 #ifndef GNU_NAT_H
 #define GNU_NAT_H
 
-#include <unistd.h>
+#include "defs.h"
+
+/* Work around conflict between Mach's 'thread_info' function, and GDB's
+   'thread_info' class.  Make the former available as 'mach_thread_info'.  */
+#define thread_info mach_thread_info
+/* Mach headers are not yet ready for C++ compilation.  */
+extern "C"
+{
 #include <mach.h>
+}
+#undef thread_info
+/* Divert 'mach_thread_info' to the original Mach 'thread_info' function.  */
+extern __typeof__ (mach_thread_info) mach_thread_info asm ("thread_info");
+
+#include <unistd.h>
+
+#include "inf-child.h"
 
 struct inf;
 
@@ -131,7 +146,7 @@ struct gnu_nat_target : public inf_child_target
                        char **, int) override;
   void mourn_inferior () override;
   bool thread_alive (ptid_t ptid) override;
-  const char *pid_to_str (ptid_t) override;
+  std::string pid_to_str (ptid_t) override;
   void stop (ptid_t) override;
 };
 
This page took 0.024024 seconds and 4 git commands to generate.