diff --git a/lib/macos.c b/lib/macos.c index 205d30db32..70393b4bf7 100644 --- a/lib/macos.c +++ b/lib/macos.c @@ -30,7 +30,17 @@ #include "macos.h" +/* Certain Apple SDK v13.0+ headers are incompatible with the GCC compiler. + As a workaround, use a minimal header and define the function we need, + to avoid hitting those incompatibilities when compiling with GCC. */ +#if defined(__clang__) #include +#else +#include +typedef const struct CF_BRIDGED_TYPE(id) __SCDynamicStore * SCDynamicStoreRef; +CFDictionaryRef __nullable +SCDynamicStoreCopyProxies(SCDynamicStoreRef __nullable store); +#endif CURLcode Curl_macos_init(void) {