Source code of Windows XP (NT5)
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

72 lines
1.5 KiB

  1. /*++
  2. Copyright (c) 1993-1999 Microsoft Corporation
  3. Module Name:
  4. precomp.h
  5. Abstract:
  6. This header file is used to cause the correct machine/platform specific
  7. data structures to be used when compiling for a non-hosted platform.
  8. --*/
  9. #define KDEXTMODE
  10. #include <nt.h>
  11. #include <ntrtl.h>
  12. #include <nturtl.h>
  13. #include <windows.h>
  14. #include <ntosp.h>
  15. #include <stdio.h>
  16. #include <stdlib.h>
  17. #include <string.h>
  18. // This is a 64 bit aware debugger extension
  19. #define KDEXT_64BIT
  20. #include <wdbgexts.h>
  21. #include <dbgeng.h>
  22. #ifdef __cplusplus
  23. extern "C" {
  24. #endif
  25. //
  26. // undef the wdbgexts
  27. //
  28. #undef DECLARE_API
  29. #define DECLARE_API(extension) \
  30. CPPMOD HRESULT CALLBACK extension(PDEBUG_CLIENT Client, PCSTR args)
  31. #define INIT_API() \
  32. HRESULT Status; \
  33. if ((Status = ExtQuery(Client)) != S_OK) return Status;
  34. // Safe release and NULL.
  35. #define EXT_RELEASE(Unk) \
  36. ((Unk) != NULL ? ((Unk)->Release(), (Unk) = NULL) : NULL)
  37. // Global variables initialized by query.
  38. extern PDEBUG_ADVANCED g_ExtAdvanced;
  39. extern PDEBUG_CLIENT g_ExtClient;
  40. extern PDEBUG_CONTROL g_ExtControl;
  41. extern PDEBUG_DATA_SPACES g_ExtData;
  42. extern PDEBUG_REGISTERS g_ExtRegisters;
  43. extern PDEBUG_SYMBOLS g_ExtSymbols;
  44. extern PDEBUG_SYSTEM_OBJECTS g_ExtSystem;
  45. HRESULT
  46. ExtQuery(PDEBUG_CLIENT Client);
  47. void
  48. ExtRelease(void);
  49. #define EXIT_API ExtRelease
  50. extern WINDBG_EXTENSION_APIS ExtensionApis;
  51. #ifdef __cplusplus
  52. }
  53. #endif