I've created a GraphicsKit package for the "Fat Camel" package, and uploaded it to SourceForge. As a reminder - these are Perl modules and the C libs they depend on for the Perl 5.8.4 distribution included in the CamelBones "Fat Camel" package.<snip>
Thanks Sherm,
I have a few "Newbie" questions.
I installed Fat Camel a few days ago and all my perl scripts that used modules I'd previously installed broke. I guessed that they were now using your 5.8.4 perl and I fixed them by adding this line:
use lib "/Library/Perl/5.8.1/";
Today I installed the GraphicsKit and tried running a test script using Imager without the "use lib" line and I get this error.
------------------
macbill$ perl thumbmake.pl favicon.bmp
dyld: perl can't open library: /usr/X11R6/lib/libSM.6.dylib (No such file or directory, errno = 2)
Trace/BPT trap
------------------
Since I had previously installed Imager and successfully ran the "thumbmake.pl" test script I added the "use lib" line to the script and tried it again, and it runs OK.
------------------ macbill$ perl thumbmake.pl favicon.bmp Storing image as: favicon_low.bmp ------------------
So, what am I doing wrong?
Here's the thumbmake.pl script I'm using to test Imager installed with the GraphicsKit:
------------------
#!/usr/bin/perl -w
use strict; use Imager;
die "Usage: thumbmake.pl filename\n" if !-f $ARGV[0];
my $file = shift;
my $format;
my $img = Imager->new(); $img->open(file=>$file) or die $img->errstr();
$file =~ s/\.[^.]*$//;
# Create smaller version my $thumb = $img->scale(scalefactor=>.3);
# Autostretch individual channels $thumb->filter(type=>'autolevels');
# try to save in one of these formats SAVE:
for $format ( qw( png gif jpg tiff ppm bmp ) ) {
# Check if given format is supported
if ($Imager::formats{$format}) {
$file.="_low.$format";
print "Storing image as: $file\n";
$thumb->write(file=>$file) or
die $thumb->errstr;
last SAVE;
}
}------------------
