Hi guys,

When I read the email asking for GCC 6.1, I took a look at MinGW-builds and
MSYS2's MinGW-packages and saw both were stuck somewhere in 5.x.

I decided to see if I could blow the dust off my aeons-old build scripts
that are still gathering some stars on github, but were otherwise unused.

I ran into some unexpected trouble though: C++ exceptions are broken. A
simple test app of the form:

#include <iostream>

int main()
try
{
  throw 42;
}
catch(int i)
{
  std::cout << "caught int: " << i << '\n';
}

crashes with this backtrace:

Starting program: C:\Users\Ruben\Desktop\mingw64\test.exe
[New Thread 3836.0x68c]
[New Thread 3836.0x15dc]
[New Thread 3836.0x15e0]

Program received signal SIGSEGV, Segmentation fault.
0x000000006fc59e7f in libstdc++-6!.cxa_demangle () from
C:\Users\Ruben\Desktop\mingw64\bin\libstdc++-6.dll
(gdb) bt
#0  0x000000006fc59e7f in libstdc++-6!.cxa_demangle () from
C:\Users\Ruben\Desktop\mingw64\bin\libstdc++-6.dll
#1  0x000000006fc5aae8 in
libstdc++-6!_ZN10__cxxabiv129__pointer_to_member_type_infoD2Ev ()
   from C:\Users\Ruben\Desktop\mingw64\bin\libstdc++-6.dll
#2  0x000000006144d245 in libgcc_s_seh-1!_GCC_specific_handler ()
   from C:\Users\Ruben\Desktop\mingw64\bin\libgcc_s_seh-1.dll
#3  0x000000006fcc0c35 in libstdc++-6!.gxx_personality_seh0 () from
C:\Users\Ruben\Desktop\mingw64\bin\libstdc++-6.dll
#4  0x00007ffea46a9afd in ntdll!.chkstk () from
C:\WINDOWS\SYSTEM32\ntdll.dll
#5  0x00007ffea4634fe9 in ntdll!RtlImageNtHeaderEx () from
C:\WINDOWS\SYSTEM32\ntdll.dll
#6  0x00007ffea46a8c0a in ntdll!KiUserExceptionDispatcher () from
C:\WINDOWS\SYSTEM32\ntdll.dll
#7  0x00007ffea15b1f28 in RaiseException () from
C:\WINDOWS\system32\KernelBase.dll
#8  0x000000006144d336 in libgcc_s_seh-1!_Unwind_RaiseException ()
   from C:\Users\Ruben\Desktop\mingw64\bin\libgcc_s_seh-1.dll
#9  0x000000006fcc042e in libstdc++-6!.cxa_throw () from
C:\Users\Ruben\Desktop\mingw64\bin\libstdc++-6.dll
#10 0x0000000000401568 in main ()

Now, I didn't change much in my build scripts, but I do remember GCC 4.8 in
prerelease form working just fine (albeit with a patch for libstdc++
exports).
I don't remember any more detail (it was quite a while ago), but looking at
MinGW-packages's build script,
https://github.com/Alexpux/MINGW-packages/blob/master/mingw-w64-gcc/PKGBUILD
I see a ton of patches being applied, and that for quite a while.

Have these been upstreamed? I'm guessing no, because there's still GCC 4.8
patches in there, being applied. Am I reading this wrong or is there no way
to make vanilla (i.e. unpatched, released GCC, say 5.4, or 6.1) work out of
the box?

If not, that seems like something that could use fixing.
What would be the minimal set of patches to make everything work for say,
GCC 6.1?

Thanks,

Ruben
------------------------------------------------------------------------------
What NetFlow Analyzer can do for you? Monitors network bandwidth and traffic
patterns at an interface-level. Reveals which users, apps, and protocols are 
consuming the most bandwidth. Provides multi-vendor support for NetFlow, 
J-Flow, sFlow and other flows. Make informed decisions using capacity 
planning reports. https://ad.doubleclick.net/ddm/clk/305295220;132659582;e
_______________________________________________
Mingw-w64-public mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/mingw-w64-public

Reply via email to