Darling build of libkqueue
Go to file
Ariel Abreu dfe9fbc0d2
Various synchronization and resource management fixes
The two most notable fixes are:
1) libsystem_kernel now delegates closing kqueue descriptor to us.
Rather than close the descriptor and inform us later, it allows us to
handle kqueue closing ourselves.
This avoids a double-close that was causing issues (most notably
with multi-threaded programs).
2) We now `map_delete` all references to kqueues being freed. We were
previously only deleting the original FD reference.

In addition, wherever `kqueue_delref` is called, the `kq_mtx` must be held.
This is required because that function can call `kqueue_free`, which
requires that lock to be held. While inefficient, this should help avoid
races between threads concurrently modifying the kqueue map. A better
solution should be devised later to make this more efficient.
2022-06-15 11:42:47 -04:00
include/sys Workaround an issue caused by a flag 2020-10-06 08:28:31 -04:00
kern starting to come together 2010-02-28 00:25:36 +00:00
kqlite kqlite: add initial timerfd support 2014-01-22 04:30:45 +00:00
libkqueue.xcodeproj Updated Xcode project 2011-05-20 05:47:20 +00:00
ports/debian rel 7.0 #2 2010-06-09 03:41:18 +00:00
src Various synchronization and resource management fixes 2022-06-15 11:42:47 -04:00
test Minor imporovements to test runner: 2013-06-11 14:45:42 +00:00
BUGS Use pthread_once() instead of marking libkqueue_init() as a constructor. 2012-11-26 02:32:45 +00:00
ChangeLog * Fix incorrect boolean logic in src/linux/read.c 2015-01-26 22:09:53 -05:00
CMakeLists.txt Implement EVFILT_MACHPORT with darlingserver 2022-02-10 13:23:16 -05:00
config.inc Add -Wextra to CFLAGS and fix all related warnings on Linux. 2011-05-22 00:28:35 +00:00
configure.ac configure.ac: Fix quoting on AC_CHECK_HEADERS 2014-08-20 15:06:01 +01:00
configure.rb Release version 2.0.1 2013-05-09 01:43:36 +00:00
kqueue.2 update manpage 2010-09-18 02:40:44 +00:00
libkqueue.la.in * Install libkqueue.la and libkqueue.a in LIBDIR 2009-11-18 01:22:29 +00:00
libkqueue.pc.in fix libkqueue.pc generation 2014-03-09 20:40:24 -04:00
libkqueue.sln win32 timer filter mostly done, improved windows_kevent_wait() 2011-01-21 03:30:35 +00:00
libkqueue.spec Release version 2.0.1 2013-05-09 01:43:36 +00:00
libkqueue.vcxproj EVFILT_USER implementation on windows 2011-04-26 20:12:28 +00:00
libkqueue.vcxproj.filters EVFILT_USER implementation on windows 2011-04-26 20:12:28 +00:00
LICENSE Rename COPYING to LICENSE to match libpwq/ 2013-05-08 12:50:01 +00:00
Makefile.am add missing header 2014-02-23 20:34:25 -05:00
README.md Integrate INSTALL with a new README file that includes very breif release 2013-06-01 21:45:01 +00:00
TODO Adapt test_kevent_user_multi_trigger_merged() from the 1.0 branch. It appears that 2.0-current does not suffer from the same problem. Tests pass on Debian 6.0/i386. 2013-06-04 14:14:36 +00:00

libkqueue

A user space implementation of the kqueue(2) kernel event notification mechanism libkqueue acts as a translator between the kevent structure and the native kernel facilities on Linux, Android, Solaris, and Windows.

Supported Event Types

  • vnode
  • socket
  • proc
  • user
  • timer

Installation - Linux, Solaris

./configure
make
make install

Installation - Red Hat

./configure
make package
rpm -i *.rpm

Installation - Android

ruby ./configure.rb --host=arm-linux-androideabi \
                    --with-ndk=/opt/android-ndk-r8c \
                    --with-sdk=/opt/android-sdks
make

Running Unit Tests

./configure
make
make check

Building Applications

CFLAGS += -I/usr/include/kqueue
LDFLAGS += -lkqueue

Tutorials & Examples

Kqueues for Fun and Profit

Handling TCP Connections with Kqueue Event Notification

Releases History

2.0 add support for Android 2013-04-29

1.0 stable relesae for Linux, Solaris, and Windows 2010-09-18