6 #define HAVE_AVAILABILITY_MACROS_H 1
7 #define HAVE_TARGET_CONDITIONALS_H 1
8 #define HAVE_OSATOMIC_COMPARE_AND_SWAP_INT 1
9 #define HAVE_OSATOMIC_COMPARE_AND_SWAP_LONG 1
10 #define HAVE_LIBKERN_OSATOMIC_H
12 /* Be sneaky and turn OSAtomicCompareAndSwapInt into OSAtomicCompareAndSwap32
13 * and OSAtomicCompareAndSwapLong into either OSAtomicCompareAndSwap32
14 * or OSAtomicCompareAndSwap64 (depending on __LP64__) so that the library
15 * is Tiger compatible!
17 #include <libkern/OSAtomic.h>
18 #define OSAtomicCompareAndSwapInt OSAtomicCompareAndSwap32
20 #define OSAtomicCompareAndSwapLong OSAtomicCompareAndSwap64
22 #define OSAtomicCompareAndSwapLong OSAtomicCompareAndSwap32
25 #else /* !__APPLE__ */
29 #if !defined(__WIN32__) && !defined(_WIN32)
31 #if __GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 1) /* GCC >= 4.1 */
33 /* runtime.c ignores these if __WIN32__ or _WIN32 is defined */
34 #define HAVE_SYNC_BOOL_COMPARE_AND_SWAP_INT 1
35 #define HAVE_SYNC_BOOL_COMPARE_AND_SWAP_LONG 1
37 #else /* GCC earlier than version 4.1 */
39 #error GCC version 4.1 (or compatible) or later is required on non-apple, non-w32 targets
41 #endif /* GCC earlier than version 4.1 */
43 #endif /* !defined(__WIN32__) && !defined(_WIN32) */
47 #endif /* !__APPLE__ */
49 #endif /* _CONFIG_H_ */