From d58aed1bd1e82193bab4c9156198804d556dca82 Mon Sep 17 00:00:00 2001 From: Marco Pesenti Gritti Date: Wed, 09 Feb 2005 15:01:24 +0000 Subject: Fix compilation on non-gcc platforms 2005-02-09 Marco Pesenti Gritti * lib/ev-debug.c: * lib/ev-debug.h: * ps/ps-document.c: (ps_document_finalize), (set_up_page), (start_interpreter), (stop_interpreter), (document_load), (ps_document_next_page), (ps_document_goto_page), (ps_document_set_page_size), (ps_document_widget_event), (ps_document_render): * shell/ev-page-view.c: (ev_page_view_dispose): * shell/ev-view.c: (ev_view_finalize), (expose_bin_window): Fix compilation on non-gcc platforms --- (limited to 'lib/ev-debug.h') diff --git a/lib/ev-debug.h b/lib/ev-debug.h index 2c4c521..53c1e61 100644 --- a/lib/ev-debug.h +++ b/lib/ev-debug.h @@ -32,13 +32,25 @@ G_BEGIN_DECLS #define DISABLE_PROFILING #endif +#if defined(G_HAVE_GNUC_VARARGS) + #ifdef DISABLE_LOGGING -#define LOG(msg, args...) +#define LOG(msg, args...) G_STMT_START { } G_STMT_END #else -#define LOG(msg, args...) \ -g_log (G_LOG_DOMAIN, G_LOG_LEVEL_DEBUG, \ - "[ %s ] " msg, \ - __FILE__ , ## args); +#define LOG(msg, args...) \ +g_log (G_LOG_DOMAIN, G_LOG_LEVEL_DEBUG, \ + "[ %s ] " msg, \ + __FILE__ , ## args) +#endif + +#elif defined(G_HAVE_ISO_VARARGS) + +#define LOG(...) G_STMT_START { } G_STMT_END + +#else /* no varargs macros */ + +static void LOG(const char *format, ...) {} + #endif #ifdef DISABLE_PROFILING -- cgit v0.9.1