Patch for MacOS build

2 views
Skip to first unread message

more...@pm.me

unread,
Mar 6, 2026, 5:08:53 AM (3 days ago) Mar 6
to proso...@googlegroups.com
Hi Prosody team,

I am running prosody 0.13.1 on my Mac Mini, I thought I'd share the diff for the change I had to make to get it to build.

I'm Aster, or morerunes. I've been getting a prosody server set up and getting more into the weeds with XMPP in general lately. Hoping to contribute more in the future.

I would be interested in updating the homebrew package for prosody as well, as I hadn't initially realized it was out of date until I couldn't get sasl2 stuff working.

The change was pretty small and I've been running it for a couple weeks now without issues as far as I can tell, aside from the (I assume unrelated) "Your server's certificate is not trusted" messages when connecting to external servers, which I plan to spend time debugging later.

Thanks for your time!

Aster

The change was basically just to exclude two file descriptor flags that aren't available on MacOS. Here's the diff:

# HG changeset patch
# User morerunes <more...@protonmail.com>
# Date 1772724296 18000
# Thu Mar 05 10:24:56 2026 -0500
# Node ID d7fdb1395432270bece115585a16213f3097f50d
# Parent 414e731b5972c8431c813ca3fbcb5240a98bb5d2
enable compilation on MacOS

diff -r 414e731b5972 -r d7fdb1395432 util-src/pposix.c
--- a/util-src/pposix.c Mon Feb 16 17:56:32 2026 +0000
+++ b/util-src/pposix.c Thu Mar 05 10:24:56 2026 -0500
@@ -663,13 +663,17 @@
}

const char *pipe_flag_names[] = {
+#if !defined(__APPLE__)
"cloexec",
"direct",
+#endif
"nonblock"
};
const int pipe_flag_values[] = {
+#if !defined(__APPLE__)
O_CLOEXEC,
O_DIRECT,
+#endif
O_NONBLOCK
};


signature.asc
Reply all
Reply to author
Forward
0 new messages