On Fri, 2008-12-19 at 10:57 +0800, Jedy Wang wrote:
> Please try full file patch in glade_xml_new.
Sorry, I mean full path.
Regards,
Jedy
>
> Regards,
>
> Jedy
> On Wed, 2008-12-17 at 15:49 -0800, yantux wrote:
> > yan at myopensolaris:~/GladeProjects$ uname -a
> > SunOS myopensolaris 5.11 snv_101b i86pc i386 i86pc Solaris
> >
> >
> > Makefile:
> > GCC=gcc
> > INCLUDE1=-I/usr/include/gtk-2.0/
> > INCLUDE2=-I/usr/include/libglade-2.0
> > INCLUDE3=-I/usr/include/glib-2.0
> > INCLUDE4=-I/usr/lib/glib-2.0/include
> > INCLUDE5=-I/usr/include/cairo
> > INCLUDE6=-I/usr/include/pango-1.0
> > INCLUDE7=-I/usr/lib/gtk-2.0/include
> > INCLUDE8=-I/usr/include/atk-1.0
> > PATHLIB1=-L/usr/lib
> > LIBS1=-lgtk -lglade-2.0 -lgdk
> >
> > SRC=test_glade_1.c
> > FLAGS1=$(INCLUDE1) $(INCLUDE2) $(INCLUDE3) $(INCLUDE4) $(INCLUDE5)
> > $(INCLUDE6) $(INCLUDE7)
> > FLAGS2=$(INCLUDE8)
> > FLAGS3=$(PATHLIB1) $(LIBS1)
> > #--export-dynamic
> >
> > all:
> > $(GCC) $(FLAGS1) $(FLAGS2) $(FLAGS3) $(SRC) -o run
> >
> >
> >
> > test_glade_1.c:
> > #include <gtk/gtk.h>
> > #include <glade/glade.h>
> >
> > void
> > some_handler(GtkWidget *widget)
> > {
> > /* a handler referenced by the glade file. Must not be static
> > * so that it appears in the global symbol table. */
> > }
> >
> > int
> > main(int argc, char **argv)
> > {
> > GladeXML *xml;
> > GtkWidget *widget;
> >
> > gtk_init(&argc, &argv);
> > xml = glade_xml_new("test_1.glade", NULL, NULL);
> > printf("glade_xml_new=%p\n", xml );
> >
> > /* get a widget (useful if you want to change something) */
> > widget = glade_xml_get_widget(xml, "widgetname");
> >
> > /* connect signal handlers */
> > glade_xml_signal_autoconnect(xml);
> >
> > gtk_main();
> >
> > return 0;
> > }
> >
> >
> >
> > yan at myopensolaris:~/GladeProjects$ ./run
> >
> > (process:909): GLib-GObject-CRITICAL **: gtype.c:2458: initialization
> > assertion failed, use g_type_init() prior to this function
> >
> > (process:909): GLib-GObject-CRITICAL **: file gobject.c: line 1053:
> > assertion `G_TYPE_IS_OBJECT (object_type)' failed
> >
> > (process:909): libglade-CRITICAL **: file glade-xml.c: line 179: assertion
> > `self != NULL' failed
> >
> > (process:909): GLib-GObject-CRITICAL **: file gobject.c: line 2366:
> > assertion `G_IS_OBJECT (object)' failed
> > glade_xml_new=0
> >
> > (process:909): libglade-CRITICAL **: file glade-xml.c: line 549: assertion
> > `self != NULL' failed
> >
> > (process:909): libglade-CRITICAL **: file glade-xml.c: line 365: assertion
> > `self != NULL' failed
> >
> >
> > Why it is? How I can solve this problem?
>
> _______________________________________________
> desktop-discuss mailing list
> desktop-discuss at opensolaris.org