plagger環境構築までの道3 cpanmで依存関係自動解決
- 先にまとめ
- yum install openssl-devel expat-devel db4-devel libxml2-devel
- cpanm で足りないモジュールをガンガン入れる。
// cpanm $ mkdir ~/bin $ wget http://xrl.us/cpanm $ chmod +x cpanm $ cd - // local::lib $ wget http://search.cpan.org/CPAN/authors/id/G/GE/GETTY/local-lib-1.006007.tar.gz // cpanm で local::lib 入れてみる (ローカルtar.gzもOKなのか!万能すぎる!) $ cpanm local-lib-1.006007.tar.gz Fetching file:///tmp/mio/local-lib-1.006007.tar.gz ... OK Configuring local-lib-1.006007 ... OK Building and testing local-lib-1.006007 for local-lib-1.006007.tar.gz ... OK Successfully installed local-lib-1.006007 $ perldoc -l local::lib /home/mio/perl5/perlbrew/perls/perl-5.12.1/lib/site_perl/5.12.1/local/lib.pm // 横道にそれたのでここからはインターネット接続必須 // cpanmアップグレード $ cpanm App::cpanminus // $ cd plagger/ $ cpanm -L ~/perl5/ . ← 以下エラー対処したらこれ実行 // Module::Install 無くてエラーするので $ cpanm -L ~/perl5/ Module::Install Running Makefile.PL include /tmp/mio/plagger/inc/Module/Install.pm Bareword "use_test_base" not allowed while "strict subs" in use at Makefile.PL line 114. Execution of Makefile.PL aborted due to compilation errors. -> N/A -> FAIL Configure failed for .. See /home/mio/.cpanm/build.log for details. // YAML, Test::Base入れる local指定しないで perlbrew のところに入れたほうがいい? $ cpanm -L ~/perl5/ YAML $ cpanm -L ~/perl5/ Test::Base // なんかいろいろ入っていく。。 // そのうち繰り返してると入らなくなるのでまた個別で対応 build.log 見ながら。 // これは前引っかかった。素直にrootでrpm入れる。 Expat.xs:12:19: error: expat.h: そのようなファイルやディレクトリはありません $ wget http://vault.centos.org/5.4/os/i386/CentOS/expat-devel-1.95.8-8.2.1.i386.rpm # rpm -ivh expat-devel-1.95.8-8.2.1.i386.rpm // 今度はopenssl のヘッダか。 SSLeay.xs:98:25: error: openssl/err.h: そのようなファイルやディレクトリはありません # yum install openssl-devel // メモし忘れた dh.h がないとか出てたはず。 # yum install db4-devel // これも前引っかかった looking for -lxml2... no looking for -llibxml2... libxml2 not found Try setting LIBS and INC values on the command line Or get libxml2 from http://xmlsoft.org/ If you install via RPMs, make sure you also install the -devel RPMs, as this is where the headers (.h files) are. # yum install libxml2-devel あとは $ perl Makefile.PL [y] とか [n] 聞かれてもずっと Enter // $ perl plagger -v Plagger version 0.7.17
- 参考
ああ、これはひどいorz。PlaggerFAQ - Plagger - TracにYAMLとModule::InstallとTest::Baseを入れとけとあるな。
http://d.hatena.ne.jp/dacs/20061201/1164899688