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 605108 - GLib-2.0.gir parse error with sun cc
GLib-2.0.gir parse error with sun cc
Status: RESOLVED FIXED
Product: gobject-introspection
Classification: Platform
Component: general
unspecified
Other Solaris
: Urgent major
: ---
Assigned To: gobject-introspection Maintainer(s)
gobject-introspection Maintainer(s)
Depends on:
Blocks:
 
 
Reported: 2009-12-21 06:14 UTC by Halton Huo
Modified: 2015-02-07 16:47 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
diff file of gir/GObject-2.0.gir compared on Linux and OpenSolaris. (2.48 KB, text/plain)
2009-12-23 03:34 UTC, Halton Huo
  Details
Add -DGLIB_COMPILATION (805 bytes, patch)
2009-12-23 08:42 UTC, Halton Huo
committed Details | Review

Description Halton Huo 2009-12-21 06:14:00 UTC
$make
../tools/g-ir-compiler --includedir=. --includedir=../gir --includedir=../gir --includedir=. GObject-2.0.gir -o GObject-2.0.typelib

** WARNING **: Entry 'GSList' not found
aborting...
make: *** [GObject-2.0.typelib] Abort (core dumped)
$pstack core
core 'core' of 28080:   /export/home/halton/work/projects/gnome/gobject-introspection/gobject-
 fec54667 _lwp_kill (1, 6, 80470b8, febfbb4e) + 7
 febfbb5a raise    (6, 0, 8047108, febd254a) + 22
 febd256a abort    (0, 10, fee07938, fee0793c, fee1d4d4, fee1d500) + f2
 fed7ccb8 g_logv   (0, 10, 8065f9c, 80475bc) + 4a8
 fed7cd61 g_log    (0, 10, 8065f9c, 80c67f0, 0, 0) + 25
 08058b9c find_entry_node (81663d0, 82046c0, 80c67f0, 0, 0, 0) + 26c
 080590fd serialize_type (81663d0, 82046c0, 80cc000, 808ff30, 0, 0) + 1ad
 080597a0 g_ir_node_build_typelib (80cc000, 80cbb60, 804789c, 80478d8, 80478d4, 0) + 290
 08059f3a g_ir_node_build_typelib (80cbb60, 80c1e98, 804789c, 80478d8, 80478d4, 0) + a2a
 08059489 g_ir_node_build_members (8047830, 12, 80819e0, 80c1e98, 804789c, 80478d8) + 79
 0805afc3 g_ir_node_build_typelib (80c1e98, 0, 804789c, 80478d8, 80478d4, 0) + 1ab3
 08055fa7 g_ir_module_build_typelib (81663d0, 82046c0) + 797
 08054f86 main     (1, 8047974, 8047998, 805449f) + 316
 080544fd _start   (8, 8047a84, 0, 0, 0, 0) + 7d
Comment 1 Halton Huo 2009-12-23 03:34:01 UTC
Created attachment 150270 [details]
diff file of gir/GObject-2.0.gir compared on Linux and OpenSolaris.

There is no this error when building on Linux. I found the gir/GObject-2.0.gir are different, attach here for reference.
Comment 2 Halton Huo 2009-12-23 08:17:02 UTC
I found the root cause is SourceScanner:_parse /usr/include/glib-2.0/glib/ghostutils.h, cc generate a error and stop parsing rest headers.

$env LPATH=.libs  env PYTHONPATH=..:..:PYTHONPATH UNINSTALLED_INTROSPECTION_SRCDIR=.. UNINSTALLED_INTROSPECTION_BUILDDIR=.. ../tools/g-ir-scanner -v --add-include-path=../gir --add-include-path=. -v --add-include-path=../gir --add-include-path=. --namespace=GLib --nsversion=2.0 --libtool="/bin/bash ../libtool"  --library=glib-2.0 --pkg=glib-2.0  --noclosure --strip-prefix=g --c-include="glib.h"  -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -DGETTEXT_PACKAGE=Dummy -D__G_I18N_LIB_H__ /usr/lib/glib-2.0/include/glibconfig.h /usr/include/glib-2.0/glib/*.h ./glib-2.0.c --output GLib-2.0.gir
"<stdin>", line 5: warning: #include of /usr/include/... may be non-portable
"<stdin>", line 6: warning: #include of /usr/include/... may be non-portable
"<stdin>", line 7: warning: #include of /usr/include/... may be non-portable
"<stdin>", line 8: warning: #include of /usr/include/... may be non-portable
"<stdin>", line 9: warning: #include of /usr/include/... may be non-portable
"<stdin>", line 10: warning: #include of /usr/include/... may be non-portable
"<stdin>", line 11: warning: #include of /usr/include/... may be non-portable
"<stdin>", line 12: warning: #include of /usr/include/... may be non-portable
"<stdin>", line 13: warning: #include of /usr/include/... may be non-portable
"<stdin>", line 14: warning: #include of /usr/include/... may be non-portable
"<stdin>", line 15: warning: #include of /usr/include/... may be non-portable
"<stdin>", line 16: warning: #include of /usr/include/... may be non-portable
"<stdin>", line 17: warning: #include of /usr/include/... may be non-portable
"<stdin>", line 18: warning: #include of /usr/include/... may be non-portable
"<stdin>", line 19: warning: #include of /usr/include/... may be non-portable
"<stdin>", line 20: warning: #include of /usr/include/... may be non-portable
"<stdin>", line 21: warning: #include of /usr/include/... may be non-portable
"<stdin>", line 22: warning: #include of /usr/include/... may be non-portable
"<stdin>", line 23: warning: #include of /usr/include/... may be non-portable
"/usr/include/glib-2.0/glib/ghostutils.h", line 21: #error: "Only <glib.h> can be included directly."
cc: acomp failed for -
Comment 3 Halton Huo 2009-12-23 08:42:09 UTC
Created attachment 150280 [details] [review]
Add -DGLIB_COMPILATION

Adding -DGLIB_COMPILATION for GLib-2.0.gir could fix this bug.
Comment 4 Johan (not receiving bugmail) Dahlin 2009-12-23 11:37:31 UTC
Review of attachment 150280 [details] [review]:

Please commit this right away.
Comment 6 André Klapper 2015-02-07 16:47:46 UTC
[Mass-moving gobject-introspection tickets to its own Bugzilla product - see bug 708029. Mass-filter your bugmail for this message: introspection20150207 ]