I test my GD module to check whether it can be used since there are too many errors when install GD.
the test program is copied from a website:
********************************************** #!/usr/bin/perl -w
use strict;
use GD; use GD::Graph::linespoints;
print "Content-type: image/png\n\n"; my @data = ( [qw(Jan Feb Mar April May June July August Sep)], [undef, 52,53,54,55,56,undef,58,59], [60, 61,61,undef,68,66,65,61,undef], );
my $chart = GD::Graph::linespoints->new(700,500); $chart->set_x_label_font("/apile/AVBKV.TTF",10); $chart->set_y_label_font("/apile/AVBKV.TTF",10); $chart->set_x_axis_font("/apile/AVBKV.TTF",10); $chart->set_y_axis_font("/apile/AVBKV.TTF",10); $chart->set_title_font("/apile/AVBKV.TTF",16); $chart->set( x_label => 'Month', y_label => '# Sell', title => 'First three quarters, 2000', y_long_ticks => 1, markers => [1,5], marker_size => 8, line_types => [4,1], line_width => 3, ); $chart->set_legend('outlet 1', 'outlet 2'); my $gd_object = $chart->plot([EMAIL PROTECTED]);
#make sure we are writing to a binary stream binmode STDOUT; # Convert the image to PNG and print it on standard output print $gd_object->png; ************************************************
When I run the program, it said: ***********************************
Can't load '/usr/lib/perl5/site_perl/5.8.6/i386-linux-thread-multi/auto/GD/GD.so' for module GD: libgd.so.2: cannot open shared object file: No such file or directory at /usr/lib/perl5/5.8.6/i386-linux-thread-multi/DynaLoader.pm line 230.
at test-GD.pl line 5
Compilation failed in require at test-GD.pl line 5.
BEGIN failed--compilation aborted at test-GD.pl line 5.
************************************
I check with CPAN by "perl -MCPAN -e shell"
cpan> install GD GD is up to date.
cpan> r GD All modules are up to date for GD
***********************************
I have updated the following package accrording to the README of GD module:
freetype-1.3.1.tar.gz gd-2.0.33.tar.gz jpegsrc.v6b.tar.gz libpng-1.2.8.tar.bz2 zlib-1.2.2.tar.gz
What I can do now? many thanks!! please also recommend some useful books or website for me to learn how to produce figure with perl, thanks.
-- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] <http://learn.perl.org/> <http://learn.perl.org/first-response>