Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F142753759
D49893.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
715 B
Referenced Files
None
Subscribers
None
D49893.diff
View Options
diff --git a/tools/build/cross-build/include/mac/string.h b/tools/build/cross-build/include/mac/string.h
--- a/tools/build/cross-build/include/mac/string.h
+++ b/tools/build/cross-build/include/mac/string.h
@@ -38,9 +38,12 @@
#include_next <string.h>
/*
- * strchrnul is not provided by macOS and the strchrnul.c implementation
- * can not be compiled on macOS so just provide it inline here
+ * strchrnul is provided by macOS 15.4 and later. However, there is
+ * no good way to detect the current host version at compile time, so
+ * provide an inline definition under an alternate name.
*/
+#define strchrnul(p, ch) __freebsd_strchrnul(p, ch)
+
static inline char *
strchrnul(const char *p, int ch)
{
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Sat, Jan 24, 3:57 AM (6 h, 46 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
27893564
Default Alt Text
D49893.diff (715 B)
Attached To
Mode
D49893: cross-build: Workaround system-provided strchrnul on macOS 15.4+
Attached
Detach File
Event Timeline
Log In to Comment