Enable kqueue on MacOS

Make sure JANET_EV_KQUEUE is defined when JANET_APPLE is defined unless
disabled by configuration.
This commit is contained in:
llmII 2021-09-06 16:01:06 -05:00
parent 121aa91139
commit 48a3b1f07f
No known key found for this signature in database
GPG Key ID: E3AD2E259F58A9A0
1 changed files with 6 additions and 0 deletions

View File

@ -198,10 +198,16 @@ extern "C" {
#define JANET_EV_EPOLL
#endif
/* Enable or disable kqueue on BSD */
#if defined(JANET_BSD) && !defined(JANET_EV_NO_KQUEUE)
#define JANET_EV_KQUEUE
#endif
/* Enable or disable kqueue on Apple */
#if defined(JANET_APPLE) && !defined(JANET_EV_NO_KQUEUE)
#define JANET_EV_KQUEUE
#endif
/* How to export symbols */
#ifndef JANET_API
#ifdef JANET_WINDOWS