From 2f801f30de646e2dbe66f3661535a7cb7e797041 Mon Sep 17 00:00:00 2001 From: Davide Beatrici Date: Mon, 3 May 2021 19:58:12 +0200 Subject: [PATCH] Fix compile errors on OpenBSD - included for the "pthread_t" type definition. - include removed as the header doesn't exist. - AI_ALL and AI_V4MAPPED defined to 0 as the options don't exist. --- src/Cedar/BridgeUnix.c | 5 ++++- src/Mayaqua/DNS.c | 8 ++++++++ src/Mayaqua/Network.h | 4 ++++ 3 files changed, 16 insertions(+), 1 deletion(-) diff --git a/src/Cedar/BridgeUnix.c b/src/Cedar/BridgeUnix.c index b883bb47..87287d7c 100644 --- a/src/Cedar/BridgeUnix.c +++ b/src/Cedar/BridgeUnix.c @@ -25,11 +25,14 @@ #include #include -#include #include #include #include +#ifndef UNIX_OPENBSD +#include +#endif + #ifdef UNIX_SOLARIS #include #endif diff --git a/src/Mayaqua/DNS.c b/src/Mayaqua/DNS.c index b5152ee5..c2617e87 100644 --- a/src/Mayaqua/DNS.c +++ b/src/Mayaqua/DNS.c @@ -13,6 +13,14 @@ #include #endif +#ifndef AI_ALL +#define AI_ALL 0 +#endif + +#ifndef AI_V4MAPPED +#define AI_V4MAPPED 0 +#endif + static bool cache_enabled; static LIST *cache; diff --git a/src/Mayaqua/Network.h b/src/Mayaqua/Network.h index b8faee9c..25ce9360 100644 --- a/src/Mayaqua/Network.h +++ b/src/Mayaqua/Network.h @@ -13,6 +13,10 @@ #ifdef OS_UNIX #include + +#ifdef UNIX_OPENBSD +#include +#endif #endif // Dynamic Value