1) Housekeeping - My dev area was getting a lot of junk floating around, and rather than just go through and delete, I thought it better to restart
2) About time I upgraded to perl-5.10.1
3) I need to start up a VM soon, and thought it a good opportunity to set make notes about what was needed
4) cpan/cpanplus wasn't working for me
5) I've never had GD working properly, and I could be about to lose my desktop at work
So plenty of reasons. I also wanted to try to structure how I setup various apps, so that it should (in theory) be easier to upgrade an of them. Getting further on, I think this might not be so worthwhile, but at least it's a try.
Here is 'What I Have Done' so far
This gives me a base dev directory to use
Download the version of perl you want to install
Unarchive the download and go into the directory for created from unarchiving and do the following
./Configure -des -Dprefix=$HOME/dev/perl/
make test (go away and make a cup of tea)
This will now give you in $HOME/dev/perl/
Once you have done this, symlink this version to $HOME/dev/perl/current, and add $HOME/dev/perl/current/bin to $PATH
This should make your default perl $HOME/dev/perl/current/bin/perl
Since you have done this, if you now want to download and try another perl, then you can do the same, and just switch the current softlink
You need to download
unpack and install
(need to look at)
./configure --prefix=$HOME/dev --enable-shared --enable-static
CFLAGS="-I$HOME/dev/include" LDFLAGS="-L$HOME/dev/lib" ./configure --prefix=$HOME/dev
CFLAGS="-I$HOME/dev/include" LDFLAGS="-L$HOME/dev/lib" ./configure --prefix=$HOME/dev --with-png=$HOME/dev --with-freetype=$HOME/dev --with-jpeg=$HOME/dev
make INCLUDEDIRS="-I. -I$HOME/dev" LIBDIRS="-L$HOME/dev" LIBS="-lgd -lpng -lz -lm" CFLAGS="-O -DHAVE_LIBPNG"
For these, I chose not to create individual versions of them. You will also note that libpng is 1.2 and jpeg is V8 but says need to look at, since this doesn't seem to work with this version of gd. However, since I mostly create png images, I'm not too concerned at this time. Must sort it though eventually.
This is needed for installation of some CPAN modules
Follow instructions on how to install, using $HOME/dev as the prefix
Again, no version specific route taken
Download from Oracle
unarchive latest version and install
Again, no version specific route, and needed for some CPAN modules
cpanp is the recommended method to download and install modules from cpan
and the interactive shell will be launched
If this is the first time, then enter the following
s conf prereqs 1; s save
This will save some of the hassle of needing to confirm installation of required modules
These are chosen because I need to set up a webserver, I work in a Bio place, and some are personal choice. Obviously, if you need others, or not some of these, then pick and choose. They are also loaded in this order for convenience and dependencies.
To install a cpan module, just type
i Task::Moose (select all the optional loads)
i List::MoreUtils (This had a checksum error, so manually downloaded)
i DBD::mysql # force install if you've no test database available, also requires the mysql client development headers - mysql_config needs to be in your $PATH (probably ~/dev/bin).
i XML::Parser (again, I got a dodgy md5)
i Readonly (another dodgy md5)
i XML::FeedLite (causes lots of prereqs to be installed - would suggest a cup of tea if you have selected auto download of prereqs)
i Ace # force install if fails to make as it may have problems connecting to Ace database during tests
i Bio::ASN1::EntrezGene # force install if fails as it looks as though for tests it needs a non-existent CPAN module
i GD (Why has this failed tests?)
i B/BI/BIRNEY/bioperl-1.4.tar.gz # Requires sleepycat libdb-4 to pass tests
manually download and install DB_File - as you need to Change config.in to point at dev/lib and dev/include
manually download and install BerkeleyDB - as you need to Change config.in as above.
APACHE and MOD-PERL:
Apache = httpd-2.2.14;
in dev, mkdir -p apache/2.2.14
ln -s 2.2.14/ current
This gives space to install this version of apache into, and a softlink to the version we want to use (similar to perl above)
./configure --prefix=$HOME/dev/apache/2.2.14 LDFLAGS="-L/$HOME/dev/lib"
add $HOME/dev/apache/current/bin to $PATH
Get latest version of 2.0
# follow instructions, e.g. apxs is at $HOME/dev/apache/current/bin/apxs
Change/create the $HOME/dev/apache/current/conf/httpd.conf and $HOME/dev/apache/current/conf/perlconfig.ini as you need to.
Now the biggie. Catalyst has lots of dependencies. It will take some time, plus it is interactive.
Just install everything - except the extra DBD supports.
You can do them in your own time, but they may make the Install fall over now, which you don't want.
If you have got through this, then congrats.
I have also downloaded into my dev area subversion and git, and have tried to do ImageMagick (although this is erroring that my C compiler won't compile executables, even though it has done svn and git).
Retrieve the latest version and dependency from http://subversion.apache.org/source-code.html
unpack both, the dependency folder should end up in the same directory, and will then be installed with svn
mkdir -p $HOME/dev/subversion/
cd into unpacked folder
add $HOME/dev/subversion/current/bin to your $PATH
This will enable you to have/try multiple versions of svn in the same way as Perl and Apache above
Retrieve the latest version from http://git-scm.com/
mkdir -p $HOME/dev/git/
make install (had to do as root)
problem with my gcc version at this time
mkdir -p $HOME/dev/imageMagick/
./configure PREFIX=/Users/ajb/dev/imageMagick/6.5.9 EXEC-PREFIX=/Users/ajb/dev/imageMagick/6.5.9 LIBS=-l/Users/ajb/dev/lib --enable-shared --disable-static
After this, you should have a nice fairly 'clean' version of a dev area. If you want ot install other stuff, then I would recommend the method suggested for versioning the download you have. (I can also recommend the MOCA installation idea for mysql, although I choose to not have that in my dev area).
Once inside this, I then create folders for my projects, using svn or git to version control within those folders, just adding the directories to my path as I need to.
Note: I am using MAC OSX Leopard. At times for the make install, I have needed to sudo make install. I accept no liability for anything that happens should you follow these instructions on any system, but hope that they might be useful for anyone who would like to set up a dev/test area, but are not sure how to go about it.