config.w32 2.5 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758
  1. // vim:ft=javascript
  2. // $Id$
  3. ARG_ENABLE('apache2handler', 'Build Apache 2.x handler', 'no');
  4. if (PHP_APACHE2HANDLER != "no") {
  5. if (PHP_ZTS == "no") {
  6. WARNING("Apache 2.0 module requires an --enable-zts build of PHP on windows");
  7. } else if (CHECK_HEADER_ADD_INCLUDE("httpd.h", "CFLAGS_APACHE2HANDLER", PHP_PHP_BUILD + "\\include\\apache2") &&
  8. CHECK_LIB("libhttpd.lib", "apache2handler", PHP_PHP_BUILD + "\\lib\\apache2") &&
  9. CHECK_LIB("libapr.lib", "apache2handler", PHP_PHP_BUILD + "\\lib\\apache2") &&
  10. CHECK_LIB("libaprutil.lib", "apache2handler", PHP_PHP_BUILD + "\\lib\\apache2")
  11. ) {
  12. SAPI('apache2handler', 'mod_php5.c sapi_apache2.c apache_config.c php_functions.c',
  13. 'php' + PHP_VERSION + 'apache2.dll',
  14. '/D PHP_APACHE2_EXPORTS /I win32');
  15. } else {
  16. WARNING("Could not find apache2 libraries/headers");
  17. }
  18. }
  19. ARG_ENABLE('apache2-2handler', 'Build Apache 2.2.x handler', 'no');
  20. if (PHP_APACHE2_2HANDLER != "no") {
  21. if (PHP_ZTS == "no") {
  22. WARNING("Apache 2.2 module requires an --enable-zts build of PHP on windows");
  23. } else if (CHECK_HEADER_ADD_INCLUDE("httpd.h", "CFLAGS_APACHE2_2HANDLER", PHP_PHP_BUILD + "\\include\\apache2_2") &&
  24. CHECK_LIB("libhttpd.lib", "apache2_2handler", PHP_PHP_BUILD + "\\lib\\apache2_2") &&
  25. CHECK_LIB("libapr-1.lib", "apache2_2handler", PHP_PHP_BUILD + "\\lib\\apache2_2") &&
  26. CHECK_LIB("libaprutil-1.lib", "apache2_2handler", PHP_PHP_BUILD + "\\lib\\apache2_2")
  27. ) {
  28. SAPI('apache2_2handler', 'mod_php5.c sapi_apache2.c apache_config.c php_functions.c',
  29. 'php' + PHP_VERSION + 'apache2_2.dll',
  30. '/D PHP_APACHE2_EXPORTS /I win32',
  31. 'sapi\\apache2_2handler');
  32. } else {
  33. WARNING("Could not find apache2.2 libraries/headers");
  34. }
  35. }
  36. ARG_ENABLE('apache2-4handler', 'Build Apache 2.4.x handler', 'no');
  37. if (PHP_APACHE2_4HANDLER != "no") {
  38. if (PHP_ZTS == "no") {
  39. WARNING("Apache 2.4 module requires an --enable-zts build of PHP on windows");
  40. } else if (CHECK_HEADER_ADD_INCLUDE("httpd.h", "CFLAGS_APACHE2_4HANDLER", PHP_PHP_BUILD + "\\include\\apache2_4") &&
  41. CHECK_LIB("libhttpd.lib", "apache2_4handler", PHP_PHP_BUILD + "\\lib\\apache2_4") &&
  42. CHECK_LIB("libapr-1.lib", "apache2_4handler", PHP_PHP_BUILD + "\\lib\\apache2_4") &&
  43. CHECK_LIB("libaprutil-1.lib", "apache2_4handler", PHP_PHP_BUILD + "\\lib\\apache2_4")
  44. ) {
  45. SAPI('apache2_4handler', 'mod_php5.c sapi_apache2.c apache_config.c php_functions.c',
  46. 'php' + PHP_VERSION + 'apache2_4.dll',
  47. '/D PHP_APACHE2_EXPORTS /I win32',
  48. 'sapi\\apache2handler');
  49. } else {
  50. WARNING("Could not find apache 2.4 libraries/headers");
  51. }
  52. }