Don't give up on bzip2 or gzip just because they may not always be in the same place.
It may be simpler to write a routine to find the executable and run it than to get a module installed across all of those machines... If you can guarantee that at least gzip is on all the boxes, it shouldn't be too hard, in fact...
sub findCompressor {
my @paths=(
"/usr/bin".
"/bin",
"/usr/local/bin",
"/usr/share/bin",
"/opt/bin",
"$ENV{HOME}/bin",
"$ENV{HOME}/local/bin",
);
foreach my $prog('bzip2','gzip','compress') {
foreach my $dir(@paths) {
my $path="$dir/$prog";
return $path if -x $path;
}
}
# return some default non-compressing compressor??
}
# run once
my $compressor=findCompress();
Not sure if that makes sense in your case, but I think it would work...
--
Mike |