John Stebbins wrote: > Tor Lillqvist wrote: >> (Adding gtk-app-devel-list back as Cc. Please let's keep this >> discussion on the list.) >> > Oops, didn't notice that reply went direct to you instead of to the list. >> Why make it harder for yourself, why not use a shared library (dll) >> build of gtk+ like everyone else? >> >> --tml >> > Short answer, I don't know what I'm doing ;-) . > I saw that cross development environment announced on freshmeat, and on > a whim I decided to try porting my application to windows. It looked > like a nice self contained set of tools that could get me there. I > didn't explicitly ask for it to build static. From the package's > "feature" list, "creates libraries to be linked statically, no DLL hell".
The last time I build a cross-compiler from scratch and build the GTK stack for it, it created all dlls. I guess that was my own setup though. I use only Tor's official zip files if I do that now. As far as I know, GTK simply cannot run statically linked, especially on win32. Basically all kinds of paths are keyed off of the main gtk dll's path. In other words, if you put the gtk dll in a folder named bin, it will automatically check in ../etc/ for stuff like the gtkrc file, ../lib/gtk-2.0 for things like theme engines. This makes it easy to bundle the runtime up with your EXE on windows. In short, GTK just isn't designed to be a statically-build system. Additionally if you did so, your resulting executable has to be licensed to users under the terms of the LGPL, something that is not always desirable. It's not hard to add the official gtk win32 binaries, libraries, and include files to your cross-compiler's environment. On my machine I have /opt/mingw/i386-pc-mingw32 and inside there are bin, include, and lib directories. I just unzip the zip files inside that folder, and things normally go into the right places. The only catch is dealing with pkg-config. you have to set the PKG_CONFIG_PATH variable to point to /opt/mingw/i386-pc-mingw32/lib/pkgconfig, but also you ahve to modify all the .pc files for GTK to have the linux paths on your machine (paths to the mingw areas). _______________________________________________ gtk-app-devel-list mailing list gtk-app-devel-list@gnome.org http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list