perl インストール
perlの現在の最新版(5.12.1)をソースからインストールしてみた。
(とあるサイトを参考にしつつ、既存のモノと共存する形で。。。)
# wget http://www.cpan.org/src/5.0/perl-5.12.1.tar.gz # tar xzvf perl-5.12.1.tar.gz # time { sh Configure -Dprefix=/usr/local/perl-5.12.1 -de && nice -19 make && make test; }
超ミニマム構成のCentOSだったので、gccが入ってなかった。。
Use which C compiler? [cc] ./trygcc: line 10: cc: command not found Uh-oh, the C compiler 'cc' doesn't seem to be working. ./trygcc: line 25: gcc: command not found ./checkcc: line 10: cc: command not found Uh-oh, the C compiler 'cc' doesn't seem to be working. You need to find a working C compiler. Either (purchase and) install the C compiler supplied by your OS vendor, or for a free C compiler try http://gcc.gnu.org/ I cannot continue any further, aborting. real 0m2.863s user 0m0.080s sys 0m1.855s
ということでgccを含めた「Development Tools」グループをまるっとインストール
# yum grouplist # yum groupinfo "Development Tools" # yum groupinstall "Development Tools"
再挑戦
# time { sh Configure -Dprefix=/usr/local/perl-5.12.1 -de && nice -19 make && make test; }
なんだかエラーが出ているけど、大丈夫なのかな。。。
Failed 1 test out of 1688, 99.94% okay. ../cpan/Memoize/t/expmod_t.t ### Since not all tests were successful, you may want to run some of ### them individually and examine any diagnostic messages they produce. ### See the INSTALL document's section on "make test". ### You have a good chance to get more information by running ### ./perl harness ### in the 't' directory since most (>=80%) of the tests succeeded. ### You may have to set your dynamic library search path, ### LD_LIBRARY_PATH, to point to the build directory: ### setenv LD_LIBRARY_PATH `pwd`; cd t; ./perl harness ### LD_LIBRARY_PATH=`pwd`; export LD_LIBRARY_PATH; cd t; ./perl harness ### export LD_LIBRARY_PATH=`pwd`; cd t; ./perl harness ### for csh-style shells, like tcsh; or for traditional/modern ### Bourne-style shells, like bash, ksh, and zsh, respectively. u=0.50 s=21.62 cu=143.07 cs=221.79 scripts=1688 tests=348969 make: *** [test] Error 1 real 19m57.616s user 3m43.590s sys 7m16.582s
あまり気にしないでインストール実行。。。
# time { make install;}
インストール自体はさくっと完了。
make[1]: Leaving directory `/home/tintin/Perl/perl-5.12.1' real 0m54.492s user 0m22.928s sys 0m8.738s
既存のperlはこっち
# perl -v This is perl, v5.8.8 built for i386-linux-thread-multi Copyright 1987-2006, Larry Wall Perl may be copied only under the terms of either the Artistic License or the GNU General Public License, which may be found in the Perl 5 source kit. Complete documentation for Perl, including FAQ lists, should be found on this system using "man perl" or "perldoc perl". If you have access to the Internet, point your browser at http://www.perl.org/, the Perl Home Page.
新しいperlはこちら。
# /usr/local/perl-5.12.1/bin/perl -v This is perl 5, version 12, subversion 1 (v5.12.1) built for i686-linux Copyright 1987-2010, Larry Wall Perl may be copied only under the terms of either the Artistic License or the GNU General Public License, which may be found in the Perl 5 source kit. Complete documentation for Perl, including FAQ lists, should be found on this system using "man perl" or "perldoc perl". If you have access to the Internet, point your browser at http://www.perl.org/, the Perl Home Page.