The latest Perl localizes very nicely. Following these very simple instructions I was able to install it into my home directory. I then modified my .bash_profile to search the local perl bin area:
[jnapiorkowski@perlbuilder ~]$ cat .bash_profile
# .bash_profile# Get the aliases and functions
if [ -f ~/.bashrc ]; then
. ~/.bashrc
fi# User specific environment and startup programs
PATH=$HOME/bin:$HOME/local/bin:$PATH
In this case I added "$HOME/loca/bin" so that search path lookups find my Perl over the system Perl. I then used "http://github.com/jjn1056/catalyst-app-example-locallibapp/tree" to setup my fully local::lib deployments of my various catalyst applications. Everything worked as expected.
Result? Localized Perl that is separate from you system Perl, plus local::lib for each deployed application, keeping everything nice and cleanly separated. Now when I need to deploy this to stage and then to production I can simple use rsync against my home directory and target my stage or production boxes (since my build box is a template for stage and production). Combined with CPAN::mini I could even have my own local cpan server with 'approved' versions of modules. Personally since I try to help fix stuff when it breaks, I try to grab the newest of everything, but if you are on a more conservative setup, looking at your own minicpan might be valuable.
[this is good] How have you worked around the File::HomeDir problem that you described in an earlier post? TIA
Posted by: Rick | 10/28/2009 at 01:39 PM
Yes, I believe two things have happened here. One, the Troubled Bits of File::HomeDir have been improved, namely Mac::Carbon has been updated and I find it compiles cleanly on my Power Book. Additionally CPAN has been patched to set the the CPAN home directory to your user directory instead of $HOME/Library .... which was a path with spaces that caused a lot of trouble for certain cpan modules. I'm not sure that patch is in the current cpan or not, but it should be out soon. Soon the good news is I find Catalyst and all my normal bits compile and install from CPAN without trouble. Just make sure your user directory isn't a path with spaces :), although even that problem should diminish over time with all the work on Strawberry Perl that involves fixing path related test and compile failures.So with Perl 5.10.1 and local lib per application I am very happy with cpan and with managing dependencies. This is a great improvement for this year and I think shows the vitality of the Perl community and its ability to address problems of this scale.
Posted by: John Napiorkowski | 10/28/2009 at 01:56 PM