简体   繁体   English

如何安装没有依赖项的perl模块

[英]How to install a perl module without a dependency

I've got a perl module (Email::AutoReply) which has BerkeleyDB listed in the README as an optional dependency. 我有一个perl模块(Email :: AutoReply),它在README中将BerkeleyDB作为可选依赖项列出。 When you try to install it with cpan or cpanminus, it tries to install BerkeleyDB as well. 当您尝试使用cpan或cpanminus安装它时,它也会尝试安装BerkeleyDB。 The problem is that no matter what I do, BerkeleyDB fails to install with a long list of errors, even though I meet all the requirements. 问题是,无论我做什么,即使我满足所有要求,BerkeleyDB都无法安装,并且会列出很多错误。 This is preventing me from installing Email::AutoReply, even though it's supposed to be an optional thing. 这使我无法安装Email :: AutoReply,即使它应该是可选的。

So, how do I install a module without one of it's dependencies? 那么,如何安装不依赖模块的模块? Can I remove the dependency somehow? 我可以以某种方式删除依赖吗? Is there some command line option for this? 为此有一些命令行选项吗?

After installing the other dependencies (which you probably have done from your earlier attempts), 在安装了其他依赖项之后 (您可能是从先前的尝试中完成的),

cd /tmp
wget http://search.cpan.org/CPAN/authors/id/A/AM/AMONSEN/Email-AutoReply-1.04.tar.gz
tar xvzf Email-AutoReply-1.04.tar.gz
cd Email-AutoReply
perl Makefile.PL && make test && make install
cd ..
rm -rf Email-AutoReply

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM