Cygwin vs gtk on win32



What are the advantages and disadvantages of cygwin and the native
gtk+stuff on win32 when porting a tool to win32?

Here are some I can think of quickly:

--Advantages of Cygwin:

Less porting efforts, obviously, as Cygwin looks like Unix. (But GTK
would still have had to get a Win32 GDI / message loop / font / etc
backend, which is where most of the work was. Surely the popularity of
GIMP/Ethereal/GAIM/Dia/etc on Windows would be next to nil if it would
require running an X server...? (Not that I am participating in any
popularity contest.)

--Disadvantages of Cygwin:

One more layer, presumably affects speed. 

If you distribute software that runs on Cygwin, that software must be
GPL licensed. (It would presumably be OK for some business to run
in-house proprietary software on Cygwin?)

Looks like Unix. End-users might get confused when using apps running
on Cygwin that makes their harddrives look like Unix file
systems. (This is probably not a big deal, the file chooser could have
code to hide the Unixness of Cygwin, etc.)

As far as I know Cygwin doesn't have any wide character API in their C
library. This means restricted Unicode support. Basically you would be
able to handle only files with names that happen to be in your system
codepage. (Well, that's the case currently also in the Win32 port, but
about to change.)

--Advantages of Win32: 

The same DLLs are usable also from MSVC-compiled code.

Speed?

--Disadvantages of Win32: 

It doesn't pretend to be Unix, so porting of some stuff is harder.


Why are there native gtk+ stuff made if you can use cygwin?

Because I could ;-)

Anybody is of course free to build GTK and whatnot using Cygwin, and
distibute them. I just happened to want to do the GIMP port natively
back in, eh, 1997? (oh, how time flies), and the port got
popular. GLib, GTK etc patches that might still be needed for a Cygwin
build are certainly accepted by the maintainers.

--tml



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]