Build failure: gtk-sharp-2 (Bug #407)
Description
/usr/include/glib-2.0/glib/glist.h:28:2: error: #error "Only <glib.h> can be included directly."
In file included from /usr/include/glib-2.0/glib/glist.h:34:0,
from list.c:23:
/usr/include/glib-2.0/glib/gmem.h:28:2: error: #error "Only <glib.h> can be included directly."
In file included from /usr/include/glib-2.0/glib/gmem.h:34:0,
from /usr/include/glib-2.0/glib/glist.h:34,
from list.c:23:
/usr/include/glib-2.0/glib/gtypes.h:28:2: error: #error "Only <glib.h> can be included directly."
In file included from /usr/lib/glib-2.0/include/glibconfig.h:9:0,
from /usr/include/glib-2.0/glib/gtypes.h:34,
from /usr/include/glib-2.0/glib/gmem.h:34,
from /usr/include/glib-2.0/glib/glist.h:34,
from list.c:23:
/usr/include/glib-2.0/glib/gmacros.h:32:2: error: #error "Only <glib.h> can be included directly."
In file included from /usr/include/glib-2.0/glib/gtypes.h:35:0,
from /usr/include/glib-2.0/glib/gmem.h:34,
from /usr/include/glib-2.0/glib/glist.h:34,
from list.c:23:
/usr/include/glib-2.0/glib/gmacros.h:32:2: error: #error "Only <glib.h> can be included directly."
In file included from /usr/include/glib-2.0/glib/gtypes.h:36:0,
from /usr/include/glib-2.0/glib/gmem.h:34,
from /usr/include/glib-2.0/glib/glist.h:34,
from list.c:23:
/usr/include/glib-2.0/glib/gversionmacros.h:28:2: error: #error "Only <glib.h> can be included directly."
In file included from /usr/include/glib-2.0/glib/glist.h:35:0,
from list.c:23:
/usr/include/glib-2.0/glib/gnode.h:28:2: error: #error "Only <glib.h> can be included directly."
In file included from /usr/include/glib-2.0/glib/gnode.h:34:0,
from /usr/include/glib-2.0/glib/glist.h:35,
from list.c:23:
/usr/include/glib-2.0/glib/gmem.h:28:2: error: #error "Only <glib.h> can be included directly."
make3: make3: Leaving directory `/usr/src/gtk-sharp-2.12.10/glib/glue'
- [list.lo] Error 1
make2: * [all-recursive] Error 1
make2: Leaving directory `/usr/src/gtk-sharp-2.12.10/glib'
make1: [all-recursive] Error 1
make1: Leaving directory `/usr/src/gtk-sharp-2.12.10'
make: ** [all] Error 2
! Problem Detected !
Creating compile log /var/log/sorcery/compile/gtk-sharp-2-2.12.10.bz2
Creating castfs debug log /var/log/sorcery/compile/gtk-sharp-2-2.12.10.castfs.dbglog.bz2
Spells that encountered problems:
---------------------------------
gtk-sharp-2 (build)
This is related to the upstream (glib2) change that forbids the inclusion of any headers other than glib.h.
root@smgl64-lappy:~# gaze versions glib2
Grimoire Section Spell Grimoire Version Installed Version
-------- ------- ----- ---------------- -----------------
grimoire gnome2-libs glib2 2.33.3 2.33.3
test gnome2-libs glib2 2.32.3 -
Also occurs with glib versions 2.32.2 (stable) and 2.32.3 (test) and both versions of gtk# listed below.
root@smgl64-lappy:~# gaze versions gtk-sharp-2
Grimoire Section Spell Grimoire Version Installed Version
-------- ------- ----- ---------------- -----------------
grimoire x11-toolkits gtk-sharp-2 2.12.11 -
test x11-toolkits gtk-sharp-2 2.12.10 -
Upstream has committed fix files, but not released them yet. I will pull them and generate patches this weekend.
Related issues
| blocks Grimoire - Bug #424: [stable 0-61.3 cast failures] Master Bug | New | 08/05/2012 |
Associated revisions
gtk-sharp-2: issue #407 - fix build with glib2 >= 2.31
gtk-sharp-2: issue #407 - fix build with glib2 >= 2.31
(cherry picked from commit c62bc1b8f616f66c2506bcd9ccf0285724b15495)
History
Updated by Tommy Boatman 11 months ago
Managed to get this working through almost a full rewrite, pulling a couple of build files from the dev repository, and creating a patch to alter a couple of source files (configure.in and glib/Thread.cs). The configure process now checks for glib2 >= 2.31 and reacts accordingly. gnome-sharp, monodevelop, and friends acknowledge its existence and can compile against it.
I'm attaching a zip file of the spell to this bug for feedback before I commit and push the change because of how extensive they are. I would appreciate feedback, and if you can do better, I challenge you to do so.
- Estimated time set to 10.00
- % Done changed from 0 to 90
- Status changed from New to Feedback
- File gtk-sharp-2.zip added
Updated by Sukneet Basuta 11 months ago
It works for me, but so does simply updating it to 2.12.11 and applying glib_fix.patch before libtoolize. Is bootstrapping really needed?
Updated by Tommy Boatman 11 months ago
Thanks Sunkeet. I was not able to get it to work without bootstrapping, which probably means I applied the patch at the wrong time. I'll commit the spell with the patch before libtoolize, provided I can duplicate the success.
Updated by Tommy Boatman 11 months ago
Fixed with commit c62bc1b8f616f66c2506bcd9ccf0285724b15495
Requesting stable integration
- % Done changed from 90 to 100
- Status changed from Feedback to Resolved
Updated by Vlad Glagolev 9 months ago
checked in current stable (0.61-5), cups 1.5.4 + pycups 1.9.60. compiles fine.
closing the bug.
- Status changed from Resolved to Closed