gdb-apple-1518-darwin8-9.patch 2.2 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788
  1. --- src/gdb/macosx/macosx-nat-dyld.c
  2. +++ src/gdb/macosx/macosx-nat-dyld.c
  3. @@ -2083,7 +2083,9 @@
  4. case MH_DYLIB:
  5. case MH_DYLINKER:
  6. case MH_BUNDLE:
  7. +#ifdef MH_KEXT_BUNDLE
  8. case MH_KEXT_BUNDLE:
  9. +#endif
  10. break;
  11. case MH_FVMLIB:
  12. case MH_PRELOAD:
  13. @@ -2412,7 +2414,9 @@
  14. break;
  15. case MH_DYLINKER:
  16. case MH_BUNDLE:
  17. +#ifdef MH_KEXT_BUNDLE
  18. case MH_KEXT_BUNDLE:
  19. +#endif
  20. entry->reason = dyld_reason_dyld;
  21. break;
  22. default:
  23. --- src/gdb/macosx/macosx-nat-dyld-process.c
  24. +++ src/gdb/macosx/macosx-nat-dyld-process.c
  25. @@ -407,7 +407,9 @@
  26. case MH_DYLIB:
  27. break;
  28. case MH_BUNDLE:
  29. +#ifdef MH_KEXT_BUNDLE
  30. case MH_KEXT_BUNDLE:
  31. +#endif
  32. break;
  33. default:
  34. return;
  35. return;
  36. --- src/gdb/macosx/macosx-nat-inferior.c
  37. +++ src/gdb/macosx/macosx-nat-inferior.c
  38. @@ -2692,6 +2692,7 @@
  39. if (tp->private == NULL || tp->private->app_thread_port == 0)
  40. return NULL;
  41. +#ifdef THREAD_IDENTIFIER_INFO_COUNT
  42. thread_identifier_info_data_t tident;
  43. unsigned int info_count;
  44. kern_return_t kret;
  45. @@ -2719,6 +2720,7 @@
  46. }
  47. }
  48. }
  49. +#endif
  50. return buf;
  51. }
  52. --- src/gdb/macosx/macosx-nat-infthread.c
  53. +++ src/gdb/macosx/macosx-nat-infthread.c
  54. @@ -809,6 +809,7 @@
  55. print_stack_frame (get_selected_frame (NULL), 0, LOCATION);
  56. switch_to_thread (current_ptid);
  57. +#ifdef THREAD_IDENTIFIER_INFO_COUNT
  58. thread_identifier_info_data_t tident;
  59. info_count = THREAD_IDENTIFIER_INFO_COUNT;
  60. kret = thread_info (tid, THREAD_IDENTIFIER_INFO, (thread_info_t) &tident,
  61. @@ -878,6 +879,7 @@
  62. printf_filtered ("\tcurrent priority: %d\n", pth.pth_priority);
  63. printf_filtered ("\tmax priority: %d\n", pth.pth_maxpriority);
  64. }
  65. +#endif
  66. printf_filtered ("\tsuspend count: %d", info.suspend_count);
  67. @@ -1175,6 +1177,7 @@
  68. ui_out_field_fmt (uiout, "mach-port-number", "0x%s",
  69. paddr_nz (app_thread_name));
  70. +#ifdef THREAD_IDENTIFIER_INFO_COUNT
  71. thread_identifier_info_data_t tident;
  72. info_count = THREAD_IDENTIFIER_INFO_COUNT;
  73. kret = thread_info (tid, THREAD_IDENTIFIER_INFO, (thread_info_t) &tident,
  74. @@ -1207,6 +1210,7 @@
  75. paddr_nz (struct_addr));
  76. }
  77. }
  78. +#endif
  79. }