configure 2.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117
  1. #!/bin/sh
  2. # Copyright (C) Igor Sysoev
  3. # Copyright (C) Nginx, Inc.
  4. LC_ALL=C
  5. export LC_ALL
  6. . auto/options
  7. . auto/init
  8. . auto/sources
  9. test -d $NGX_OBJS || mkdir -p $NGX_OBJS
  10. echo > $NGX_AUTO_HEADERS_H
  11. echo > $NGX_AUTOCONF_ERR
  12. echo "#define NGX_CONFIGURE \"$NGX_CONFIGURE\"" > $NGX_AUTO_CONFIG_H
  13. if [ $NGX_DEBUG = YES ]; then
  14. have=NGX_DEBUG . auto/have
  15. fi
  16. if test -z "$NGX_PLATFORM"; then
  17. echo "checking for OS"
  18. NGX_SYSTEM=`uname -s 2>/dev/null`
  19. NGX_RELEASE=`uname -r 2>/dev/null`
  20. NGX_MACHINE=`uname -m 2>/dev/null`
  21. echo " + $NGX_SYSTEM $NGX_RELEASE $NGX_MACHINE"
  22. NGX_PLATFORM="$NGX_SYSTEM:$NGX_RELEASE:$NGX_MACHINE";
  23. case "$NGX_SYSTEM" in
  24. MINGW32_*)
  25. NGX_PLATFORM=win32
  26. ;;
  27. esac
  28. else
  29. echo "building for $NGX_PLATFORM"
  30. NGX_SYSTEM=$NGX_PLATFORM
  31. fi
  32. . auto/cc/conf
  33. if [ "$NGX_PLATFORM" != win32 ]; then
  34. . auto/headers
  35. fi
  36. . auto/os/conf
  37. if [ "$NGX_PLATFORM" != win32 ]; then
  38. . auto/unix
  39. fi
  40. . auto/threads
  41. . auto/modules
  42. . auto/lib/conf
  43. case ".$NGX_PREFIX" in
  44. .)
  45. NGX_PREFIX=${NGX_PREFIX:-/usr/local/nginx}
  46. have=NGX_PREFIX value="\"$NGX_PREFIX/\"" . auto/define
  47. ;;
  48. .!)
  49. NGX_PREFIX=
  50. ;;
  51. *)
  52. have=NGX_PREFIX value="\"$NGX_PREFIX/\"" . auto/define
  53. ;;
  54. esac
  55. if [ ".$NGX_CONF_PREFIX" != "." ]; then
  56. have=NGX_CONF_PREFIX value="\"$NGX_CONF_PREFIX/\"" . auto/define
  57. fi
  58. have=NGX_SBIN_PATH value="\"$NGX_SBIN_PATH\"" . auto/define
  59. have=NGX_CONF_PATH value="\"$NGX_CONF_PATH\"" . auto/define
  60. have=NGX_PID_PATH value="\"$NGX_PID_PATH\"" . auto/define
  61. have=NGX_LOCK_PATH value="\"$NGX_LOCK_PATH\"" . auto/define
  62. have=NGX_ERROR_LOG_PATH value="\"$NGX_ERROR_LOG_PATH\"" . auto/define
  63. have=NGX_HTTP_LOG_PATH value="\"$NGX_HTTP_LOG_PATH\"" . auto/define
  64. have=NGX_HTTP_CLIENT_TEMP_PATH value="\"$NGX_HTTP_CLIENT_TEMP_PATH\""
  65. . auto/define
  66. have=NGX_HTTP_PROXY_TEMP_PATH value="\"$NGX_HTTP_PROXY_TEMP_PATH\""
  67. . auto/define
  68. have=NGX_HTTP_FASTCGI_TEMP_PATH value="\"$NGX_HTTP_FASTCGI_TEMP_PATH\""
  69. . auto/define
  70. have=NGX_HTTP_UWSGI_TEMP_PATH value="\"$NGX_HTTP_UWSGI_TEMP_PATH\""
  71. . auto/define
  72. have=NGX_HTTP_SCGI_TEMP_PATH value="\"$NGX_HTTP_SCGI_TEMP_PATH\""
  73. . auto/define
  74. . auto/make
  75. . auto/lib/make
  76. . auto/install
  77. # STUB
  78. . auto/stubs
  79. have=NGX_USER value="\"$NGX_USER\"" . auto/define
  80. have=NGX_GROUP value="\"$NGX_GROUP\"" . auto/define
  81. if [ ".$NGX_BUILD" != "." ]; then
  82. have=NGX_BUILD value="\"$NGX_BUILD\"" . auto/define
  83. fi
  84. . auto/summary