From: groma AT everx DOT szbk DOT u-szeged DOT hu ("Geza Groma") Subject: Re: looking for TCL-TK gnu compiled 27 Jan 1997 09:13:26 -0800 Approved: cygnus DOT gnu-win32 AT cygnus DOT com Distribution: cygnus Message-ID: <85EEE065F.cygnus.gnu-win32@everx.szbk.u-szeged.hu> Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7BIT Original-To: gnu-win32 AT cygnus DOT com, Fabrice Beauvir Original-Cc: colin AT bird DOT fu DOT is DOT saga-u DOT ac DOT jp X-Mailer: Pegasus Mail for Windows (v2.33) Content-Length: 2517 Original-Sender: owner-gnu-win32 AT cygnus DOT com > I am looking for a GNU -win32 compiled version of TCL-TK 8.0 or makefile(s) Well, the DLL files precompiled by SUN do not work with cygwin (and also not with MSVC!). I just tried to build tcl8.0 (not yet tk) with gnu-win32. Here is the list of problems/patches found during the compilation phase: 1. The most serious problem is the following piece of code in tclWinFCmd.c: try { if (MoveFile(src, dst) != FALSE) { return TCL_OK; } } except (-1) {} Try is a C++ keyword. Some compilers (Borland, MSVC, Symantec) supports try or __try even in simple C, but GCC apparently does not. Compiling with the -xc++ flag eliminates this problem, but brings up a lot of new errors (even in the header files). Any idea how to deal with this? 2. Since no io.h exists in the original cygwin distribution I used the mingw32 package with compiler options: -O -DFAR= -Denviron=_environ -Dhypot=_hypot 3. No winsock.h, winarg.h, winnt.h and winbase.h in mingwin32. Use windows.h instead of them (also causing less pain with redefinitions). 4. As pointed out by Colin Peters in section Gotchas and Surprises of mingw32, the Berkley-type error message are redefined in Sockets.h, so the corresponding block should be commented out. 5. _hypot is not declared in math.h although CRTDLL supports it. Is there any particular reason to omit that? 6. Declaration of struct exception and definition of DOMAIN and SING should be copied to math.h of mingwin32 from math.h of tcygwin . (tclWinMtherr.c supplies its own version of _matherr) 7. Dos.h does not exist. tclWinPipe.c needs IMAGE_DOS_HEADER and IMAGE_DOS_SIGNATURE from that. I found them declared in winnt.h of Microsoft but _not_ in the cygwin32 or mingwin32 distribution. 8. Two errors found in tclWinSock.c I have not yet time to analyze: winSock.accept = (SOCKET (PASCAL FAR *)(SOCKET s, struct sockaddr FAR *addr, int FAR *addrlen)) GetProcAddress(handle, "accept"); ../../win/tclWinSock.c:261: warning: `__stdcall__' attribute directive ignored ../../win/tclWinSock.c:263: `type name' declared as function returning a function ../../win/tclWinSock.c:263: cast specifies function type socketWindow = CreateWindowEx(0, (LPCTSTR)socketClass, "TclSocket", WS_OVERLAPPED, 0, 0, 0, 0, NULL, NULL, TclWinGetTclInstance(), NULL); ../../win/tclWinSock.c:398: warning: cast to pointer from integer of different size 9. _timezone, _tzname and _daylight are not declared in any header file. Geza Groma - For help on using this list, send a message to "gnu-win32-request AT cygnus DOT com" with one line of text: "help".