]> git.kaiwu.me - nginx.git/commitdiff
Solaris directio()
authorIgor Sysoev <igor@sysoev.ru>
Mon, 4 Aug 2008 15:32:10 +0000 (15:32 +0000)
committerIgor Sysoev <igor@sysoev.ru>
Mon, 4 Aug 2008 15:32:10 +0000 (15:32 +0000)
auto/os/features
src/os/unix/ngx_files.h

index ffb27a4813e5a845c7edde2d5c6fd3dea144b7d2..8efed75a225838216d830f2f5c796b817e153c6d 100644 (file)
@@ -190,3 +190,14 @@ ngx_feature_path=
 ngx_feature_libs=
 ngx_feature_test="fcntl(0, F_NOCACHE, 1);"
 . auto/feature
+
+
+ngx_feature="directio()"
+ngx_feature_name="NGX_HAVE_DIRECTIO"
+ngx_feature_run=no
+ngx_feature_incs="#include <sys/types.h>
+                  #include <sys/fcntl.h>"
+ngx_feature_path=
+ngx_feature_libs=
+ngx_feature_test="directio(0, DIRECTIO_ON);"
+. auto/feature
index 62af63bce74b31eec17470d1af4dec4becc6e9b7..7e84070862b5d428266875eba24b5f5f1b2f37de 100644 (file)
@@ -199,6 +199,11 @@ ngx_int_t ngx_directio(ngx_fd_t fd);
 #define ngx_directio(fd)         fcntl(fd, F_NOCACHE, 1)
 #define ngx_directio_n           "fcntl(F_NOCACHE)"
 
+#elif (NGX_HAVE_DIRECTIO)
+
+#define ngx_directio(fd)         directio(fd, DIRECTIO_ON)
+#define ngx_directio_n           "directio(DIRECTIO_ON)"
+
 #else
 
 #define ngx_directio(fd)         0