source: trunk/third/gtk2/README.win32 @ 18162

Revision 18162, 4.0 KB checked in by ghudson, 22 years ago (diff)
This commit was generated by cvs2svn to compensate for changes in r18161, which included commits to RCS files with non-trunk default branches.
Line 
1The Win32 port of GTK+ is a work in progress, and not as stable or
2correct as the Unix/X11 version. For more information about the Win32
3port, and prebuilt runtime and developer packages see
4http://www.gimp.org/win32/ .
5
6There is a gtk-1-3-win32-production branch of GTK+ that was branched
7off from before the addition of the no-flicker and other recent
8functionality. That is what should be used by "production" code until
9this CVS HEAD (2.0) version is useable. (But note, the Win32 backend
10has never been claimed to be "production quality", although it works
11surprisingly well for the GIMP.)
12
13Building GTK+ on Win32
14======================
15
16There are two ways to build GTK+ for win32:
17
181) Use the autoconf-generated configure script, and the resulting
19Makefiles (which use libtool and gcc to do the compilation). I use
20this myself, but it might be hell to setup correctly.
21
22Personally I run configure with:
23CC='gcc -mpentium -fnative-struct' CPPFLAGS='-I/target/include' CFLAGS=-O2 LDFLAGS='-L/target/lib' ./configure --disable-static --prefix=/target --with-gdktarget=win32 --with-wintab=/src/wtkit126 --with-ie55=/src/workshop/ie55_lib --host=i386-pc-mingw32 --enable-maintainer-mode
24
25It might well be that in order for this to work, you will have to get
26a bleeding-edge version of libtool for Win32, run libtoolize yourself,
27and then run autoconf to generate the configure script.
28
292) Use the Microsoft compiler, cl and Make, nmake. Say nmake -f
30makefile.msc in gdk and gtk.
31
32Alternative 1 also generates Microsoft import libraries (.lib), if you
33have lib.exe available. It might also work for cross-compilation from
34Unix.
35
36There are hand-written makefiles for mingw (look for makefile.mingw in
37various directories), but those haven't been kept up-to-date, and
38probably won't work without editing. Sorry. If you make them work
39again, by all means do submit patches.
40
41Note that I use method 1 myself. Hans Breuer has been taking care of
42the MSVC makefiles. At times, we disagree a bit about various issues,
43and the makefile.msc files might not produce identically named DLLs
44and import libraries as the "autoconfiscated" makefiles and libtool
45do.
46
47Using GTK+ on Win32
48===================
49
50To use GTK+ on Win32, you also need either one of the above mentioned
51compilers. Other compilers might work, but don't count on it. Look for
52prebuilt developer packages (DLLs, import libraries, headers) on the
53above website.
54
55Multi-threaded use of GTK+ on Win32
56===================================
57
58Multi-threaded GTK+ programs might work in special simple cases, but
59not in general. Sorry. If you have all GTK+ and GDK calls in the same
60thread, it might work. Otherwise, probably not at all. Possible ways
61to fix this are being investigated.
62
63Wintab
64======
65
66The tablet support uses the Wintab API. The Wintab development kit can
67be downloaded from http://www.pointing.com. Pass the --with-wintab
68flag to configure if you use that. If you use nmake and you don't care
69for Wintab, undefine HAVE_WINTAB in config.h.win32 and remove
70references to the wntab32x library from the makefile before building.
71
72Libintl
73=======
74
75GTK wants to be built with the GNU "intl" library for
76internationalisation (i18n). Get the version ported to Win32 (not a
77very big deal) from the web site mentioned above. The "intl" library
78as gets built as a DLL called libintl-1.dll. If you don't want any
79i18n stuff, undefine ENABLE_NLS, HAVE_GETTEXT and HAVE_LIBINTL in the
80config.h.win32 file, and remove references to the intl library from
81the makefiles.
82
83ActiveIMM
84=========
85
86If you want to build a GTK+ that supports ActiveIMM (the Input Method
87Manager for non-EastAsia locales that can be used on Win9x/NT4), you
88need the dimm.h header file. That is somewhat difficult to find, but
89http://msdn.microsoft.com/downloads/samples/internet/wizard/ seems to
90be a good place to look nowadays. If you use "autoconfiscated" build,
91pass the --with-ie55 flag to configure specifyin the location of the
92ie55_lib directory created by downloading the IE5.5 headers and libs
93from the above URL.
94
95--Tor Lillqvist <tml@iki.fi>
Note: See TracBrowser for help on using the repository browser.