Added configure options --prefix=PATH and --log=FILE.

A prefix is prepended to all relative names at configure stage.
There is no prefix by default.

A log file name can be relative.
The default log file name is "nginext.log".
This commit is contained in:
Igor Sysoev
2017-08-26 13:37:44 +03:00
parent 897b860e83
commit d3a6d7805f
4 changed files with 28 additions and 15 deletions

View File

@@ -12,6 +12,9 @@ NXT_CFLAGS=
NXT_CC_OPT=
NXT_LD_OPT=
NXT_PREFIX=
NXT_LOG="nginext.log"
NXT_DEBUG=NO
NXT_INET6=YES
@@ -54,6 +57,9 @@ do
--build-dir=*) NXT_BUILD_DIR="$value" ;;
--prefix=*) NXT_PREFIX="$value" ;;
--log=*) NXT_LOG="$value" ;;
--debug) NXT_DEBUG=YES ;;
--no-ipv6) NXT_INET6=NO ;;
@@ -94,3 +100,14 @@ do
NXT_CONFIGURE_OPTIONS="$NXT_CONFIGURE_OPTIONS $nxt_opt"
done
case "$NXT_PREFIX" in
""|*/) ;;
*) NXT_PREFIX="$NXT_PREFIX/" ;;
esac
case "$NXT_LOG" in
/*) ;;
*) NXT_LOG="$NXT_PREFIX$NXT_LOG" ;;
esac