From 159c1ec26428bc6206ea4ac8dcc3f4ea1569793a Mon Sep 17 00:00:00 2001 From: Eric Wong Date: Sun, 28 Dec 2014 01:26:00 +0000 Subject: [PATCH] extconf: detect inotify_init1 in libc Many systems have inotify_init1 nowadays, so use inotify_init1 if it is available to avoid unnecessary syscalls. --- ext/sleepy_penguin/extconf.rb | 1 + 1 file changed, 1 insertion(+) diff --git a/ext/sleepy_penguin/extconf.rb b/ext/sleepy_penguin/extconf.rb index 407c947..eda7fcd 100644 --- a/ext/sleepy_penguin/extconf.rb +++ b/ext/sleepy_penguin/extconf.rb @@ -20,6 +20,7 @@ end have_type('clockid_t', 'time.h') have_func('clock_gettime', 'time.h') have_func('epoll_create1', %w(sys/epoll.h)) +have_func('inotify_init1', %w(sys/inotify.h)) have_func('rb_thread_call_without_gvl') have_func('rb_thread_blocking_region') have_func('rb_thread_io_blocking_region') -- 2.11.4.GIT