Skip to content

Commit db5c279

Browse files
committed
Only build CNIOOpenBSD on OpenBSD.
1 parent f53474d commit db5c279

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

Sources/CNIOOpenBSD/include/CNIOOpenBSD.h

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,11 @@
1414
#ifndef C_NIO_OPENBSD_H
1515
#define C_NIO_OPENBSD_H
1616

17-
#include <sys/types.h>
17+
#if defined(__OpenBSD__)
1818
#include <sys/event.h>
19+
#include <pthread_np.h>
20+
#endif
21+
#include <sys/types.h>
1922
#include <sys/socket.h>
2023
#include <sys/stat.h>
2124
#include <sys/time.h>
@@ -28,7 +31,6 @@
2831
#include <netinet/in.h>
2932
#include <netinet/ip.h>
3033
#include <pthread.h>
31-
#include <pthread_np.h>
3234
#include <stdbool.h>
3335

3436

0 commit comments

Comments
 (0)