#!/bin/sh ############################################################# # Program: cpan_modules.build # Author : Stuart Winter # Purpose: Build a package of CPAN modules via altertrack # Date...: 16-Oct-2003 ############################################################# #perl -MCPAN -e 'o conf prerequisites_policy follow' ############################################################# # DO NOT EVER BUILD THIS ON A MACHINE YOU USE DAILY # Use it on a dev box where it doesn't matter that it'll get # trashed. ############################################################# ORIGPATH=$PWD # Save me setting up CPAN on a fresh box # once you've done perl -MCPAN -eshell # and configured CPAN with a few mirrors and so on. # As it happes I *do* want this config being included within # my CPAN modules package. It saves me manually configuring CPAN # on every server I administrate. # If you want to leave it out of your package you'd move the # following line into 'perl.remove' cp -f $ORIGPATH/Config.pm /usr/lib/perl5/5.8.1/CPAN/ # Some of the modules require force installing because they expect # you to have local httpd, MySQL servers and so on which simply # aren't required to build the module. exec 3<&0 egrep -v "^$|^#" ${ORIGPATH}/modules.list | while read module ; do perl -MCPAN -e "force install ${module}" <&3 done exec 3<&- mkdir /install install -m644 $ORIGPATH/slack-desc /install