summaryrefslogtreecommitdiffhomepage
path: root/auto
diff options
context:
space:
mode:
authorAndrei Belov <defan@nginx.com>2020-04-16 18:27:26 +0300
committerAndrei Belov <defan@nginx.com>2020-04-16 18:27:26 +0300
commit74f32d26b91f49d3392605e81c1597b375890b60 (patch)
treeadfc67dfc86461441bde65512f745ce27bd6ea28 /auto
parent2ff9df10ef1df43c935c870175e52473dad2c21a (diff)
parent9877087756144d3bdf343d0d4e91e1efbcc62c93 (diff)
downloadunit-1.17.0-1.tar.gz
unit-1.17.0-1.tar.bz2
Merged with the default branch.1.17.0-1
Diffstat (limited to 'auto')
-rw-r--r--auto/sendfile56
-rw-r--r--auto/sources1
2 files changed, 33 insertions, 24 deletions
diff --git a/auto/sendfile b/auto/sendfile
index e5bf3b79..a065f7b6 100644
--- a/auto/sendfile
+++ b/auto/sendfile
@@ -46,7 +46,7 @@ if [ $nxt_found = no ]; then
int main() {
off_t sent;
- sendfile(-1, -1, 0, 0, NULL, &sent, SF_NODISKIO);
+ sendfile(-1, -1, 0, 0, NULL, &sent, 0);
return 0;
}"
. auto/feature
@@ -57,55 +57,63 @@ if [ $nxt_found = no ]; then
fi
-NXT_LIBSENDFILE=
-
if [ $nxt_found = no ]; then
- # Solaris 8 sendfilev().
+ # MacOSX sendfile().
- nxt_feature="Solaris sendfilev()"
- nxt_feature_name=NXT_HAVE_SOLARIS_SENDFILEV
- nxt_feature_libs="-lsendfile"
- nxt_feature_test="#include <sys/sendfile.h>
+ nxt_feature="MacOSX sendfile()"
+ nxt_feature_name=NXT_HAVE_MACOSX_SENDFILE
+ nxt_feature_libs=
+ nxt_feature_test="#include <sys/types.h>
+ #include <sys/socket.h>
+ #include <sys/uio.h>
+ #include <stdlib.h>
int main() {
- size_t sent;
- struct sendfilevec vec;
+ off_t sent;
- sendfilev(-1, &vec, 0, &sent);
+ sendfile(-1, -1, 0, &sent, NULL, 0);
return 0;
}"
. auto/feature
if [ $nxt_found = yes ]; then
- NXT_HAVE_SOLARIS_SENDFILEV=YES
- NXT_LIBSENDFILE=$nxt_feature_libs
+ NXT_HAVE_MACOSX_SENDFILE=YES
fi
fi
if [ $nxt_found = no ]; then
+ $echo
+ $echo "$0: error: no supported sendfile() found."
+ $echo
+ exit 1;
+fi
- # MacOSX sendfile().
- nxt_feature="MacOSX sendfile()"
- nxt_feature_name=NXT_HAVE_MACOSX_SENDFILE
- nxt_feature_libs=
- nxt_feature_test="#include <sys/types.h>
- #include <sys/socket.h>
- #include <sys/uio.h>
- #include <stdlib.h>
+NXT_LIBSENDFILE=
+
+if [ $nxt_found = no ]; then
+
+ # Solaris 8 sendfilev().
+
+ nxt_feature="Solaris sendfilev()"
+ nxt_feature_name=NXT_HAVE_SOLARIS_SENDFILEV
+ nxt_feature_libs="-lsendfile"
+ nxt_feature_test="#include <sys/sendfile.h>
int main() {
- off_t sent;
+ size_t sent;
+ struct sendfilevec vec;
- sendfile(-1, -1, 0, &sent, NULL, 0);
+ sendfilev(-1, &vec, 0, &sent);
return 0;
}"
. auto/feature
if [ $nxt_found = yes ]; then
- NXT_HAVE_MACOSX_SENDFILE=YES
+ NXT_HAVE_SOLARIS_SENDFILEV=YES
+ NXT_LIBSENDFILE=$nxt_feature_libs
fi
fi
diff --git a/auto/sources b/auto/sources
index 2283e543..c6b34bbc 100644
--- a/auto/sources
+++ b/auto/sources
@@ -87,6 +87,7 @@ NXT_LIB_SRCS=" \
src/nxt_http_error.c \
src/nxt_http_route.c \
src/nxt_http_route_addr.c \
+ src/nxt_http_return.c \
src/nxt_http_static.c \
src/nxt_http_proxy.c \
src/nxt_application.c \