After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 770682 - gtkmm 2.24.x no longer builds with glibmm 2.49.x
gtkmm 2.24.x no longer builds with glibmm 2.49.x
Status: RESOLVED FIXED
Product: gtkmm
Classification: Bindings
Component: build
2.24.x
Other Linux
: Normal normal
: ---
Assigned To: gtkmm-forge
gtkmm-forge
Depends on:
Blocks:
 
 
Reported: 2016-08-31 21:52 UTC by Dominique Leuenberger
Modified: 2016-09-04 18:00 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description Dominique Leuenberger 2016-08-31 21:52:26 UTC
Similar to what was discussed in the gnote bug 770541 - and even though we all with gtkmm 2.24 would no longer be needed, reality is different (just as gtk2 is still around)

An up-to-date build log can be found at https://build.opensuse.org/package/live_build_log/GNOME:Next/gtkmm2/openSUSE_Factory/x86_64

[  206s] In file included from /usr/lib64/glib-2.0/include/glibconfig.h:9:0,
[  206s]                  from /usr/include/glib-2.0/glib/gtypes.h:32,
[  206s]                  from /usr/include/glib-2.0/glib/galloca.h:32,
[  206s]                  from /usr/include/glib-2.0/glib.h:30,
[  206s]                  from /usr/include/glibmm-2.4/glibmm/thread.h:39,
[  206s]                  from /usr/include/glibmm-2.4/glibmm.h:89,
[  206s]                  from ../gtkmm/menushell.h:7,
[  206s]                  from menushell.cc:8:
[  206s] menushell.cc: In member function 'Glib::HelperList<Gtk::MenuItem, const Gtk::Menu_Helpers::Element, Glib::List_Cpp_Iterator<_GtkMenuItem, Gtk::MenuItem> >::iterator Gtk::Menu_Helpers::MenuList::insert(Glib::HelperList<Gtk::MenuItem, const Gtk::Menu_Helpers::Element, Glib::List_Cpp_Iterator<_GtkMenuItem, Gtk::MenuItem> >::iterator, const Gtk::Menu_Helpers::Element&)':
[  206s] menushell.cc:133:29: error: no match for 'operator!=' (operand types are 'const Glib::RefPtr<Gtk::MenuItem>' and 'int')
[  206s]    g_return_val_if_fail(item != 0, position);
Comment 1 Kjell Ahlstedt 2016-09-01 18:18:25 UTC
menushell.ccg was changed 2016-05-25 in the gtkmm-2-24 branch in git.gnome.org.
  g_return_val_if_fail(item != 0, position);
is now
  g_return_val_if_fail(!!item, position);

Perhaps it's time to release a new version of gtkmm 2.

If code is generated with a new version of glibmm, and thus a new version of
gmmproc, then the generated code would require a C++11 compiler. Some users of
gtkmm 2 would not like that. I think that if code is generated with an old
enough version of gmmproc, it can then be used either with a new version of
glibmm and a C++11 compiler, or an old version of glibmm and a compiler without
C++11 support.
Comment 2 Murray Cumming 2016-09-01 18:34:20 UTC
Sure. Feel free to release a new gtkmm-2.24 built with an older glibmm, please.

Can we avoid that !! in the code? It does look rather odd.
Comment 3 Kjell Ahlstedt 2016-09-04 18:00:51 UTC
  g_return_val_if_fail(!!item, position);
has been replaced by
  g_return_val_if_fail(static_cast<bool>(item), position);

I have released gtkmm 2.24.5. It can be built and used together with the latest
versions of glibmm.

I generated code with glibmm (gmmproc) 2.45.3 + a patch from glibmm 2.45.31,
9c5e30622e38974e909fef60ea045d08000e33a0
gmmproc: _WRAP_SIGNAL: Accept apostrophes in a preceding comment

I did not try to build without C++11 support. It would have required more
changes in my build environment than I wanted to do. The code looks free of
C++11 stuff (e.g. no noexcept, no move operations).