Comment 5 for bug 1923642

Revision history for this message
In , Thomas Klausner (tk-giga) wrote :

There is a breaking change in glib 2.68.0:

https://bugzilla.redhat.com/show_bug.cgi?id=1926239
https://gitlab.gnome.org/GNOME/glib/-/merge_requests/1935#note_1034039

In short, the glib headers cannot be included in ``extern "C"'' any longer.

This breaks gnucash 4.4 and 4.5. A lot of error output, looking basically like this:

In file included from /usr/pkg/include/glib-2.0/glib/gatomic.h:31,
                 from /usr/pkg/include/glib-2.0/glib/gthread.h:32,
                 from /usr/pkg/include/glib-2.0/glib/gasyncqueue.h:32,
                 from /usr/pkg/include/glib-2.0/glib.h:32,
                 from /scratch/finance/gnucash/work/gnucash-4.5/libgnucash/engine/SchedXaction.h:42,
                 from /scratch/finance/gnucash/work/gnucash-4.5/gnucash/gnome/assistant-loan.cpp:33:
/usr/include/g++/type_traits:3024:3: error: template with C linkage
 3024 | template<typename _Tp>
      | ^~~~~~~~
/scratch/finance/gnucash/work/gnucash-4.5/gnucash/gnome/assistant-loan.cpp:26:1: note: 'extern "C"' linkage started here
   26 | extern "C"
      | ^~~~~~~~~~

The glib includes are sometimes in other includes - here in SchedXAction.h, so it's not easy to see what needs to be moved.