--sysconfdir=DIR
diff --git a/auto/configure b/auto/configure
index bcb8aaa..00a7f48 100755
--- a/auto/configure
+++ b/auto/configure
@@ -67,6 +67,7 @@
 
 have=NGX_PREFIX value="\"$NGX_PREFIX/\"" . auto/define
 have=NGX_SBIN_PATH value="\"$NGX_SBIN_PATH\"" . auto/define
+have=NGX_CONF_PREFIX value="\"$NGX_CONF_PREFIX/\"" . auto/define
 have=NGX_CONF_PATH value="\"$NGX_CONF_PATH\"" . auto/define
 have=NGX_PID_PATH value="\"$NGX_PID_PATH\"" . auto/define
 have=NGX_LOCK_PATH value="\"$NGX_LOCK_PATH\"" . auto/define
diff --git a/auto/install b/auto/install
index 3496c5b..e949aec 100644
--- a/auto/install
+++ b/auto/install
@@ -26,19 +26,22 @@
 	test ! -f '$NGX_SBIN_PATH' || mv '$NGX_SBIN_PATH' '$NGX_SBIN_PATH.old'
 	cp $NGX_OBJS/nginx '$NGX_SBIN_PATH'
 
-	test -d '`dirname "$NGX_CONF_PATH"`' \
-		|| mkdir -p '`dirname "$NGX_CONF_PATH"`'
+	test -d '$NGX_CONF_PREFIX' || mkdir -p '$NGX_CONF_PREFIX'
 
-	cp conf/koi-win '`dirname "$NGX_CONF_PATH"`'
-	cp conf/koi-utf '`dirname "$NGX_CONF_PATH"`'
-	cp conf/win-utf '`dirname "$NGX_CONF_PATH"`'
+	cp conf/koi-win '$NGX_CONF_PREFIX'
+	cp conf/koi-utf '$NGX_CONF_PREFIX'
+	cp conf/win-utf '$NGX_CONF_PREFIX'
 
-	test -f '`dirname "$NGX_CONF_PATH"`/mime.types' || \
-		cp conf/mime.types '`dirname "$NGX_CONF_PATH"`/mime.types'
-	cp conf/mime.types '`dirname "$NGX_CONF_PATH"`/mime.types.default'
+	test -f '$NGX_CONF_PREFIX/mime.types' \
+		|| cp conf/mime.types '$NGX_CONF_PREFIX'
+	cp conf/mime.types '$NGX_CONF_PATH/mime.types.default'
 
-	test -f '$NGX_CONF_PATH' || cp conf/nginx.conf '$NGX_CONF_PATH'
-	cp conf/nginx.conf '`dirname "$NGX_CONF_PATH"`/nginx.conf.default'
+	test -f '$NGX_CONF_PREFIX/fastcgi_params' \
+		|| cp conf/fastcgi_params '$NGX_CONF_PREFIX'
+	cp conf/fastcgi_params '$NGX_CONF_PATH/fastcgi_params.default'
+
+	test -f '$NGX_CONF_PATH' || cp conf/nginx.conf '$NGX_CONF_PREFIX'
+	cp conf/nginx.conf '$NGX_CONF_PREFIX/nginx.conf.default'
 
 	test -d '`dirname "$NGX_PID_PATH"`' \
 		|| mkdir -p '`dirname "$NGX_PID_PATH"`'
diff --git a/auto/options b/auto/options
index 7fb7131..0640f8c 100644
--- a/auto/options
+++ b/auto/options
@@ -6,6 +6,7 @@
 
 NGX_PREFIX=
 NGX_SBIN_PATH=
+NGX_CONF_PREFIX=
 NGX_CONF_PATH=
 NGX_ERROR_LOG_PATH=
 NGX_PID_PATH=
@@ -123,6 +124,7 @@
 
         --prefix=*)                      NGX_PREFIX="$value"        ;;
         --sbin-path=*)                   NGX_SBIN_PATH="$value"     ;;
+        --sysconfdir=*)                  NGX_CONF_PREFIX="$value"   ;;
         --conf-path=*)                   NGX_CONF_PATH="$value"     ;;
         --error-log-path=*)              NGX_ERROR_LOG_PATH="$value";;
         --pid-path=*)                    NGX_PID_PATH="$value"      ;;
@@ -240,6 +242,7 @@
 
   --prefix=PATH                      set the installation prefix
   --sbin-path=PATH                   set path to the nginx binary file
+  --sysconfdir=PATH                  set the configuration prefix
   --conf-path=PATH                   set path to the nginx.conf file
   --error-log-path=PATH              set path to the error log
   --pid-path=PATH                    set path to nginx.pid file
@@ -360,6 +363,7 @@
 
 
 NGX_PREFIX=${NGX_PREFIX:-/usr/local/nginx}
+NGX_CONF_PREFIX=${NGX_CONF_PREFIX:-$NGX_PREFIX}
 
 
 case ".$NGX_SBIN_PATH" in
@@ -381,11 +385,11 @@
     ;;
 
     .)
-        NGX_CONF_PATH=$NGX_PREFIX/conf/nginx.conf
+        NGX_CONF_PATH=$NGX_CONF_PREFIX/conf/nginx.conf
     ;;
 
     *)
-        NGX_CONF_PATH=$NGX_PREFIX/$NGX_CONF_PATH
+        NGX_CONF_PATH=$NGX_CONF_PREFIX/$NGX_CONF_PATH
     ;;
 esac
 
diff --git a/auto/summary b/auto/summary
index accb7b9..c220c71 100644
--- a/auto/summary
+++ b/auto/summary
@@ -148,6 +148,7 @@
 cat << END
   nginx path prefix: "$NGX_PREFIX"
   nginx binary file: "$NGX_SBIN_PATH"
+  nginx configuration prefix: "$NGX_CONF_PREFIX"
   nginx configuration file: "$NGX_CONF_PATH"
   nginx pid file: "$NGX_PID_PATH"
 END