aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMaxim Konovalov <maxim@nginx.com>2011-11-21 11:51:41 +0000
committerMaxim Konovalov <maxim@nginx.com>2011-11-21 11:51:41 +0000
commitd4a2f14262c967d8be2f46815ec4a04cca9ba55b (patch)
treed396b3601e614d25404b4034d52d00670081bd20
parentdf56c2e23921d0541b2b13d9088d98433ba47d08 (diff)
downloadnginx-d4a2f14262c967d8be2f46815ec4a04cca9ba55b.tar.gz
nginx-d4a2f14262c967d8be2f46815ec4a04cca9ba55b.zip
o AIX 7 defines sys_nerr in errno.h, therefore <errno.h> included
in the sys_nerr test. o When sys_nerr and _sys_nerr are missed on a particular platform and our euristic for a maximum errno detection applied always print the maximum errno number we reached instead of printing void.[*] * patch from Maxim Dounin This commit makes possible to build nginx on AIX 7.1.
-rwxr-xr-xauto/unix9
1 files changed, 5 insertions, 4 deletions
diff --git a/auto/unix b/auto/unix
index ca533487c..7621e8fa2 100755
--- a/auto/unix
+++ b/auto/unix
@@ -496,7 +496,8 @@ ngx_feature_test="char buf[1]; ssize_t n; n = pwrite(1, buf, 1, 0)"
ngx_feature="sys_nerr"
ngx_feature_name="NGX_SYS_NERR"
ngx_feature_run=value
-ngx_feature_incs='#include <stdio.h>'
+ngx_feature_incs='#include <errno.h>
+ #include <stdio.h>'
ngx_feature_path=
ngx_feature_libs=
ngx_feature_test='printf("%d", sys_nerr);'
@@ -538,10 +539,10 @@ if [ $ngx_found = no ]; then
|| p == NULL
|| strncmp(p, "Unknown error", 13) == 0)
{
- printf("%d", n);
- return 0;
+ break;
}
- }'
+ }
+ printf("%d", n);'
. auto/feature
fi