From 33232f3f05c333779ef418b4656e1fb75d689495 Mon Sep 17 00:00:00 2001 From: Sergey Fedorov Date: Sun, 1 Dec 2024 20:09:14 +0800 Subject: [PATCH] core-crypto.c: fix htobe64 for Darwin (closes #2216) --- CHANGELOG.md | 1 + src/core/core-crypto.c | 5 ++++- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 41ca0859b..c41104c94 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -41,6 +41,7 @@ - relay, xfer: fix letters with actions displayed on top of buffer - perl: fix crash when unloading Perl scripts with Perl 5.38 ([#2209](https://github.com/weechat/weechat/issues/2209), [#2213](https://github.com/weechat/weechat/issues/2213)) - lua: fix compilation on Fedora with Lua < 5.2.0 ([#2173](https://github.com/weechat/weechat/issues/2173), [#2174](https://github.com/weechat/weechat/issues/2174)) +- core: fix build on Darwin ([#2216](https://github.com/weechat/weechat/issues/2216)) - core: fix build on Android ([#2180](https://github.com/weechat/weechat/issues/2180)) ## Version 4.4.4 (2024-11-30) diff --git a/src/core/core-crypto.c b/src/core/core-crypto.c index ce93de879..dc23469aa 100644 --- a/src/core/core-crypto.c +++ b/src/core/core-crypto.c @@ -31,10 +31,13 @@ #include #include -#ifdef __ANDROID__ /* Bring in htobe64 */ +#ifdef __ANDROID__ #define _BSD_SOURCE #include +#elif defined(__APPLE__) +#include +#define htobe64 OSSwapHostToBigInt64 #endif #include "weechat.h"