Leaked source code of windows server 2003
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.

60 lines
1.7 KiB

  1. /* EXTERN.h
  2. *
  3. * Copyright (c) 1991-2001, Larry Wall
  4. *
  5. * You may distribute under the terms of either the GNU General Public
  6. * License or the Artistic License, as specified in the README file.
  7. *
  8. */
  9. /*
  10. * EXT designates a global var which is defined in perl.h
  11. * dEXT designates a global var which is defined in another
  12. * file, so we can't count on finding it in perl.h
  13. * (this practice should be avoided).
  14. */
  15. #undef EXT
  16. #undef dEXT
  17. #undef EXTCONST
  18. #undef dEXTCONST
  19. #if defined(VMS) && !defined(__GNUC__)
  20. /* Suppress portability warnings from DECC for VMS-specific extensions */
  21. # ifdef __DECC
  22. # pragma message disable (GLOBALEXT,NOSHAREEXT,READONLYEXT)
  23. # endif
  24. # define EXT globalref
  25. # define dEXT globaldef {"$GLOBAL_RW_VARS"} noshare
  26. # define EXTCONST globalref
  27. # define dEXTCONST globaldef {"$GLOBAL_RO_VARS"} readonly
  28. #else
  29. # if defined(WIN32) && !defined(PERL_STATIC_SYMS) && !defined(PERL_OBJECT)
  30. # ifdef PERLDLL
  31. # define EXT extern __declspec(dllexport)
  32. # define dEXT
  33. # define EXTCONST extern __declspec(dllexport) const
  34. # define dEXTCONST const
  35. # else
  36. # define EXT extern __declspec(dllimport)
  37. # define dEXT
  38. # define EXTCONST extern __declspec(dllimport) const
  39. # define dEXTCONST const
  40. # endif
  41. # else
  42. # if defined(__CYGWIN__) && defined(USEIMPORTLIB)
  43. # define EXT extern __declspec(dllimport)
  44. # define dEXT
  45. # define EXTCONST extern __declspec(dllimport) const
  46. # define dEXTCONST const
  47. # else
  48. # define EXT extern
  49. # define dEXT
  50. # define EXTCONST extern const
  51. # define dEXTCONST const
  52. # endif
  53. # endif
  54. #endif
  55. #undef INIT
  56. #define INIT(x)
  57. #undef DOINIT