1 /* -*- Mode: C; indent-tabs-mode: t; c-basic-offset: 4; tab-width: 4 -*- */
4 Copyright (C) 2003 Naba Kumar <naba@gnome.org>
6 This program is free software; you can redistribute it and/or modify
7 it under the terms of the GNU General Public License as published by
8 the Free Software Foundation; either version 2 of the License, or
9 (at your option) any later version.
11 This program is distributed in the hope that it will be useful,
12 but WITHOUT ANY WARRANTY; without even the implied warranty of
13 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 GNU General Public License for more details.
16 You should have received a copy of the GNU General Public License
17 along with this program; if not, write to the Free Software
18 Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
21 #ifndef __ANJUTA_DEBUG__
22 #define __ANJUTA_DEBUG__
25 * SECTION:anjuta-debug
27 * @short_description: Debug functions
30 * @include: libanjuta/anjuta-debug.h
32 * Anjuta debug messages are displayed using the g_debug() function from GLib.
34 * To display debug messages, Anjuta must have been compiled with
35 * --enable-debug and the environment variable G_MESSAGES_DEBUG should be set
36 * to "all" or to a list separated by whitespace of domains to display.
40 * G_MESSAGE_DEBUG=Gtk Anjuta libanjuta-gdb
42 * will display debug messages from Gtk, Anjuta and gdb plugin only.
48 * Equivalent to g_debug() showing the FILE, the LINE and the FUNC,
49 * except it has only effect when DEBUG is defined . Used for printing debug
53 #if defined (__GNUC__) && (__GNUC__ >= 3) && !defined(__STRICT_ANSI__)
54 #define DEBUG_PRINT(format, ...) g_debug ("%s:%d (%s) " format, __FILE__, __LINE__, G_STRFUNC, ##__VA_ARGS__)
56 #define DEBUG_PRINT g_debug
59 #define DEBUG_PRINT(...)
62 #endif /* _ANJUTA_DEBUG_H_ */