How can I safely compile a Perl 5.12 module for Perl 5.8.9?

做~自己de王妃 提交于 2019-12-06 03:56:32
Ether

If the module is available separately (i.e. "dual-lifed"), as both a standalone distribution and inside core Perl, then the standalone version is safe to install on an earlier Perl, assuming its Makefile allows it. That is, if you can do cpan <Module> and it builds and tests without errors, then you are good.

The only problem is if a module is not dual-lifed, which I opined about in this question -- which is where you are likely S.O.L.

If a perl core module is also available separately, that means that it is intended to work on older perls (unless it explicitly requires some version of perl), and if it doesn't, that's a bug.

That said, 5.10 was released almost three years ago, and you are going to start seeing more and more problems using newer modules with older versions of perl.

cpan or cpanplus will handle dependencies for you.

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