config.m4 1006 B

123456789101112131415161718192021222324252627282930
  1. dnl config.m4 for sapi embed
  2. PHP_ARG_ENABLE(embed,,
  3. [ --enable-embed[=TYPE] EXPERIMENTAL: Enable building of embedded SAPI library
  4. TYPE is either 'shared' or 'static'. [TYPE=shared]], no, no)
  5. AC_MSG_CHECKING([for embedded SAPI library support])
  6. if test "$PHP_EMBED" != "no"; then
  7. case "$PHP_EMBED" in
  8. yes|shared)
  9. PHP_EMBED_TYPE=shared
  10. INSTALL_IT="\$(mkinstalldirs) \$(INSTALL_ROOT)\$(prefix)/lib; \$(INSTALL) -m 0755 $SAPI_SHARED \$(INSTALL_ROOT)\$(prefix)/lib"
  11. ;;
  12. static)
  13. PHP_EMBED_TYPE=static
  14. INSTALL_IT="\$(mkinstalldirs) \$(INSTALL_ROOT)\$(prefix)/lib; \$(INSTALL) -m 0644 $SAPI_STATIC \$(INSTALL_ROOT)\$(prefix)/lib"
  15. ;;
  16. *)
  17. PHP_EMBED_TYPE=no
  18. ;;
  19. esac
  20. if test "$PHP_EMBED_TYPE" != "no"; then
  21. PHP_SELECT_SAPI(embed, $PHP_EMBED_TYPE, php_embed.c, -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1)
  22. PHP_INSTALL_HEADERS([sapi/embed/php_embed.h])
  23. fi
  24. AC_MSG_RESULT([$PHP_EMBED_TYPE])
  25. else
  26. AC_MSG_RESULT(no)
  27. fi