Comment 30 for bug 367607

Revision history for this message
su_v (suv-lp) wrote : Re: Remove deprecated GTK+ symbols

With GTK_DISABLE_DEPRECATED, build fails if configured with '--enable-dbusapi':

  CXX extension/dbus/document-interface.o
In file included from ../../src/ui/dialog/ocaldialogs.h:17,
                 from ../../src/file.h:19,
                 from ../../src/extension/dbus/document-interface.cpp:29:
/opt/local/include/gtkmm-2.4/gtkmm/box.h:105: error: expected class-name before ‘{’ token
/opt/local/include/gtkmm-2.4/gtkmm/box.h:112: error: ISO C++ forbids declaration of ‘_GtkBoxChild’ with no type
/opt/local/include/gtkmm-2.4/gtkmm/box.h:112: error: ‘_GtkBoxChild’ declared as an ‘inline’ field
/opt/local/include/gtkmm-2.4/gtkmm/box.h:112: error: expected ‘;’ before ‘*’ token
/opt/local/include/gtkmm-2.4/gtkmm/box.h:114: error: expected `;' before ‘inline’
/opt/local/include/gtkmm-2.4/gtkmm/box.h:114: error: ISO C++ forbids declaration of ‘_GtkBoxChild’ with no type
/opt/local/include/gtkmm-2.4/gtkmm/box.h:114: error: ‘_GtkBoxChild’ declared as an ‘inline’ field
/opt/local/include/gtkmm-2.4/gtkmm/box.h:114: error: expected ‘;’ before ‘*’ token
/opt/local/include/gtkmm-2.4/gtkmm/box.h:116: error: expected `;' before ‘Widget’
/opt/local/include/gtkmm-2.4/gtkmm/box.h: In member function ‘guint16 Gtk::Box_Helpers::Child::get_padding() const’:
/opt/local/include/gtkmm-2.4/gtkmm/box.h:118: error: ‘gobj’ was not declared in this scope
/opt/local/include/gtkmm-2.4/gtkmm/box.h: In member function ‘bool Gtk::Box_Helpers::Child::get_expand() const’:
/opt/local/include/gtkmm-2.4/gtkmm/box.h:119: error: ‘gobj’ was not declared in this scope
/opt/local/include/gtkmm-2.4/gtkmm/box.h: In member function ‘bool Gtk::Box_Helpers::Child::get_fill() const’:
/opt/local/include/gtkmm-2.4/gtkmm/box.h:120: error: ‘gobj’ was not declared in this scope
/opt/local/include/gtkmm-2.4/gtkmm/box.h: In member function ‘bool Gtk::Box_Helpers::Child::get_pack() const’:
/opt/local/include/gtkmm-2.4/gtkmm/box.h:121: error: ‘gobj’ was not declared in this scope
/opt/local/include/gtkmm-2.4/gtkmm/box.h: In member function ‘GtkBox* Gtk::Box_Helpers::Child::parent()’:
/opt/local/include/gtkmm-2.4/gtkmm/box.h:130: error: ‘gobj’ was not declared in this scope
make[3]: *** [extension/dbus/document-interface.o] Error 1
make[2]: *** [all] Error 2
make[1]: *** [all-recursive] Error 1
make: *** [all] Error 2

With this change to configure.ac (reverting r11222), build succeeds:

$ bzr diff configure.ac
=== modified file 'configure.ac'
--- configure.ac 2012-04-11 15:17:53 +0000
+++ configure.ac 2012-04-14 01:00:47 +0000
@@ -60,7 +60,7 @@
   CPPFLAGS="-DG_DISABLE_DEPRECATED $CPPFLAGS"
   CPPFLAGS="-DGTK_DISABLE_SINGLE_INCLUDES $CPPFLAGS"
   CPPFLAGS="-DGTKMM_DISABLE_DEPRECATED $CPPFLAGS"
- CPPFLAGS="-DGTK_DISABLE_DEPRECATED $CPPFLAGS"
+ #CPPFLAGS="-DGTK_DISABLE_DEPRECATED $CPPFLAGS"
   CPPFLAGS="-DGDKMM_DISABLE_DEPRECATED $CPPFLAGS"

   # Test for -Werror=... (introduced some time post-4.0)

$