3 * Functions copied from glib 2.10
5 * Copyright 2005 David Schleef <ds@schleef.org>
8 #ifndef __GLIB_COMPAT_PRIVATE_H__
9 #define __GLIB_COMPAT_PRIVATE_H__
15 #if !GLIB_CHECK_VERSION(2,25,0)
17 #if defined (_MSC_VER) && !defined(_WIN64)
18 typedef struct _stat32 GStatBuf;
20 typedef struct stat GStatBuf;
25 #if GLIB_CHECK_VERSION(2,26,0)
26 #define GLIB_HAS_GDATETIME
30 #if GLIB_CHECK_VERSION(2,29,5)
31 #define G_ATOMIC_POINTER_COMPARE_AND_EXCHANGE(a,b,c) \
32 g_atomic_pointer_compare_and_exchange ((a),(b),(c))
33 #define G_ATOMIC_INT_COMPARE_AND_EXCHANGE(a,b,c) \
34 g_atomic_int_compare_and_exchange ((a),(b),(c))
36 #define G_ATOMIC_POINTER_COMPARE_AND_EXCHANGE(a,b,c) \
37 g_atomic_pointer_compare_and_exchange ((volatile gpointer *)(a),(b),(c))
38 #define G_ATOMIC_INT_COMPARE_AND_EXCHANGE(a,b,c) \
39 g_atomic_int_compare_and_exchange ((volatile int *)(a),(b),(c))
43 #if GLIB_CHECK_VERSION(2,29,5)
44 #define G_ATOMIC_INT_ADD(a,b) g_atomic_int_add ((a),(b))
46 #define G_ATOMIC_INT_ADD(a,b) g_atomic_int_exchange_and_add ((a),(b))