-
Notifications
You must be signed in to change notification settings - Fork 559
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Win32] mingw-w64 ports of gcc-13 will break 32-bit builds of perl #21039
Labels
Comments
xenu
added a commit
to xenu/perl5
that referenced
this issue
Jun 5, 2023
Those redefinitions are in effect only when PERL_IMPLICIT_SYS is defined (pretty much only on Windows) and they're broken (circular) when HAS_SIGSETJMP isn't defined (e.g. on Windows). Also, even if they weren't broken, they don't provide any value. The workaround in thread.xs for this issue is still needed, because it's a dual-life module and it's supposed to work on older Perls. However, it can be simplified by defining NO_XSLOCKS to suppress the redefinitions. Fixes Perl#21039
xenu
added a commit
to xenu/perl5
that referenced
this issue
Jun 6, 2023
Those redefinitions are in effect only when PERL_IMPLICIT_SYS is defined (pretty much only on Windows) and they're broken (circular) when HAS_SIGSETJMP isn't defined (e.g. on Windows). Also, even if they weren't broken, they don't provide any value. The workaround in threads.xs for this issue is still needed, because it's a dual-life module and it's supposed to work on older Perls. However, it can be simplified by defining NO_XSLOCKS to suppress the redefinitions. Fixes Perl#21039
#21142 LGTM. Cheers, |
tonycoz
pushed a commit
that referenced
this issue
Jul 10, 2023
Those redefinitions are in effect only when PERL_IMPLICIT_SYS is defined (pretty much only on Windows) and they're broken (circular) when HAS_SIGSETJMP isn't defined (e.g. on Windows). Also, even if they weren't broken, they don't provide any value. The workaround in threads.xs for this issue is still needed, because it's a dual-life module and it's supposed to work on older Perls. However, it can be simplified by defining NO_XSLOCKS to suppress the redefinitions. Fixes #21039
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Description
With mingw-w64 ports of gcc-13, 32-bit versions of setjmp.h will no longer look at whether USE_NO_MINGW_SETJMP_TWO_ARGS is defined.
This change means that dist/threads/threads.xs won't compile using gcc-13. (No such issue with gcc-12 and earlier.)
Martin Storsjo (who is a member of the mingw-w64 development team) has generously provided me with the following patch to the perl source that (verified) will fix this problem:
Things to note:
Applying this patch to perl-5.37.10, I've checked that perl still builds and tests fine for both 32-bit and 64-bit versions of both gcc-12.2.0 and gcc-13.0.1.
I've also checked that this patch (applied to 5.37.10) works fine with 32-bit and 64-bit VS-2022 compilers. (With the 32-bit VS-2022 I built both MSWin32-x86-multi-thread and MSWin32-x86-multi-thread-64int.)
To me, it looks great, and I'll be applying this patch to the perls that I build henceforth.
But I haven't (eg) tested it using any gcc versions older than 12.2.0.
Anyway .... I'm putting the patch up here as something that people might like to test and/or comment upon.
If you think there's a better way to deal with the impending issue with gcc-13, now is a good time to speak up.
Snapshots of mingw-w64 ports of the gcc-13.0.1 toolchain can be downloaded from:
https://gcc-mcf.lhmouse.com/
or
https://winlibs.com
EDIT: fixed typo
Cheers,
Rob
The text was updated successfully, but these errors were encountered: