[Glade-users] Problem of linking gtk-demo images.c program
Damon Chaplin
damon@karuna.uklinux.net
Mon, 10 Jan 2005 13:38:13 +0000
Oops, I forgot that the new stable 2.6 versions of GTK+ and GLib are
available. So you could get those, if the packages for Windows are
ready.
Damon
On Mon, 2005-01-10 at 13:06, Cui, Fanzhe wrote:
> Damon,
>
> Appreciate your response. The glib I was using was in the package
> GTK+/Win32 dev env Installer 2.4-rc25, and I think the version was glib
> 2.4.8. The images.c source code was in the directory
> C:\GTK\share\gtk-2.0\demo after installation. I also modified the source
> program main.c and demos.h to exclude other part of the demo (because it
> calls a bunch of other programs that I didn't need). These two files
> plus demo-common.h are from the source pkg of gtk+2.6 that was
> separately downloaded from http://www.gtk.org/download/.
>
> I will try GTK+2.4.9 to find out how the demo use g_fopen(), while I
> wait the release of glib 2.5.4.
>
> Thank you!
> Fanz
>
>
> -----Original Message-----
> From: Damon Chaplin [mailto:damon@karuna.uklinux.net]
> Sent: Monday, January 10, 2005 6:42 AM
> To: Cui, Fanzhe
> Cc: glade-users@lists.ximian.com
> Subject: RE: [Glade-users] Problem of linking gtk-demo images.c program
>
>
> g_fopen() was only added to GLib recently. It is in GLib 2.5.4, which is
> a beta release, not a stable release.
>
> Where did you get the demo program from? Download an older stable
> version of GTK+, e.g. 2.4.9, and try the demo from there.
>
> Damon
>
>
> On Mon, 2005-01-10 at 01:23, Cui, Fanzhe wrote:
> > Regarding my question in previous email, I think the glib library file
> > should include g_fopen() function. In my project, I included
> > glib-2.0.lib, which came with installation of glib2.4.8, but I don't
> > know why the linkage complains that g_fopen() not resolved. I wonder
> > if anybody in the email list has seen the same problem or knew what
> > was wrong with it?
> >
> > Regards,
> > Fanzhe
> >
> > ______________________________________________________________________
> > From: glade-users-admin@lists.ximian.com
> > [mailto:glade-users-admin@lists.ximian.com] On Behalf Of Cui, Fanzhe
> > Sent: Sunday, January 09, 2005 7:14 PM
> > To: glade-users@lists.ximian.com
> > Subject: [Glade-users] Problem of linking gtk-demo images.c program
> >
> >
> > Hi,
> >
> > I am new to gtk+, and glade, and I had a problem trying to link the
> > images.c demo which comes with gtk-demo. If somebody can help me out,
> > it would be appreciated.
> >
> > I downloaded the latest windows port of glage with gdk+ from:
> > http://gladewin32.sourceforge.net/, and I was able to run the
> > gtk-demo. I was also able to compile and link some other glade2 demos
> > with MS VC++ 7.
> >
> > The problem was when I was trying to make a little more complicated
> > testing program by modifying images.c in C:\GTK\share\gtk-2.0\demo
> > directory, which is part of gtk-demo program.
> >
> > When I build the project by linking the program, I got:
> > Linking...
> > main.obj : error LNK2019: unresolved external symbol _g_fopen
> > referenced in function _load_file
> > .\/gtk-demo_images.exe : fatal error LNK1120: 1 unresolved externals
> >
> > The problem is that the program calls g_fopen() function which is in
> > the in the library that I included. I searched the library and it
> > should be in one of glib library. I am not sure that the problem
> > caused by using windows port of the gtk+ pkg. Anybody has seen such
> > problem or have any idea about how to resolve this problem. Thank you!
> >
> > Best Regards,
> > Fanzhe Cui
> > Intel America's, Inc
>