config.m4 1.2 KB

12345678910111213141516171819202122232425262728293031323334353637383940
  1. dnl $Id$
  2. dnl config.m4 for extension hash
  3. PHP_ARG_WITH(mhash, for mhash support,
  4. [ --with-mhash[=DIR] Include mhash support])
  5. PHP_ARG_ENABLE(hash, whether to enable hash support,
  6. [ --disable-hash Disable hash support], yes)
  7. if test "$PHP_MHASH" != "no"; then
  8. if test "$PHP_HASH" = "no"; then
  9. PHP_HASH="yes"
  10. fi
  11. AC_DEFINE(PHP_MHASH_BC, 1, [ ])
  12. fi
  13. if test "$PHP_HASH" != "no"; then
  14. AC_DEFINE(HAVE_HASH_EXT,1,[Have HASH Extension])
  15. PHP_C_BIGENDIAN
  16. AC_CHECK_SIZEOF(short, 2)
  17. AC_CHECK_SIZEOF(int, 4)
  18. AC_CHECK_SIZEOF(long, 4)
  19. AC_CHECK_SIZEOF(long long, 8)
  20. EXT_HASH_SOURCES="hash.c hash_md.c hash_sha.c hash_ripemd.c hash_haval.c \
  21. hash_tiger.c hash_gost.c hash_snefru.c hash_whirlpool.c hash_adler32.c \
  22. hash_crc32.c hash_fnv.c hash_joaat.c"
  23. EXT_HASH_HEADERS="php_hash.h php_hash_md.h php_hash_sha.h php_hash_ripemd.h \
  24. php_hash_haval.h php_hash_tiger.h php_hash_gost.h php_hash_snefru.h \
  25. php_hash_whirlpool.h php_hash_adler32.h php_hash_crc32.h \
  26. php_hash_fnv.h php_hash_joaat.h"
  27. PHP_NEW_EXTENSION(hash, $EXT_HASH_SOURCES, $ext_shared)
  28. ifdef([PHP_INSTALL_HEADERS], [
  29. PHP_INSTALL_HEADERS(ext/hash, $EXT_HASH_HEADERS)
  30. ])
  31. fi