nginx-0.0.1-2004-01-30-00:45:01 import
diff --git a/auto/os/linux b/auto/os/linux
index bf5092a..8990e6d 100644
--- a/auto/os/linux
+++ b/auto/os/linux
@@ -7,6 +7,15 @@
 ZLIB_LIB="-lz"
 
 
+NGX_INC="sys/epoll.h"; . auto/inc
+
+if [ $NGX_FOUND=YES ]; then
+    CFLAGS="$CFLAGS -D HAVE_EPOLL=1"
+    EVENT_MODULES="$EVENT_MODULES $EPOLL_MODULE"
+    CORE_SRCS="$CORE_SRCS $EPOLL_SRCS"
+fi
+
+
 # TODO check sendfile64()
 
 CC_TEST_FLAGS="-D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE"