config.m4 1.1 KB

123456789101112131415161718192021222324252627282930313233
  1. dnl config.m4 for extension phar
  2. PHP_ARG_ENABLE(phar, for phar archive support,
  3. [ --disable-phar Disable phar support], yes)
  4. if test "$PHP_PHAR" != "no"; then
  5. PHP_NEW_EXTENSION(phar, util.c tar.c zip.c stream.c func_interceptors.c dirstream.c phar.c phar_object.c phar_path_check.c, $ext_shared,, -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1)
  6. AC_MSG_CHECKING([for phar openssl support])
  7. if test "$PHP_HASH_SHARED" != "yes"; then
  8. if test "$PHP_HASH" != "no"; then
  9. AC_DEFINE(PHAR_HASH_OK,1,[ ])
  10. fi
  11. else
  12. AC_MSG_WARN([Phar: sha256/sha512 signature support disabled if ext/hash is built shared])
  13. fi
  14. if test "$PHP_OPENSSL_SHARED" = "yes"; then
  15. AC_MSG_RESULT([no (shared openssl)])
  16. else
  17. if test "$PHP_OPENSSL" = "yes"; then
  18. AC_MSG_RESULT([yes])
  19. AC_DEFINE(PHAR_HAVE_OPENSSL,1,[ ])
  20. else
  21. AC_MSG_RESULT([no])
  22. fi
  23. fi
  24. PHP_ADD_EXTENSION_DEP(phar, hash, true)
  25. PHP_ADD_EXTENSION_DEP(phar, spl, true)
  26. PHP_ADD_MAKEFILE_FRAGMENT
  27. PHP_INSTALL_HEADERS([ext/phar], [php_phar.h])
  28. PHP_OUTPUT(ext/phar/phar.1 ext/phar/phar.phar.1)
  29. fi