Opened 5 years ago

Closed 3 years ago

#59207 closed defect (worksforme)

perl5.28 build fails on Catalina with MacPorts 2.6.1 and Xcode 11.1

Reported by: nombak Owned by: mojca (Mojca Miklavec)
Priority: Normal Milestone:
Component: ports Version:
Keywords: catalina Cc: mjwybrow (Michael Wybrow), MasakiOita, thenickdude (Nicholas Sherlock), Knapoc, chrstphrchvz (Christopher Chavez)
Port: perl5.28

Description

perl5.28 build fails on Catalina with MacPorts 2.6.1 and Xcode 11.1. main.log is attached.

Attachments (3)

main.log (164.7 KB) - added by nombak 5 years ago.
Screen Shot 2019-10-14 at 4.08.51 PM.png (256.2 KB) - added by knightjp 5 years ago.
Perl5.28 still failing.
main.2.log (193.7 KB) - added by knightjp 5 years ago.
Main - 2

Download all attachments as: .zip

Change History (30)

Changed 5 years ago by nombak

Attachment: main.log added

comment:1 Changed 5 years ago by jmroot (Joshua Root)

Keywords: catalina added
Owner: set to mojca
Port: perl5.28 added
Status: newassigned

comment:2 Changed 5 years ago by mojca (Mojca Miklavec)

Thanks a lot for the report.

Out of curiosity: does perl5.30 work?

I fail to see what exactly goes wrong. As if miniperl was called with something like $UNKNOWN_VARIABLE/miniperl and then ends up being called as /miniperl and not found, but I'm not sure where.

Would you be willing to ask on the perl's IRC channel (or whatever other communication channels) in case they might have any insight? (They might ask you additional questions or suggest what to try; even when I ask, I cannot provide them the answers that you can).

:info:build DYLD_LIBRARY_PATH=/path/to/perl5.28/work/perl-5.28.2 ./miniperl -Ilib make_ext.pl cpan/JSON-PP/pm_to_blib  MAKE="/Library/Developer/CommandLineTools/usr/bin/make" LIBPERL_A=libperl.dylib
:info:build Generating a Unix-style Makefile
:info:build Writing Makefile for lib
:info:build Running pm_to_blib for ext/IPC-Open3 directly
:info:build DYLD_LIBRARY_PATH=/path/to/perl5.28/work/perl-5.28.2 ./miniperl -Ilib make_ext.pl cpan/Locale-Codes/pm_to_blib  MAKE="/Library/Developer/CommandLineTools/usr/bin/make" LIBPERL_A=libperl.dylib
:info:build make[1]: Entering directory `/path/to/perl5.28/work/perl-5.28.2/dist/lib'
:info:build Generating a Unix-style Makefile
:info:build Writing Makefile for HTTP::Tiny
:info:build make[1]: Entering directory `/path/to/perl5.28/work/perl-5.28.2/cpan/HTTP-Tiny'
:info:build /bin/sh: /miniperl: No such file or directory
:info:build make[1]: *** [../../lib/HTTP/.exists] Error 127

comment:3 Changed 5 years ago by nombak

Thank you for working on this! I have tried perl5.30, which builds successfully (, but may ports depend on perl5.28...).

I clean-installed Catalina, installed Xcode 11.1, and did "xcodebuild -license" and "sudo xcode-select --install". Then I installed MacPorts 2.6.1 and just typed "sudo port install -fN perl5.28". Is there anything you see that I'm missing?

comment:4 Changed 5 years ago by mojca (Mojca Miklavec)

Thank you for working on this! I have tried perl5.30, which builds successfully

At least that is good news, which means that at least the problem was fixed somehow.

Please note that I'm not using Catalina yet, so my data point doesn't count, but I'm surprised that there is not a lot more error reports than this one. Admittedly though, xcode 11 breaks for just about everyone in plenty of other ways.

(but many ports depend on perl5.28...).

We should actually fix this as soon as possible anyway, but we probably cannot do that fast enough without help. If you are volunteering, I gladly provide instructions.

(And no, there's nothing obvious that you might be doing wrong.)

comment:5 Changed 5 years ago by nombak

Since the issue is critical for me, I'd like to volunteer. However, I'm not sure whether I'm really able to that, depending on the instructions :-)

comment:6 Changed 5 years ago by stromnov (Andrey Stromnov)

Please, try to disable parallel build (works for me).

comment:7 Changed 5 years ago by nombak

Disabling parallel build is also a workaround for me. Thank you!

comment:8 Changed 5 years ago by mjwybrow (Michael Wybrow)

Cc: mjwybrow added

comment:9 Changed 5 years ago by mojca (Mojca Miklavec)

Once https://github.com/macports/macports-ports/pull/5457 gets merged we should address #58361, but probably going straight to 5.30 rather than to 5.28 first.

Changing individual ports is pretty straightforward: just change 5.26 or 5.28 to 5.30. Ideally make sure if any port depends or is a dependent of that port (visit https://ports.macports.org/port/<name>). Sometimes several ports need to be updated at the same time. So ... after changing 5.26 or 28 to 5.30 ... just check if the port still builds ok (for those of ports for which you care also check if they work fine) and open a pull request.

Then again ... there are lots of ports, so one option is to simply keep replacing numbers and leaving it to CI infrastructure to test the builds. That's still much better than not doing any work at all.

comment:10 Changed 5 years ago by yuvalx

Hi,

for me the issue was that in one of the Makefiles ABSPERL was set incorrectly to /miniperl

Entering /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_lang_perl5/perl5.28/work/perl-5.28.2

Finding the wrong Makefile (using the directory from the log). Replacing it with

ABSPERL = /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_lang_perl5/perl5.28/work/perl-5.28.2/miniperl

Then manually running:

sudo make -j 12 -w all

Then afterwards continuing the port installation worked for me (adjust -j 12 to your number of of cores). Not sure it's easier than disabling parallel build but it worked.

comment:11 Changed 5 years ago by MasakiOita

Cc: MasakiOita added

comment:12 Changed 5 years ago by paxperscientiam (Chris)

just noting that perl5.28 also failed to build for me on Catalina. Fortunately, disabling parallel building worked for me as well. For posterity, here is the command I used: sudo port install perl5.28 use_parallel_build=no. According to docs, this should work also: sudo port install PORT build.jobs=1

comment:13 Changed 5 years ago by danielseemaier (Daniel Seemaier)

perl5.28 failed to build for me as well but disabling parallel building didn't fix it. For me the issue was a supposedly wrong value for BPPARGS in /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_lang_perl5/perl5.28/work/perl-5.28.2/ext/Tie-Hash-NamedCapture/Makefile: it was set to -typemap '/lib/ExtUtils/typemap' but the correct path was ../../lib/ExtUtils/typemap.

comment:14 Changed 5 years ago by beeuhtricks (Beatrix Klebe)

Discovered this while attempting to install git.

comment:15 in reply to:  10 Changed 5 years ago by beeuhtricks (Beatrix Klebe)

Replying to yuvalx:

Then afterwards continuing the port installation worked for me (adjust -j 12 to your number of of cores). Not sure it's easier than disabling parallel build but it worked.

But this still solves a different problem than disabling parallel builds would, right? Because mine wasn't fixed by disabling them, but was fixed by setting ABSPERL = ../../miniperl.

Last edited 5 years ago by beeuhtricks (Beatrix Klebe) (previous) (diff)

comment:16 Changed 5 years ago by MaddTheSane (C.W. Betts)

Installing Perl 5.26 first seemed to work for me.

comment:17 Changed 5 years ago by alexanha

For those who don't get the issue fixed by setting use_parallel_build=no, try cleaning the port first and then reinstall, so run sudo port clean --all perl5.28 and then sudo port install perl5.28 use_parallel_build=no. This did the trick in my case.

comment:18 Changed 5 years ago by thenickdude (Nicholas Sherlock)

Cc: thenickdude added

comment:19 Changed 5 years ago by jimsiff (Jim Sifferle)

I can confirm that perl5.28 installs fine for me on Catalina after a 'sudo port clean --all perl5.28' then 'sudo port install perl5.28 use_parallel_build=no'. Thanks for working out this issue so quickly.

comment:20 Changed 5 years ago by ktoksoz (Koray Toksoz)

I can confirm that it works when building with use_parallel_build=no flag. But you must first clean the previous build like @alexanha said. If you have any files left in the installation directory from previous install or you add some files manually, build completes but installation does not. In my case, i had to manually delete some dylibs. Cleaning the build does not delete these manually added files.

Changed 5 years ago by knightjp

Perl5.28 still failing.

Changed 5 years ago by knightjp

Attachment: main.2.log added

Main - 2

comment:21 Changed 5 years ago by mojca (Mojca Miklavec)

In 7b977ef7ce92037f9b0a85d0b1045c2fc82d9bc4/macports-ports (master):

perl5: avoid parallel builds on Catalina

See: #59207

comment:22 Changed 5 years ago by Knapoc

I still have issues installing perl5.28 too. The main error I get is:

:info:build dyld: Library not loaded: /opt/local/lib/perl5/5.28/darwin-thread-multi-2level/CORE/libperl.dylib
:info:build   Referenced from: /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_lang_perl5/perl5.28/work/perl-5.28.2/dist/Storable/../../perl
:info:build   Reason: image not found

Looks like the same issue as in https://trac.macports.org/ticket/58572

Version 1, edited 5 years ago by Knapoc (previous) (next) (diff)

comment:23 Changed 5 years ago by mojca (Mojca Miklavec)

@Knapoc: can you please provide full logs, possibly submit them under #58572?

The reporter of #58572 could no longer reproduce it after a while, so we could not figure out what was wrong (i suspect that something went wrong with platform version identification).

comment:24 Changed 5 years ago by mojca (Mojca Miklavec)

Cc: Knapoc added

comment:25 Changed 4 years ago by chrstphrchvz (Christopher Chavez)

perl5.28 @5.28.3_1 is known to build on macOS 10.15. Are there any issues remaining, or can this ticket be closed?

comment:26 Changed 4 years ago by chrstphrchvz (Christopher Chavez)

Cc: chrstphrchvz added

comment:27 Changed 3 years ago by mojca (Mojca Miklavec)

Resolution: worksforme
Status: assignedclosed

I'm closing the issue for now. If there are further issues, we need more details.

Note: See TracTickets for help on using tickets.