/* the exception context */
typedef ex_ctx_t *(*ex_ctx_cb_t)(void);
-extern ex_ctx_cb_t XBT_PUBLIC_DATA __xbt_ex_ctx;
+extern XBT_PUBLIC_DATA(ex_ctx_cb_t) __xbt_ex_ctx;
extern ex_ctx_t *__xbt_ex_ctx_default(void);
/* the termination handler */
typedef void (*ex_term_cb_t)(xbt_ex_t *);
-extern ex_term_cb_t XBT_PUBLIC_DATA __xbt_ex_terminate;
+extern XBT_PUBLIC_DATA(ex_term_cb_t) __xbt_ex_terminate;
extern void __xbt_ex_terminate_default(xbt_ex_t *e);
/** @brief Introduce a block where exception may be dealed with
# define XBT_PUBLIC(type) __declspec(dllexport) type
# define XBT_EXPORT_NO_IMPORT(type) __declspec(dllexport) type
# define XBT_IMPORT_NO_EXPORT(type) type
-# define XBT_PUBLIC_DATA __declspec(dllexport)
+# define XBT_PUBLIC_DATA(type) __declspec(dllexport) type
/* Pack everything up statically */
#elif defined(DLL_STATIC)
# define XBT_PUBLIC(type) type
# define XBT_EXPORT_NO_IMPORT(type) type
# define XBT_IMPORT_NO_EXPORT(type) type
-# define XBT_PUBLIC_DATA
+# define XBT_PUBLIC_DATA(type) type
/* Link against the DLL */
# define XBT_PUBLIC(type) __declspec(dllimport) type
# define XBT_EXPORT_NO_IMPORT(type) type
# define XBT_IMPORT_NO_EXPORT(type) __declspec(dllimport) type
-# define XBT_PUBLIC_DATA __declspec(dllimport)
+# define XBT_PUBLIC_DATA(type) __declspec(dllimport) type
-/* Non-UNIX build. Let's keep sain here ;) */
+/* UNIX build. Let's keep sain here ;) */
#else
# define XBT_PUBLIC(type) extern type
# define XBT_EXPORT_NO_IMPORT(type) type
# define XBT_IMPORT_NO_EXPORT(type) type
-# define XBT_PUBLIC_DATA
+# define XBT_PUBLIC_DATA(type) type
#endif
#if !defined (max) && !defined(__cplusplus)
/* globals */
static gras_procdata_t *_gras_procdata = NULL;
-char const * XBT_PUBLIC_DATA _gras_procname = NULL;
+XBT_PUBLIC_DATA(char const *) _gras_procname = NULL;
void gras_process_init() {
_gras_procdata=xbt_new0(gras_procdata_t,1);
/* globals */
static gras_procdata_t *_gras_procdata = NULL;
-char const * XBT_PUBLIC_DATA _gras_procname = NULL;
+XBT_PUBLIC_DATA(char const *) _gras_procname = NULL;
void gras_process_init() {
_gras_procdata=xbt_new0(gras_procdata_t,1);