[goffice] Moved debug declarations to goffice-debug.h



commit e13141924b8d2d6d6e94eacf3a84e1ab1f493fa7
Author: Jean Brefort <jean brefort normalesup org>
Date:   Mon Dec 3 22:21:56 2012 +0100

    Moved debug declarations to goffice-debug.h

 ChangeLog                     |   13 +++++++++++++
 configure.in                  |    6 +++---
 goffice/Makefile.am           |    3 ++-
 goffice/app/go-plugin.c       |    1 +
 goffice/app/go-plugin.h       |    7 -------
 goffice/goffice-debug.h       |   40 ++++++++++++++++++++++++++++++++++++++++
 goffice/graph/goffice-graph.h |    8 --------
 goffice/graph/gog-axis.c      |    1 +
 goffice/graph/gog-object.c    |    1 +
 goffice/graph/gog-renderer.c  |    1 +
 goffice/graph/gog-view.c      |    1 +
 11 files changed, 63 insertions(+), 19 deletions(-)
---
diff --git a/ChangeLog b/ChangeLog
index 62e90c3..4a41992 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,16 @@
+2012-12-03  Jean Brefort  <jean brefort normalesup org>
+
+	* configure.in: rquire lasem >= 0.4.1.
+	* goffice/Makefile.am: add goffice-debug.h.
+	* goffice/goffice-debug.h: new private header.
+	* goffice/app/go-plugin.c: moved debug declarations to goffice-debug.h.
+	* goffice/app/go-plugin.h: ditto.
+	* goffice/graph/goffice-graph.h: ditto.
+	* goffice/graph/gog-axis.c: ditto.
+	* goffice/graph/gog-object.c: ditto.
+	* goffice/graph/gog-renderer.c: ditto.
+	* goffice/graph/gog-view.c: ditto.
+
 2012-11-29  Morten Welinder <terra gnome org>
 
 	* configure.in: Post-release bump.
diff --git a/configure.in b/configure.in
index d086b18..bc145d0 100644
--- a/configure.in
+++ b/configure.in
@@ -133,16 +133,16 @@ AC_ARG_WITH(lasem,
 AS_CASE([$with_lasem],
 	[no],[found_lasem="disabled by request"],
 	[auto], [
-	PKG_CHECK_MODULES(Lasem, lasem-0.4 >= 0.3.4,
+	PKG_CHECK_MODULES(Lasem, lasem-0.4 >= 0.4.1,
 	[found_lasem="yes";goffice_with_lasem=true], [found_lasem="no, missing or too old lasem library"])
 	],
 	[yes],[found_lasem="yes";
-	PKG_CHECK_MODULES(Lasem, lasem-0.4 >= 0.3.4);
+	PKG_CHECK_MODULES(Lasem, lasem-0.4 >= 0.4.1);
 	goffice_with_lasem=true
 	],[AC_MSG_ERROR([invalid argument passed to --with-lasem, should be one of @<:@no/auto/yes@:>@])])
 if test "x$goffice_with_lasem" = "xtrue" ; then
 	AC_DEFINE(GOFFICE_WITH_LASEM, 1, [Define if Lasem is used])
-	goffice_reqs="$goffice_reqs lasem-0.4 >= 0.3.4 "
+	goffice_reqs="$goffice_reqs lasem-0.4 >= 0.4.1 "
 	EXTRA_DEPS="$EXTRA_DEPS lasem-0.4"
 fi
 
diff --git a/goffice/Makefile.am b/goffice/Makefile.am
index 3e9b78a..e520e5d 100644
--- a/goffice/Makefile.am
+++ b/goffice/Makefile.am
@@ -14,7 +14,8 @@ INTROSPECTION_COMPILER_ARGS = \
 #app directory files
 
 noinst_HEADERS = \
-	app/file-priv.h
+	app/file-priv.h \
+	goffice-debug.h
 
 app_SOURCES = \
 	app/go-doc.c 			\
diff --git a/goffice/app/go-plugin.c b/goffice/app/go-plugin.c
index c9b1c6a..0e29149 100644
--- a/goffice/app/go-plugin.c
+++ b/goffice/app/go-plugin.c
@@ -27,6 +27,7 @@
 #include <goffice/goffice-config.h>
 #include <goffice/goffice-priv.h>
 #include <goffice/goffice-paths.h>
+#include <goffice/goffice-debug.h>
 #include <goffice/app/go-plugin.h>
 #include <goffice/app/go-plugin-service.h>
 #include <goffice/app/go-plugin-loader.h>
diff --git a/goffice/app/go-plugin.h b/goffice/app/go-plugin.h
index 52fdc1d..9ff9266 100644
--- a/goffice/app/go-plugin.h
+++ b/goffice/app/go-plugin.h
@@ -6,13 +6,6 @@
 
 G_BEGIN_DECLS
 
-/*
- * Use "#define PLUGIN_DEBUG x" to enable some plugin related debugging
- * messages.
-#undef PLUGIN_DEBUG
- * Define PLUGIN_ALWAYS_LOAD to disable loading on demand feature
- */
-
 #define GO_TYPE_PLUGIN	(go_plugin_get_type ())
 #define GO_PLUGIN(o)	(G_TYPE_CHECK_INSTANCE_CAST ((o), GO_TYPE_PLUGIN, GOPlugin))
 #define GO_IS_PLUGIN(o)	(G_TYPE_CHECK_INSTANCE_TYPE ((o), GO_TYPE_PLUGIN))
diff --git a/goffice/goffice-debug.h b/goffice/goffice-debug.h
new file mode 100644
index 0000000..4a79551
--- /dev/null
+++ b/goffice/goffice-debug.h
@@ -0,0 +1,40 @@
+/*
+ * goffice-debug.h:
+ *
+ * Copyright (C) 2003-2004 Jody Goldberg (jody gnome org)
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License as
+ * published by the Free Software Foundation; either version 2 of the
+ * License, or (at your option) version 3.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301
+ * USA
+ */
+
+#ifndef GOFFICE_DEBUG_H
+#define GOFFICE_DEBUG_H
+
+/*
+ * Use "#define PLUGIN_DEBUG x" to enable some plugin related debugging
+ * messages.
+#undef PLUGIN_DEBUG
+ * Define PLUGIN_ALWAYS_LOAD to disable loading on demand feature
+ */
+
+/* #define NO_DEBUG_CHARTS */
+#ifndef NO_DEBUG_CHARTS
+#define gog_debug(level, code)	do { if (goffice_graph_debug_level > level) { code } } while (0)
+#else
+#define gog_debug(level, code)
+#endif
+extern int goffice_graph_debug_level;
+
+#endif
diff --git a/goffice/graph/goffice-graph.h b/goffice/graph/goffice-graph.h
index ff50a8b..2b1fe2f 100644
--- a/goffice/graph/goffice-graph.h
+++ b/goffice/graph/goffice-graph.h
@@ -225,14 +225,6 @@ typedef enum {
 #define GOG_POSITION_IS_SPECIAL(pos) (((pos) & GOG_POSITION_SPECIAL)&&(!((pos) & GOG_POSITION_MANUAL)))
 #define GOG_POSITION_IS_PADDING(pos) (((pos) & GOG_POSITION_PADDING)&&(!((pos) & GOG_POSITION_MANUAL)))
 
-/* #define NO_DEBUG_CHARTS */
-#ifndef NO_DEBUG_CHARTS
-#define gog_debug(level, code)	do { if (goffice_graph_debug_level > level) { code } } while (0)
-#else
-#define gog_debug(level, code)
-#endif
-extern int goffice_graph_debug_level;
-
 G_END_DECLS
 
 #include <goffice/goffice.h>
diff --git a/goffice/graph/gog-axis.c b/goffice/graph/gog-axis.c
index dd4568e..04d5f53 100644
--- a/goffice/graph/gog-axis.c
+++ b/goffice/graph/gog-axis.c
@@ -21,6 +21,7 @@
 
 #include <goffice/goffice-config.h>
 #include <goffice/goffice.h>
+#include <goffice/goffice-debug.h>
 #include "gog-axis-line-impl.h"
 
 #include <gsf/gsf-impl-utils.h>
diff --git a/goffice/graph/gog-object.c b/goffice/graph/gog-object.c
index df7dd31..29c61fd 100644
--- a/goffice/graph/gog-object.c
+++ b/goffice/graph/gog-object.c
@@ -21,6 +21,7 @@
 
 #include <goffice/goffice-config.h>
 #include <goffice/goffice.h>
+#include <goffice/goffice-debug.h>
 
 #include <gsf/gsf-impl-utils.h>
 #include <glib/gi18n-lib.h>
diff --git a/goffice/graph/gog-renderer.c b/goffice/graph/gog-renderer.c
index c9bb0d6..80de568 100644
--- a/goffice/graph/gog-renderer.c
+++ b/goffice/graph/gog-renderer.c
@@ -19,6 +19,7 @@
  * USA
  */
 #include <goffice/goffice-config.h>
+#include <goffice/goffice-debug.h>
 #include <goffice/graph/gog-graph.h>
 #include <goffice/graph/gog-graph-impl.h>
 #include <goffice/graph/gog-view.h>
diff --git a/goffice/graph/gog-view.c b/goffice/graph/gog-view.c
index 0c13a61..e4f8264 100644
--- a/goffice/graph/gog-view.c
+++ b/goffice/graph/gog-view.c
@@ -21,6 +21,7 @@
 
 #include <goffice/goffice-config.h>
 #include <goffice/goffice.h>
+#include <goffice/goffice-debug.h>
 
 #include <gsf/gsf-impl-utils.h>
 #include <glib/gi18n-lib.h>



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]