mirror of
https://github.com/tsl0922/ttyd.git
synced 2026-01-06 02:44:21 +01:00
Shims to compile under OpenBSD
STAILQ_HEAD is implemented as SIMPLEQ_HEAD pty.h is like in apple , util.h
This commit is contained in:
13
src/server.h
13
src/server.h
@@ -22,7 +22,18 @@
|
||||
#include <sys/wait.h>
|
||||
#include <assert.h>
|
||||
|
||||
#ifdef __APPLE__
|
||||
#ifdef __OpenBSD__
|
||||
#define STAILQ_HEAD SIMPLEQ_HEAD
|
||||
#define STAILQ_ENTRY SIMPLEQ_ENTRY
|
||||
#define STAILQ_INIT SIMPLEQ_INIT
|
||||
#define STAILQ_INSERT_TAIL SIMPLEQ_INSERT_TAIL
|
||||
#define STAILQ_EMPTY SIMPLEQ_EMPTY
|
||||
#define STAILQ_FIRST SIMPLEQ_FIRST
|
||||
#define STAILQ_REMOVE_HEAD SIMPLEQ_REMOVE_HEAD
|
||||
#define STAILQ_FOREACH SIMPLEQ_FOREACH
|
||||
#endif
|
||||
|
||||
#if defined(__OpenBSD__) || defined(__APPLE__)
|
||||
#include <util.h>
|
||||
#elif defined(__FreeBSD__)
|
||||
#include <libutil.h>
|
||||
|
||||
Reference in New Issue
Block a user