Unless I'm horribly confused, why don't you just say, install apache to a folder, then copy that entire folder to the cd? Same with mysql/postgresql/whatever. Apache doesn't need anything else to run as far as I know, then just do the same thing with perl and create a batch script that looks like
start \apache\apache.exe
start \mysql\bin\mysqld-opt.exe
start \perl\bin\perl.exe \my\script
?