Skip to content
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

Fix failure in building of perl integration source for 9.2 on macOS #53

Closed
wants to merge 1 commit into from

Conversation

nuclearpidgeon
Copy link

Building the previous formula for [email protected] led to the following error in the make step:

In file included from plperl.c:49:
./plperl.h:53:10: fatal error: 'EXTERN.h' file not found
#include "EXTERN.h"
         ^~~~~~~~~~

As of XCode 10(?), system headers (which includes the headers for the system version of perl) have been removed from the base macOS system and now only live in the macOS SDK, which must be included explicitly for the build process to find the system perl headers that were previously expected to already be globally available.

See these links for more info:

I'm not sure if this PR is the 'right' way to solve this issue, but it at least made the compilation work for me on macOS 10.14.6. I can port this across to the other formulas as well if you want, it will just involve some more time for me to test which formulas need it and which ones don't.

This seems to be the same kind of issue as raised by #50 and #44 - users on those issues fixed the problem by making perl a brew dependency of the formula, or by installing the temporary workaround macOS_SDK_headers_for_macOS_10.14.pkg supplied by Apple that puts all the headers back in the system root (this is apparently not available on 10.15 Catalina though). The fix in this PR at least avoids the user needing to make any changes for the formula to compile.

Longer-term though, Apple will be removing scripting languages like Perl from the base macOS system, so it may be better to add a homebrew dependency on perl instead? Like I said, not sure what the right way forward is, but wanted to at least share this fix as a possible solution.

Building the previous formula led to the following error in the make step:

    In file included from plperl.c:49:
    ./plperl.h:53:10: fatal error: 'EXTERN.h' file not found
    #include "EXTERN.h"
             ^~~~~~~~~~

As of XCode 10(?), system headers have been removed from the base macOS system
and now only live in the macOS SDK, which must be included explicitly for the
build process to find the system perl headers that were previously expected
to already be globally available.

See these links for more info:
* https://apple.stackexchange.com/questions/337940/
* https://developer.apple.com/documentation/xcode_release_notes/xcode_10_release_notes#3035623
@petere
Copy link
Owner

petere commented Mar 19, 2020

Is this particular to 9.2?

@petere
Copy link
Owner

petere commented Nov 10, 2021

closing due to lack of feedback

@petere petere closed this Nov 10, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants