Skip to content

Unbreak Perl build on legacy Darwin systems #21023

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

Open
wants to merge 1 commit into
base: blead
Choose a base branch
from

Conversation

sevan
Copy link
Contributor

@sevan sevan commented Apr 15, 2023

On modern macOS the compiler defaults to '-Werror,-Wimplicit-function-declaration' This breaks the build on code which calls a function without a prototype (invalid in C99).
Turning the check off with '-Wno-error=implicit-function-declaration' breaks the build of Perl itself on legacy versions of Darwin with compilers which do not recognise the flags.
Removing it allows Perl to once again build on Mac OS X as old as 10.4 with GCC 4.0.1.

Resolves #18902

@Leont
Copy link
Contributor

Leont commented Apr 15, 2023

I see you've already made a PR for the MakeMaker part of change. This PR should be marked as not mergeable until that has been applied, released and synced back into blead.

Otherwise I approve of this change.

@sevan sevan marked this pull request as draft April 16, 2023 16:33
@sevan
Copy link
Contributor Author

sevan commented Apr 16, 2023

Moved PR into draft mode until other PR for MakeMaker is merged.

@haarg
Copy link
Contributor

haarg commented Apr 17, 2023

The changes to EUMM should be removed from this PR, since that will be handled separately.

Making this change, along with the EUMM change, is likely to break a number of XS modules on macOS. I agree that we should change this, but I'm not sure about the timing.

On modern macOS the compiler defaults to '-Werror,-Wimplicit-function-declaration'
This breaks the build on code which calls a function without a prototype
(invalid in C99).
Turning the check off with '-Wno-error=implicit-function-declaration'
breaks the build of Perl itself on legacy versions of Darwin with
compilers which do not recognise the flags.
Removing it allows Perl to once again build on Mac OS X as old as 10.4
with GCC 4.0.1.
Bump version and document.
This requires a similar change to cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_Darwin.pm
which will be handled separately.
@sevan
Copy link
Contributor Author

sevan commented Apr 17, 2023

I've removed cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_Darwin.pm

@sevan
Copy link
Contributor Author

sevan commented Apr 18, 2023

@sevan
Copy link
Contributor Author

sevan commented Apr 22, 2023

Smoke test result with patched blead

Ignore the failures, I didn't bump the rev so t/porting/cmp_version.t failed, cpan/ExtUtils-MakeMaker/t/04-xs-rpath-darwin.t fails but the test shouldn't be running on Darwin 8.
There is an issue with cpan/Test-Simple/t/Test2/behavior/ipc_wait_timeout.t hanging which is why the smoke test took so long. I had to run 'kill -9' several times over the past few days.

@jkeenan
Copy link
Contributor

jkeenan commented Aug 27, 2024

Smoke test result with patched blead

Ignore the failures, I didn't bump the rev so t/porting/cmp_version.t failed, cpan/ExtUtils-MakeMaker/t/04-xs-rpath-darwin.t fails but the test shouldn't be running on Darwin 8. There is an issue with cpan/Test-Simple/t/Test2/behavior/ipc_wait_timeout.t hanging which is why the smoke test took so long. I had to run 'kill -9' several times over the past few days.

There has been no discussion in this ticket in more than a year, and in that time the code has acquired several merge conflicts. Those will have to be resolved before we can proceed.

@sevan
Copy link
Contributor Author

sevan commented Aug 29, 2024

I'll take a look at updating over the weekend.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Perl 5.34.0 build breaks on Darwin gcc4
4 participants