From 4973a4deab2504fe6166924b2a31d735cf4624cc Mon Sep 17 00:00:00 2001 From: Aarni Koskela Date: Wed, 19 Sep 2018 14:31:38 +0300 Subject: [PATCH] Become macOS compatible --- opustags.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/opustags.c b/opustags.c index 18713bf..b5bcc81 100644 --- a/opustags.c +++ b/opustags.c @@ -7,6 +7,12 @@ #include #include +#ifdef __APPLE__ +#include +#define htole32(x) OSSwapHostToLittleInt32(x) +#define le32toh(x) OSSwapLittleToHostInt32(x) +#endif + typedef struct { uint32_t vendor_length; const char *vendor_string;