Re: GTK+ for Windows
- From: Tor Lillqvist <tml iki fi>
- To: "Cheng, Kevin " <kc40 hw ac uk>
- Cc: gtk-list gnome org
- Subject: Re: GTK+ for Windows
- Date: Sun, 19 Jun 2005 04:24:03 +0300
Cheng, Kevin writes:
> I was wondering if you know of, or already have any GTK already
> compiled lib files?
The GTK+ 2.6.8 developer package for Windows available at
ftp://ftp.gtk.org/pub/gtk/v2.6/win32/gtk+-dev-2.6.8.zip contains
import libraries for Microsoft's tools (.lib files). As the .lib files
are import libraries, they don't contain any compiled code as
such. (The actual code is in the corresponding DLLs.) Hopefully you
aren't actually asking for statically built libraries? That's futile.
Even if there wasn't any .lib files provided, it would be trivial to
build such yourself when you have the DLL, and know that the calling
convention is the normal for C code, cdecl. (I.e. no stdcall crap.)
Just use Microsoft's link.exe and lib.exe:
link -dump -exports libgtk-win32-2.0-0.dll >gtk-win32-2.0.def
edit the listing into a proper .def file, it should look like this:
EXPORTS
gtk_show_about_dialog
gtk_about_dialog_get_artists
gtk_about_dialog_get_authors
...
and then run:
lib -name:libgtk-win32-2.0-0.dll -def:gtk-win32-2.0.def -out:gtk-win32-2.0.lib
Isn't this documented in the documentation for the Microsoft tools you
hopefully got when you bought them?
(The fact that the DLLs are built with GNU tools (gcc and binutils) is
irrelevant. C code built with gcc is binary compatible with code built
with Microsoft tools. I built the .lib files using the "freely"
downloadable Visual C++ Express Edition 2005 Beta 2 (or whatever its
exact name is).)
--tml
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]