[hipl-commit] [trunk] Rev 4155: #define GTK_STOCK_ORIENTATION_PORTRAIT only in the C file where it is used.

  • From: Diego Biurrun <diego@xxxxxxxxxx>
  • To: hipl-commit@xxxxxxxxxxxxx
  • Date: Wed, 7 Apr 2010 17:37:39 +0300

Committer: Diego Biurrun <diego@xxxxxxxxxx>
Date: 07/04/2010 at 17:37:39
Revision: 4155
Revision-id: diego@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
Branch nick: trunk

Log:
  #define GTK_STOCK_ORIENTATION_PORTRAIT only in the C file where it is used.
  
  This breaks the dependency of the agent code on GTK CPPFLAGS.

Modified:
  M  Makefile.am
  M  lib/gui/events.c
  M  lib/gui/hipgui.h

=== modified file 'Makefile.am'
--- Makefile.am 2010-04-07 13:36:38 +0000
+++ Makefile.am 2010-04-07 14:36:47 +0000
@@ -213,9 +213,6 @@
                           firewall/pisa_cert.c
 endif
 
-# NOTE: gtk does not allow for -Wstrict-prototypes, so we need to append 
AM_CFLAGS
-agent_hipagent_CFLAGS = @GTK_CFLAGS@ -Werror -Wall -Wcast-align 
-Wdisabled-optimization -Wundef -fno-strict-aliasing -funit-at-a-time
-
 agent_hipagent_SOURCES = agent/agent.c          \
                          agent/connhipd.c       \
                          agent/hitdb.c          \

=== modified file 'lib/gui/events.c'
--- lib/gui/events.c    2010-03-18 21:15:21 +0000
+++ lib/gui/events.c    2010-04-07 14:36:47 +0000
@@ -12,6 +12,9 @@
  *
  * @note The documentation may be inaccurate please feel free to fix it -Samu
  */
+
+#include <gtk/gtk.h>
+
 #include "events.h"
 #include "hipgui.h"
 #include "widgets.h"
@@ -22,6 +25,11 @@
 #include "agent/connhipd.h"
 #include "lib/core/debug.h"
 
+#if (GTK_MAJOR_VERSION >= 2) && (GTK_MINOR_VERSION >= 10)
+#else
+#define GTK_STOCK_ORIENTATION_PORTRAIT GTK_STOCK_FILE
+#endif
+
 /**
  * e_delete - Default window close event. This occurs when user presses that 
cross
  *            usually placed in right top corner of windows.

=== modified file 'lib/gui/hipgui.h'
--- lib/gui/hipgui.h    2010-03-29 18:08:51 +0000
+++ lib/gui/hipgui.h    2010-04-07 14:36:47 +0000
@@ -7,14 +7,8 @@
  * Authors: Antti Partanen <aehparta@xxxxxxxxx>
  */
 
-#include <gtk/gtk.h>
 #include "agent/hitdb.h"
 
-#if (GTK_MAJOR_VERSION >= 2) && (GTK_MINOR_VERSION >= 10)
-#else
-#define GTK_STOCK_ORIENTATION_PORTRAIT GTK_STOCK_FILE
-#endif
-
 /*!
  * \addtogroup libhipgui
  * @{

Other related posts:

  • » [hipl-commit] [trunk] Rev 4155: #define GTK_STOCK_ORIENTATION_PORTRAIT only in the C file where it is used. - Diego Biurrun