Please consider this patch for auto/install to overcome a compile error if the '/naxsi/naxsi_src' [optional module] is not enabled.
The patch is for the file /auto/install
test -d '\$(DESTDIR)$NGX_PREFIX/html' \
|| cp -R $NGX_HTML '\$(DESTDIR)$NGX_PREFIX'
- test -d '\$(DESTDIR)$NGX_PREFIX/naxsi' || mkdir -p '\$(DESTDIR)$NGX_PREFIX/naxsi'
- cp -R 3rd-party/naxsi/nx_util '\$(DESTDIR)$NGX_PREFIX/naxsi/'
- cp -R 3rd-party/naxsi/naxsi_config '\$(DESTDIR)$NGX_PREFIX/naxsi/'
- sed -i 's#naxsi_core_rules=.*#naxsi_core_rules=\$(DESTDIR)$NGX_PREFIX/naxsi/naxsi_config/naxsi_core.rules#' '\$(DESTDIR)$NGX_PREFIX/naxsi/nx_util/nx_util.conf'
- sed -i 's#data_dir=.*#data_dir=\$(DESTDIR)$NGX_PREFIX/naxsi/nx_util/nx_datas#' '\$(DESTDIR)$NGX_PREFIX/naxsi/nx_util/nx_util.conf'
END
if test -n "$NGX_ERROR_LOG_PATH"; then
cat << END >> $NGX_MAKEFILE
test -d '\$(DESTDIR)`dirname "$NGX_ERROR_LOG_PATH"`' || \
mkdir -p '\$(DESTDIR)`dirname "$NGX_ERROR_LOG_PATH"`'
END
fi
Otherwise, without the optional '/naxsi/naxsi_src' module compiling will fail with this error:
test -d '/root/rpmbuild/BUILDROOT/nginx-1.5.12-1.fc20.x86_64/usr/share/nginx/naxsi' || mkdir -p '/root/rpmbuild/BUILDROOT/nginx-1.5.12-1.fc20.x86_64/usr/share/nginx/naxsi'
cp -R 3rd-party/naxsi/nx_util '/root/rpmbuild/BUILDROOT/nginx-1.5.12-1.fc20.x86_64/usr/share/nginx/naxsi/'
cp: cannot stat '3rd-party/naxsi/nx_util': No such file or directory
make[1]: *** [install] Error 1
Please consider this patch for auto/install to overcome a compile error if the '/naxsi/naxsi_src' [optional module] is not enabled.
The patch is for the file /auto/install
Otherwise, without the optional '/naxsi/naxsi_src' module compiling will fail with this error: