More Win32 updates. Add missing Win32 files to distributed files.
[platform/upstream/glib.git] / README.win32
1 For more information about the port or GLib, GTk+ and the GIMP to
2 native Windows, see http://www.iki.fi/tml/gimp/win32/ . ("Native"
3 means that we use the Win32 API only, and not any POSIX emulation
4 layer except that provided by the Microsoft runtime C library, and the
5 pthreads emulation library.)
6
7 As for now, only the Microsoft compiler and tools are really
8 supported. Before compiling, check the BIN definition in
9 makefile.msc. Compile with `nmake -f makefile.msc`. Install with
10 `nmake -f makefile.msc install`. Cygwin (without cygwin runtime,
11 i.e. "mingw32"), and maybe LCC-Win32 support will be added later.
12
13 When using the cygwin compiler and tools *with* the cygwin runtime the
14 normal Unix configuration method should work as if on Unix (knock on
15 wood).
16
17 With a little work, it might be possible to use the ./configure
18 mechanism also with a "mingw32" configuration. I.e. building GLib for
19 Win32 would use the cygwin tools (and dll), but the produced libraries
20 would not depend on the cygwin runtime being present.
21
22 The following preprocessor macros are used for conditional compilation 
23 related to Win32:
24
25 - WIN32 is defined when compiling for the Win32 platform, regardless
26   if using the X11 or Win32 GUI API (of course, in the case of GLib, this
27   dimension isn't significant), regardless whether using a more
28   or less complete Unix emulation runtime layer (like Cygwin) or not.
29
30 - NATIVE_WIN32 is defined when compiling for Win32, *and* without
31   any Unix emulation, other that to the extent provided by the
32   (Microsoft) C library, or the pthreads-win32 library. For instance,
33   pathnames use the native Windows syntax.
34
35 - _MSC_VER is defined when using the Microsoft compiler.
36
37 Currently the Win32 port uses the combination with all three of those
38 on, but eventually the cygwin compiler and tools will be supported
39 also, and in that case _MSC_VER wouldn't be defined.
40
41 Some of the usage of these macros is probably a bit mixed up, and will
42 have to be straightened out when actually trying other combinations.
43
44 The thread support uses the pthreads for Win32 package available from
45 http://sourceware.cygnus.com/pthreads-win32/, which isn't ready yet,
46 and thus really should not be relied upon.