diff options
author | dkf <donal.k.fellows@manchester.ac.uk> | 2016-11-25 15:44:43 (GMT) |
---|---|---|
committer | dkf <donal.k.fellows@manchester.ac.uk> | 2016-11-25 15:44:43 (GMT) |
commit | cda6d2b5a4a63d4d80cfcbd58598686e5cfd0f35 (patch) | |
tree | 4b18b033b648b2726b82cee5d08cb3d5d4f0e4d9 /unix/configure.ac | |
parent | 7b4af51ed2c67661856796cc6669052b86bda825 (diff) | |
download | tcl-cda6d2b5a4a63d4d80cfcbd58598686e5cfd0f35.zip tcl-cda6d2b5a4a63d4d80cfcbd58598686e5cfd0f35.tar.gz tcl-cda6d2b5a4a63d4d80cfcbd58598686e5cfd0f35.tar.bz2 |
Implementation of improved notifier from Lucio Andrés Illanes Albornoz.
Diffstat (limited to 'unix/configure.ac')
-rw-r--r-- | unix/configure.ac | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/unix/configure.ac b/unix/configure.ac index bafb970..2389ab0 100644 --- a/unix/configure.ac +++ b/unix/configure.ac @@ -300,6 +300,34 @@ if test $tcl_ok = no; then AC_DEFINE(NO_FD_SET, 1, [Do we have fd_set?]) fi +#----------------------------------------------------------------------------- +# Options for the notifier. Checks for epoll(7) on Linux, and kqueue(2) +# on FreeBSD. +#----------------------------------------------------------------------------- + +AC_MSG_CHECKING([for advanced notifier support]) +case x`uname -s` in + xLinux) + AC_MSG_RESULT([epoll(7)]) + AC_CHECK_HEADERS([sys/epoll.h], + [AC_DEFINE(HAVE_EPOLL, [1], [Is epoll(7) supported?])]);; + xFreeBSD) + AC_MSG_RESULT([kqueue(2)]) + # Messy because we want to check if *all* the headers are present, and not + # just *any* + tcl_kqueue_headers=x + AC_CHECK_HEADERS([sys/types.h sys/event.h sys/time.h], + [tcl_kqueue_headers=${tcl_kqueue_headers}y]) + AS_IF([test $tcl_kqueue_headers = xyyy], [ + AC_DEFINE(HAVE_KQUEUE, [1], [Is kqueue(2) supported?])]);; + xDarwin) + # Assume that we've got CoreFoundation present (checked elsewhere because + # of wider impact). + AC_MSG_RESULT([OSX]);; + *) + AC_MSG_RESULT([none]);; +esac + #------------------------------------------------------------------------------ # Find out all about time handling differences. #------------------------------------------------------------------------------ |