Re: [Mingw-w64-public] conflicting EXCEPTION_REGISTRATION types with tcl/tk 8.6.1

2013-11-08 Thread Zbigniew Diaczyszyn
Am 08.11.2013 05:58, schrieb Alexey Pavlov:
 This is known issue. You can grab my patch from here:
 
 https://github.com/Alexpux/mingw-builds/blob/master/patches/tcl/tcl-8.6.1-mingwexcept.patch

Thanks for the patch. Building the win64 version Tcl 8.5.15 I have got the same 
exception error but after applying your patch manually all went well.

Did you already inform the Tcl development team that a patch has to be made?

Below you can find the contents of my tcl-8.5.15-mingwexcept.patch 

--- tclWin32Dll.c.orig  2013-08-30 17:58:40.0 +0200
+++ tclWin32Dll.c   2013-11-08 08:55:00.742333794 +0100
@@ -53,14 +53,14 @@ static int platformId;  /* Running under
  * them by creating an EXCEPTION_REGISTRATION within the activation record.
  */
 
-typedef struct EXCEPTION_REGISTRATION {
-struct EXCEPTION_REGISTRATION *link;
+typedef struct TCL_EXCEPTION_REGISTRATION {
+struct TCL_EXCEPTION_REGISTRATION *link;
 EXCEPTION_DISPOSITION (*handler)(
struct _EXCEPTION_RECORD*, void*, struct _CONTEXT*, void*);
 void *ebp;
 void *esp;
 int status;
-} EXCEPTION_REGISTRATION;
+} TCL_EXCEPTION_REGISTRATION;
 #endif
 
 /*
@@ -1086,7 +1086,7 @@ TclWinCPUID(
 
 #   else
 
-EXCEPTION_REGISTRATION registration;
+TCL_EXCEPTION_REGISTRATION registration;
 
 /*
  * Execute the CPUID instruction with the given index, and store results
--- tclWinChan.c.orig   2013-08-30 17:58:40.0 +0200
+++ tclWinChan.c2013-11-08 09:05:57.237807102 +0100
@@ -127,14 +127,14 @@ static Tcl_ChannelType fileChannelType =
  * them by creating an EXCEPTION_REGISTRATION within the activation record.
  */
 
-typedef struct EXCEPTION_REGISTRATION {
-struct EXCEPTION_REGISTRATION* link;
+typedef struct TCL_EXCEPTION_REGISTRATION {
+struct TCL_EXCEPTION_REGISTRATION *link;
 EXCEPTION_DISPOSITION (*handler)(
struct _EXCEPTION_RECORD*, void*, struct _CONTEXT*, void*);
 void* ebp;
 void* esp;
 int status;
-} EXCEPTION_REGISTRATION;
+} TCL_EXCEPTION_REGISTRATION;
 #endif
 

 /*
@@ -1027,7 +1027,7 @@ Tcl_MakeFileChannel(
 * TCL_WRITABLE to indicate file mode. */
 {
 #if defined(HAVE_NO_SEH)  !defined(_WIN64)
-EXCEPTION_REGISTRATION registration;
+TCL_EXCEPTION_REGISTRATION registration;
 #endif
 char channelName[16 + TCL_INTEGER_SPACE];
 Tcl_Channel channel = NULL;
--- tclWinFCmd.c.orig   2013-08-30 17:58:40.0 +0200
+++ tclWinFCmd.c2013-11-08 09:09:19.541771741 +0100
@@ -72,17 +72,17 @@ CONST TclFileAttrProcs tclpFileAttrProcs
 /*
  * Unlike Borland and Microsoft, we don't register exception handlers by
  * pushing registration records onto the runtime stack. Instead, we register
- * them by creating an EXCEPTION_REGISTRATION within the activation record.
+ * them by creating an TCL_EXCEPTION_REGISTRATION within the activation record.
  */
 
-typedef struct EXCEPTION_REGISTRATION {
-struct EXCEPTION_REGISTRATION *link;
+typedef struct TCL_EXCEPTION_REGISTRATION {
+struct TCL_EXCEPTION_REGISTRATION *link;
 EXCEPTION_DISPOSITION (*handler)(
struct _EXCEPTION_RECORD *, void *, struct _CONTEXT *, void *);
 void *ebp;
 void *esp;
 int status;
-} EXCEPTION_REGISTRATION;
+} TCL_EXCEPTION_REGISTRATION;
 
 #endif
 
@@ -176,7 +176,7 @@ DoRenameFile(
 * (native). */
 {
 #if defined(HAVE_NO_SEH)  !defined(_WIN64)
-EXCEPTION_REGISTRATION registration;
+TCL_EXCEPTION_REGISTRATION registration;
 #endif
 DWORD srcAttr, dstAttr;
 int retval = -1;
@@ -568,7 +568,7 @@ DoCopyFile(
 CONST TCHAR *nativeDst)/* Pathname of file to copy to (native). */
 {
 #if defined(HAVE_NO_SEH)  !defined(_WIN64)
-EXCEPTION_REGISTRATION registration;
+TCL_EXCEPTION_REGISTRATION registration;
 #endif
 int retval = -1;

-- 
Zbigniew Diaczyszyn
 Web: http://zdia.de
 PGP Key ID: 0x52052C79

--
November Webinars for C, C++, Fortran Developers
Accelerate application performance with scalable programming models. Explore
techniques for threading, error checking, porting, and tuning. Get the most 
from the latest Intel processors and coprocessors. See abstracts and register
http://pubads.g.doubleclick.net/gampad/clk?id=60136231iu=/4140/ostg.clktrk
___
Mingw-w64-public mailing list
Mingw-w64-public@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mingw-w64-public


[Mingw-w64-public] conflicting EXCEPTION_REGISTRATION types with tcl/tk 8.6.1

2013-11-07 Thread Jon
While updating my powershell-based build recipes (buildlets) for 64-bit
and other things, I get the following build errors on Win8.1 64bit using
`x64-msys2-20131022.tar.xz` and the mingw32-make reloaded version of
`x86_64-4.8.2-release-win32-seh-rt_v3-rev0.7z`.

No errors when using mingw.org msys and the older mingwbuilds
`x32-4.7.3-release-win32-sjlj-rev1.7z` toolchain.

The only mildly interesting part of the buildlet is addressing the
`config.guess` problem of not being able to guess the `x86_64-w64-mingw32`
system type. But it appears irrelevant to what looks to be a mingw-w64
header issue.

mingw-w64 header issue, or tcl/tk issue, or something I've messed up in the
config?



PS buildlets-git .\build_tcltk.ps1 8.6.1 -x64
--- validating tcl8.6.1-src.tar.gz
--- validating tk8.6.1-src.tar.gz
--- extracting tcl8.6.1-src.tar.gz
--- extracting tk8.6.1-src.tar.gz
--- activating toolchain [64-bit]
--- configuring tcl8.6.1 [64-bit]
--- building tcl8.6.1 [64-bit]
C:\Users\Jon\Documents\CDev\buildlets-git\tcl8.6.1\win\tclWin32Dll.c:42:3:
error: conflicting
types for 'EXCEPTION_REGISTRATION'
 } EXCEPTION_REGISTRATION;
   ^
In file included from
c:\apps\devtools\mingw\x86_64-w64-mingw32\include\minwindef.h:146:0,
 from
c:\apps\devtools\mingw\x86_64-w64-mingw32\include\windef.h:8,
 from
c:\apps\devtools\mingw\x86_64-w64-mingw32\include\windows.h:69,
 from
C:/Users/Jon/Documents/CDev/buildlets-git/tcl8.6.1/win/tclWinPort.h:36,
 from
C:/Users/Jon/Documents/CDev/buildlets-git/tcl8.6.1/generic/tclPort.h:21,
 from
C:/Users/Jon/Documents/CDev/buildlets-git/tcl8.6.1/generic/tclInt.h:36,
 from
C:\Users\Jon\Documents\CDev\buildlets-git\tcl8.6.1\win\tclWinInt.h:15,
 from
C:\Users\Jon\Documents\CDev\buildlets-git\tcl8.6.1\win\tclWin32Dll.c:14:
c:\apps\devtools\mingw\x86_64-w64-mingw32\include\winnt.h:3554:43: note:
previous declaration
of 'EXCEPTION_REGISTRATION' was here
 typedef EXCEPTION_REGISTRATION_RECORD EXCEPTION_REGISTRATION;
   ^
make: *** [tclWin32Dll.o] Error 1

...[SNIP]...

--- activating toolchain [64-bit]
--- configuring tk8.6.1 [64-bit]
--- building tk8.6.1 [64-bit]
C:\Users\Jon\Documents\CDev\buildlets-git\tk8.6.1\win\tkWin32Dll.c:30:3:
error: conflicting types for 'EXCEPTION_REGISTRATION'
 } EXCEPTION_REGISTRATION;
   ^
In file included from
c:\apps\devtools\mingw\x86_64-w64-mingw32\include\minwindef.h:146:0,
 from
c:\apps\devtools\mingw\x86_64-w64-mingw32\include\windef.h:8,
 from
c:\apps\devtools\mingw\x86_64-w64-mingw32\include\windows.h:69,
 from
C:\Users\Jon\Documents\CDev\buildlets-git\tk8.6.1\win\tkWin.h:36,
 from
C:\Users\Jon\Documents\CDev\buildlets-git\tk8.6.1\win\tkWinInt.h:26,
 from
C:\Users\Jon\Documents\CDev\buildlets-git\tk8.6.1\win\tkWin32Dll.c:12:
c:\apps\devtools\mingw\x86_64-w64-mingw32\include\winnt.h:3554:43: note:
previous declaration
of 'EXCEPTION_REGISTRATION' was here
 typedef EXCEPTION_REGISTRATION_RECORD EXCEPTION_REGISTRATION;
   ^
make: *** [tkWin32Dll.o] Error 1
--
November Webinars for C, C++, Fortran Developers
Accelerate application performance with scalable programming models. Explore
techniques for threading, error checking, porting, and tuning. Get the most 
from the latest Intel processors and coprocessors. See abstracts and register
http://pubads.g.doubleclick.net/gampad/clk?id=60136231iu=/4140/ostg.clktrk___
Mingw-w64-public mailing list
Mingw-w64-public@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mingw-w64-public


Re: [Mingw-w64-public] conflicting EXCEPTION_REGISTRATION types with tcl/tk 8.6.1

2013-11-07 Thread Jon
the link to the tcltk buildlet

https://github.com/jonforums/buildlets/blob/master/build_tcltk.ps1#L79-L80


On Thu, Nov 7, 2013 at 10:41 PM, Jon jon.for...@gmail.com wrote:

 While updating my powershell-based build recipes (buildlets) for 64-bit
 and other things, I get the following build errors on Win8.1 64bit using
 `x64-msys2-20131022.tar.xz` and the mingw32-make reloaded version of
 `x86_64-4.8.2-release-win32-seh-rt_v3-rev0.7z`.

 No errors when using mingw.org msys and the older mingwbuilds
 `x32-4.7.3-release-win32-sjlj-rev1.7z` toolchain.

 The only mildly interesting part of the buildlet is addressing the
 `config.guess` problem of not being able to guess the `x86_64-w64-mingw32`
 system type. But it appears irrelevant to what looks to be a mingw-w64
 header issue.

 mingw-w64 header issue, or tcl/tk issue, or something I've messed up in
 the config?



 PS buildlets-git .\build_tcltk.ps1 8.6.1 -x64
 --- validating tcl8.6.1-src.tar.gz
 --- validating tk8.6.1-src.tar.gz
 --- extracting tcl8.6.1-src.tar.gz
 --- extracting tk8.6.1-src.tar.gz
 --- activating toolchain [64-bit]
 --- configuring tcl8.6.1 [64-bit]
 --- building tcl8.6.1 [64-bit]
 C:\Users\Jon\Documents\CDev\buildlets-git\tcl8.6.1\win\tclWin32Dll.c:42:3:
 error: conflicting
 types for 'EXCEPTION_REGISTRATION'
  } EXCEPTION_REGISTRATION;
^
 In file included from
 c:\apps\devtools\mingw\x86_64-w64-mingw32\include\minwindef.h:146:0,
  from
 c:\apps\devtools\mingw\x86_64-w64-mingw32\include\windef.h:8,
  from
 c:\apps\devtools\mingw\x86_64-w64-mingw32\include\windows.h:69,
  from
 C:/Users/Jon/Documents/CDev/buildlets-git/tcl8.6.1/win/tclWinPort.h:36,
  from
 C:/Users/Jon/Documents/CDev/buildlets-git/tcl8.6.1/generic/tclPort.h:21,
  from
 C:/Users/Jon/Documents/CDev/buildlets-git/tcl8.6.1/generic/tclInt.h:36,
  from
 C:\Users\Jon\Documents\CDev\buildlets-git\tcl8.6.1\win\tclWinInt.h:15,
  from
 C:\Users\Jon\Documents\CDev\buildlets-git\tcl8.6.1\win\tclWin32Dll.c:14:
 c:\apps\devtools\mingw\x86_64-w64-mingw32\include\winnt.h:3554:43: note:
 previous declaration
 of 'EXCEPTION_REGISTRATION' was here
  typedef EXCEPTION_REGISTRATION_RECORD EXCEPTION_REGISTRATION;
^
 make: *** [tclWin32Dll.o] Error 1

 ...[SNIP]...

 --- activating toolchain [64-bit]
 --- configuring tk8.6.1 [64-bit]
 --- building tk8.6.1 [64-bit]
 C:\Users\Jon\Documents\CDev\buildlets-git\tk8.6.1\win\tkWin32Dll.c:30:3:
 error: conflicting types for 'EXCEPTION_REGISTRATION'
  } EXCEPTION_REGISTRATION;
^
 In file included from
 c:\apps\devtools\mingw\x86_64-w64-mingw32\include\minwindef.h:146:0,
  from
 c:\apps\devtools\mingw\x86_64-w64-mingw32\include\windef.h:8,
  from
 c:\apps\devtools\mingw\x86_64-w64-mingw32\include\windows.h:69,
  from
 C:\Users\Jon\Documents\CDev\buildlets-git\tk8.6.1\win\tkWin.h:36,
  from
 C:\Users\Jon\Documents\CDev\buildlets-git\tk8.6.1\win\tkWinInt.h:26,
  from
 C:\Users\Jon\Documents\CDev\buildlets-git\tk8.6.1\win\tkWin32Dll.c:12:
 c:\apps\devtools\mingw\x86_64-w64-mingw32\include\winnt.h:3554:43: note:
 previous declaration
 of 'EXCEPTION_REGISTRATION' was here
  typedef EXCEPTION_REGISTRATION_RECORD EXCEPTION_REGISTRATION;
^
 make: *** [tkWin32Dll.o] Error 1



--
November Webinars for C, C++, Fortran Developers
Accelerate application performance with scalable programming models. Explore
techniques for threading, error checking, porting, and tuning. Get the most 
from the latest Intel processors and coprocessors. See abstracts and register
http://pubads.g.doubleclick.net/gampad/clk?id=60136231iu=/4140/ostg.clktrk___
Mingw-w64-public mailing list
Mingw-w64-public@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mingw-w64-public


Re: [Mingw-w64-public] conflicting EXCEPTION_REGISTRATION types with tcl/tk 8.6.1

2013-11-07 Thread Alexey Pavlov
2013/11/8 Jon jon.for...@gmail.com:
 the link to the tcltk buildlet

 https://github.com/jonforums/buildlets/blob/master/build_tcltk.ps1#L79-L80



 On Thu, Nov 7, 2013 at 10:41 PM, Jon jon.for...@gmail.com wrote:

 While updating my powershell-based build recipes (buildlets) for 64-bit
 and other things, I get the following build errors on Win8.1 64bit using
 `x64-msys2-20131022.tar.xz` and the mingw32-make reloaded version of
 `x86_64-4.8.2-release-win32-seh-rt_v3-rev0.7z`.

 No errors when using mingw.org msys and the older mingwbuilds
 `x32-4.7.3-release-win32-sjlj-rev1.7z` toolchain.

 The only mildly interesting part of the buildlet is addressing the
 `config.guess` problem of not being able to guess the `x86_64-w64-mingw32`
 system type. But it appears irrelevant to what looks to be a mingw-w64
 header issue.

 mingw-w64 header issue, or tcl/tk issue, or something I've messed up in
 the config?



 PS buildlets-git .\build_tcltk.ps1 8.6.1 -x64
 --- validating tcl8.6.1-src.tar.gz
 --- validating tk8.6.1-src.tar.gz
 --- extracting tcl8.6.1-src.tar.gz
 --- extracting tk8.6.1-src.tar.gz
 --- activating toolchain [64-bit]
 --- configuring tcl8.6.1 [64-bit]
 --- building tcl8.6.1 [64-bit]
 C:\Users\Jon\Documents\CDev\buildlets-git\tcl8.6.1\win\tclWin32Dll.c:42:3:
 error: conflicting
 types for 'EXCEPTION_REGISTRATION'
  } EXCEPTION_REGISTRATION;
^
 In file included from
 c:\apps\devtools\mingw\x86_64-w64-mingw32\include\minwindef.h:146:0,
  from
 c:\apps\devtools\mingw\x86_64-w64-mingw32\include\windef.h:8,
  from
 c:\apps\devtools\mingw\x86_64-w64-mingw32\include\windows.h:69,
  from
 C:/Users/Jon/Documents/CDev/buildlets-git/tcl8.6.1/win/tclWinPort.h:36,
  from
 C:/Users/Jon/Documents/CDev/buildlets-git/tcl8.6.1/generic/tclPort.h:21,
  from
 C:/Users/Jon/Documents/CDev/buildlets-git/tcl8.6.1/generic/tclInt.h:36,
  from
 C:\Users\Jon\Documents\CDev\buildlets-git\tcl8.6.1\win\tclWinInt.h:15,
  from
 C:\Users\Jon\Documents\CDev\buildlets-git\tcl8.6.1\win\tclWin32Dll.c:14:
 c:\apps\devtools\mingw\x86_64-w64-mingw32\include\winnt.h:3554:43: note:
 previous declaration
 of 'EXCEPTION_REGISTRATION' was here
  typedef EXCEPTION_REGISTRATION_RECORD EXCEPTION_REGISTRATION;
^
 make: *** [tclWin32Dll.o] Error 1

 ...[SNIP]...

 --- activating toolchain [64-bit]
 --- configuring tk8.6.1 [64-bit]
 --- building tk8.6.1 [64-bit]
 C:\Users\Jon\Documents\CDev\buildlets-git\tk8.6.1\win\tkWin32Dll.c:30:3:
 error: conflicting types for 'EXCEPTION_REGISTRATION'
  } EXCEPTION_REGISTRATION;
^
 In file included from
 c:\apps\devtools\mingw\x86_64-w64-mingw32\include\minwindef.h:146:0,
  from
 c:\apps\devtools\mingw\x86_64-w64-mingw32\include\windef.h:8,
  from
 c:\apps\devtools\mingw\x86_64-w64-mingw32\include\windows.h:69,
  from
 C:\Users\Jon\Documents\CDev\buildlets-git\tk8.6.1\win\tkWin.h:36,
  from
 C:\Users\Jon\Documents\CDev\buildlets-git\tk8.6.1\win\tkWinInt.h:26,
  from
 C:\Users\Jon\Documents\CDev\buildlets-git\tk8.6.1\win\tkWin32Dll.c:12:
 c:\apps\devtools\mingw\x86_64-w64-mingw32\include\winnt.h:3554:43: note:
 previous declaration
 of 'EXCEPTION_REGISTRATION' was here
  typedef EXCEPTION_REGISTRATION_RECORD EXCEPTION_REGISTRATION;
^
 make: *** [tkWin32Dll.o] Error 1



This is known issue. You can grab my patch from here:

https://github.com/Alexpux/mingw-builds/blob/master/patches/tcl/tcl-8.6.1-mingwexcept.patch

Regards,
Alexey.



 --
 November Webinars for C, C++, Fortran Developers
 Accelerate application performance with scalable programming models. Explore
 techniques for threading, error checking, porting, and tuning. Get the most
 from the latest Intel processors and coprocessors. See abstracts and
 register
 http://pubads.g.doubleclick.net/gampad/clk?id=60136231iu=/4140/ostg.clktrk
 ___
 Mingw-w64-public mailing list
 Mingw-w64-public@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/mingw-w64-public


--
November Webinars for C, C++, Fortran Developers
Accelerate application performance with scalable programming models. Explore
techniques for threading, error checking, porting, and tuning. Get the most 
from the latest Intel processors and coprocessors. See abstracts and register
http://pubads.g.doubleclick.net/gampad/clk?id=60136231iu=/4140/ostg.clktrk
___
Mingw-w64-public mailing list
Mingw-w64-public@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mingw-w64-public