php_posix.h 1.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354
  1. /*
  2. +----------------------------------------------------------------------+
  3. | Copyright (c) The PHP Group |
  4. +----------------------------------------------------------------------+
  5. | This source file is subject to version 3.01 of the PHP license, |
  6. | that is bundled with this package in the file LICENSE, and is |
  7. | available through the world-wide-web at the following url: |
  8. | https://www.php.net/license/3_01.txt |
  9. | If you did not receive a copy of the PHP license and are unable to |
  10. | obtain it through the world-wide-web, please send a note to |
  11. | license@php.net so we can mail you a copy immediately. |
  12. +----------------------------------------------------------------------+
  13. | Author: Kristian Koehntopp <kris@koehntopp.de> |
  14. +----------------------------------------------------------------------+
  15. */
  16. #ifndef PHP_POSIX_H
  17. #define PHP_POSIX_H
  18. #ifdef HAVE_CONFIG_H
  19. #include "config.h"
  20. #endif
  21. #ifdef HAVE_POSIX
  22. #ifndef DLEXPORT
  23. #define DLEXPORT
  24. #endif
  25. extern zend_module_entry posix_module_entry;
  26. #define posix_module_ptr &posix_module_entry
  27. #include "php_version.h"
  28. #define PHP_POSIX_VERSION PHP_VERSION
  29. ZEND_BEGIN_MODULE_GLOBALS(posix)
  30. int last_error;
  31. ZEND_END_MODULE_GLOBALS(posix)
  32. #if defined(ZTS) && defined(COMPILE_DL_POSIX)
  33. ZEND_TSRMLS_CACHE_EXTERN()
  34. #endif
  35. ZEND_EXTERN_MODULE_GLOBALS(posix)
  36. #define POSIX_G(v) ZEND_MODULE_GLOBALS_ACCESSOR(posix, v)
  37. #else
  38. #define posix_module_ptr NULL
  39. #endif
  40. #define phpext_posix_ptr posix_module_ptr
  41. #endif /* PHP_POSIX_H */