xmlexports.h 1.3 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980
  1. /*
  2. * Summary: macros for marking symbols as exportable/importable.
  3. * Description: macros for marking symbols as exportable/importable.
  4. *
  5. * Copy: See Copyright for the status of this software.
  6. */
  7. #ifndef __XML_EXPORTS_H__
  8. #define __XML_EXPORTS_H__
  9. #if defined(_WIN32) || defined(__CYGWIN__)
  10. /** DOC_DISABLE */
  11. #include <windef.h>
  12. #ifdef LIBXML_STATIC
  13. #define XMLPUBLIC
  14. #elif defined(IN_LIBXML)
  15. #define XMLPUBLIC __declspec(dllexport)
  16. #else
  17. #define XMLPUBLIC __declspec(dllimport)
  18. #endif
  19. #if defined(LIBXML_FASTCALL)
  20. #define XMLCALL __fastcall
  21. #else
  22. #define XMLCALL __cdecl
  23. #endif
  24. #define XMLCDECL __cdecl
  25. /** DOC_ENABLE */
  26. #else /* not Windows */
  27. /**
  28. * XMLPUBLIC:
  29. *
  30. * Macro which declares a public symbol
  31. */
  32. #define XMLPUBLIC
  33. /**
  34. * XMLCALL:
  35. *
  36. * Macro which declares the calling convention for exported functions
  37. */
  38. #define XMLCALL
  39. /**
  40. * XMLCDECL:
  41. *
  42. * Macro which declares the calling convention for exported functions that
  43. * use '...'.
  44. */
  45. #define XMLCDECL
  46. #endif /* platform switch */
  47. /*
  48. * XMLPUBFUN:
  49. *
  50. * Macro which declares an exportable function
  51. */
  52. #define XMLPUBFUN XMLPUBLIC
  53. /**
  54. * XMLPUBVAR:
  55. *
  56. * Macro which declares an exportable variable
  57. */
  58. #define XMLPUBVAR XMLPUBLIC extern
  59. /* Compatibility */
  60. #if !defined(LIBXML_DLL_IMPORT)
  61. #define LIBXML_DLL_IMPORT XMLPUBVAR
  62. #endif
  63. #endif /* __XML_EXPORTS_H__ */