Skip to content
Snippets Groups Projects
Commit 3954356a authored by Jakub Piotr Cłapa's avatar Jakub Piotr Cłapa
Browse files

perl: fixed host compilation of static perl on MacOS


All symbols on MacOS are prefixed with an underscore which
interfered with the filtering mechanism (added in perl 5.28)
for extension libraries to be linked into static perl.

Signed-off-by: default avatarJakub Piotr Cłapa <jpc@loee.pl>
parent b084ca69
No related branches found
No related tags found
No related merge requests found
...@@ -11,7 +11,7 @@ include perlver.mk ...@@ -11,7 +11,7 @@ include perlver.mk
PKG_NAME:=perl PKG_NAME:=perl
PKG_VERSION:=$(PERL_VERSION) PKG_VERSION:=$(PERL_VERSION)
PKG_RELEASE:=2 PKG_RELEASE:=3
PKG_SOURCE_URL:=\ PKG_SOURCE_URL:=\
https://cpan.metacpan.org/src/5.0 \ https://cpan.metacpan.org/src/5.0 \
......
--- a/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_Unix.pm
+++ b/cpan/ExtUtils-MakeMaker/lib/ExtUtils/MM_Unix.pm
@@ -2738,14 +2738,14 @@ sub _find_static_libs {
Called by a utility method of makeaperl. Checks whether a given file
is an XS library by seeing whether it defines any symbols starting
-with C<boot_>.
+with C<boot_> (with an optional leading underscore – needed on MacOS).
=cut
sub xs_static_lib_is_xs {
my ($self, $libfile) = @_;
my $devnull = File::Spec->devnull;
- return `nm $libfile 2>$devnull` =~ /\bboot_/;
+ return `nm $libfile 2>$devnull` =~ /\b_?boot_/;
}
=item makefile (o)
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment