Error installing perl using perlbrew on Big Sur

夙愿已清 提交于 2020-12-26 06:55:16

问题


I'm trying to install perl version 5.33.4 in my macOS environment using perlbrew. I cannot comprehend why it fails during installation.

I started installing perlbrew using \curl -L https://install.perlbrew.pl | bash, then I added in my zshenv this line: source ~/perl5/perlbrew/etc/bashrc and started installing perl with perlbrew install perl-5.33.4 command. I tried also with different perl versions, but the problem is the same.

This is the logged error:

# Failed test 20 - array should contain one result or more: libc => () at t/DynaLoader.t line 127
#      got "0"
# expected >= "1"
../ext/DynaLoader/t/DynaLoader.t ..................................... 
Failed 1/44 subtests 


Test Summary Report
-------------------
../ext/DynaLoader/t/DynaLoader.t                                   (Wstat: 0 Tests: 44 Failed: 1)
  Failed test:  20
Files=2652, Tests=1183275, 624 wallclock secs (25.86 usr  5.24 sys + 260.60 cusr 25.43 csys = 317.13 CPU)
Result: FAIL
make: *** [test_harness] Error 1
##### Brew Failed #####

How can I find a way to detect the problem and solve it? Thanks in advance to any suggestion.


回答1:


A change in macOS Big Sur has broken part of Perl's module-installing tool chain.

From the macOS Big Sur 11.0.1 Release Notes

New in macOS Big Sur 11.0.1, the system ships with a built-in dynamic linker cache of all system-provided libraries. As part of this change, copies of dynamic libraries are no longer present on the filesystem. Code that attempts to check for dynamic library presence by looking for a file at a path or enumerating a directory will fail. Instead, check for library presence by attempting to dlopen() the path, which will correctly check for the library in the cache. (62986286)

This is preventing Perl from being installed.

A ticket (#381) has been filed against ExtUtils-MakeMaker here. It is currently unresolved.

A ticket (#18406) has been filed against Perl itself here.




回答2:


It's something that perl needs to fix. There's perlbrew issue 701 that's related to how MakeMaker looks for libraries.



来源:https://stackoverflow.com/questions/65297237/error-installing-perl-using-perlbrew-on-big-sur

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!