Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl Monk, Perl Meditation
 
PerlMonks  

Problem executing GD module

by bar10der (Beadle)
on Aug 03, 2005 at 15:03 UTC ( [id://480504]=perlquestion: print w/replies, xml ) Need Help??

bar10der has asked for the wisdom of the Perl Monks concerning the following question:

Hi Monks, I have installed GD under perl 5.6.1 and also all the modules listed in the INSTALL file. I am getting follwoing error while exuting my script

----

ld.so.1: /usr/bin/perl: fatal: relocation error: file /usr/perl5/site_perl/5.6.1/sun4-solaris-64int/auto/GD/GD.so: symbol gdImagePngPtr: referenced symbol not found

Killed

----

Can anyone help please? Best regards,

Replies are listed 'Best First'.
Re: Problem executing GD module
by blazar (Canon) on Aug 03, 2005 at 15:14 UTC
    The important bit of information, which by pure chance happens to be missing here, is how exactly you installed it. CPAN.pm should take of everything for you, including dependencies, if you instruct it to do so.
Re: Problem executing GD module
by Joost (Canon) on Aug 03, 2005 at 15:17 UTC
    Did you compile the module yourself or installed a binary version? If you compiled it yourself, make sure you also run "make test" before installing.

    See also this note from the Makefile.PL of the latest GD version:

    NOTICE: This module requires libgd 2.0.25 or higher. it will NOT work with earlier versions. If you are getting compile or link errors, then please get and install a new version of libgd from www.boutell.com. Do NOT ask Lincoln for help until you try this.
      Yes, I did install GD.pm myself

      Also I did install libgd 2.0.33 under default location ie. /usr/local/lib

      However when I run make test I get following error

      PERL_DL_NONLAZY=1 /usr/bin/perl -Iblib/arch -Iblib/lib -I/usr/perl5/5. +6.1/lib/sun4-solaris-64int -I/usr/perl5/5.6.1/lib -e 'use Test::Harne +ss qw(&runtests $verbose); $verbose=0; runtests @ARGV;' t/*.t t/GD..........Can't load './blib/arch/auto/GD/GD.so' for module GD: ld +.so.1: /usr/bin/perl: fatal: relocation error: file ./blib/arch/auto/ +GD/GD.so: symbol gdImageCreateFromPng: referenced symbol not found at + /usr/perl5/5.6.1/lib/sun4-solaris-64int/DynaLoader.pm line 206. Compilation failed in require at t/GD.t line 13. BEGIN failed--compilation aborted at t/GD.t line 13. t/GD..........dubious Test returned status 255 (wstat 65280, 0xff00) DIED. FAILED tests 1-10 Failed 10/10 tests, 0.00% okay t/Polyline....Can't load 'blib/arch/auto/GD/GD.so' for module GD: ld.s +o.1: /usr/bin/perl: fatal: relocation error: file blib/arch/auto/GD/G +D.so: symbol gdImageCreateFromPng: referenced symbol not found at /us +r/perl5/5.6.1/lib/sun4-solaris-64int/DynaLoader.pm line 206. Compilation failed in require at blib/lib/GD/Polyline.pm line 45. BEGIN failed--compilation aborted at blib/lib/GD/Polyline.pm line 45. Compilation failed in require at t/Polyline.t line 10. BEGIN failed--compilation aborted at t/Polyline.t line 10. t/Polyline....dubious Test returned status 255 (wstat 65280, 0xff00) DIED. FAILED test 1 Failed 1/1 tests, 0.00% okay Failed Test Stat Wstat Total Fail Failed List of Failed ---------------------------------------------------------------------- +--------- t/GD.t 255 65280 10 20 200.00% 1-10 t/Polyline.t 255 65280 1 2 200.00% 1 Failed 2/2 test scripts, 0.00% okay. 11/11 subtests failed, 0.00% okay +. *** Error code 2 make: Fatal error: Command failed for target `test_dynamic'
Re: Problem executing GD module
by fauria (Deacon) on Aug 03, 2005 at 16:12 UTC
    It seems you are trying to use GD bindigs for a shared object different than the one you have already installed (it can be either newer or older, symbols may vary in both cases).

    Make sure both Perl-GD and libgd versions are the same.
      >>Make sure both Perl-GD and libgd versions are the same.

      Sorry but not sure how to get around this. I am not very good at UNIX, so if you could give me some lead, I'll greatly appreciate.

        I see you are using Solaris. Here you can find a description of the relocation process. The error you are having is explained under the "Relocation Error" section.

        I dont know so much about Solaris, but it mught have some kind of package management tools, such as emerge, apt or yum in Linux. Try to install the GD library provided by you package manager, and then install Perl-GD through CPAN, to ensure it is compiled against the library you already have.
        Get the latest versions of both.

        I'm not really a human, but I play one on earth. flash japh

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: perlquestion [id://480504]
Approved by Joost
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others sharing their wisdom with the Monastery: (5)
As of 2024-04-20 00:23 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found