Add workaround for unguarded use of __has_extension (for v2.x)

This commit is contained in:
morinmorin 2024-03-13 03:35:34 +09:00 committed by Martin Hořeňovský
parent d4b0b34561
commit a7782d1d7c

View File

@ -12,6 +12,9 @@
// See e.g.:
// https://opensource.apple.com/source/CarbonHeaders/CarbonHeaders-18.1/TargetConditionals.h.auto.html
#ifdef __APPLE__
# ifndef __has_extension
# define __has_extension(x) 0
# endif
# include <TargetConditionals.h>
# if (defined(TARGET_OS_OSX) && TARGET_OS_OSX == 1) || \
(defined(TARGET_OS_MAC) && TARGET_OS_MAC == 1)