You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

85 lines
1.9 KiB

19 years ago
  1. #! /bin/sh
  2. SED="@SED@"
  3. prefix="@prefix@"
  4. exec_prefix="@exec_prefix@"
  5. version="@PHP_VERSION@"
  6. vernum="@PHP_VERSION_ID@"
  7. include_dir="@includedir@/php"
  8. includes="-I$include_dir -I$include_dir/main -I$include_dir/TSRM -I$include_dir/Zend -I$include_dir/ext -I$include_dir/ext/date/lib"
  9. ldflags="@PHP_LDFLAGS@"
  10. libs="@EXTRA_LIBS@"
  11. extension_dir='@EXTENSION_DIR@'
  12. program_prefix="@program_prefix@"
  13. program_suffix="@program_suffix@"
  14. exe_extension="@EXEEXT@"
  15. php_cli_binary=NONE
  16. php_cgi_binary=NONE
  17. configure_options="@CONFIGURE_OPTIONS@"
  18. php_sapis="@PHP_INSTALLED_SAPIS@"
  19. # Set php_cli_binary and php_cgi_binary if available
  20. for sapi in $php_sapis; do
  21. case $sapi in
  22. cli)
  23. php_cli_binary="@bindir@/${program_prefix}php${program_suffix}${exe_extension}"
  24. ;;
  25. cgi)
  26. php_cgi_binary="@bindir@/${program_prefix}php-cgi${program_suffix}${exe_extension}"
  27. ;;
  28. esac
  29. done
  30. # Determine which (if any) php binary is available
  31. if test "$php_cli_binary" != "NONE"; then
  32. php_binary="$php_cli_binary"
  33. else
  34. php_binary="$php_cgi_binary"
  35. fi
  36. # Remove quotes
  37. configure_options=`echo $configure_options | $SED -e "s#'##g"`
  38. case "$1" in
  39. --prefix)
  40. echo $prefix;;
  41. --includes)
  42. echo $includes;;
  43. --ldflags)
  44. echo $ldflags;;
  45. --libs)
  46. echo $libs;;
  47. --extension-dir)
  48. echo $extension_dir;;
  49. --include-dir)
  50. echo $include_dir;;
  51. --php-binary)
  52. echo $php_binary;;
  53. --php-sapis)
  54. echo $php_sapis;;
  55. --configure-options)
  56. echo $configure_options;;
  57. --version)
  58. echo $version;;
  59. --vernum)
  60. echo $vernum;;
  61. *)
  62. cat << EOF
  63. Usage: $0 [OPTION]
  64. Options:
  65. --prefix [$prefix]
  66. --includes [$includes]
  67. --ldflags [$ldflags]
  68. --libs [$libs]
  69. --extension-dir [$extension_dir]
  70. --include-dir [$include_dir]
  71. --php-binary [$php_binary]
  72. --php-sapis [$php_sapis]
  73. --configure-options [$configure_options]
  74. --version [$version]
  75. --vernum [$vernum]
  76. EOF
  77. exit 1;;
  78. esac
  79. exit 0