Perl 5.8.0 是否包含符号 Perl_sv_2pv?
Hi friends,
Perl 5.8.0 seems a bit strange. I encounterred a trouble in my dynamic library which uses this symbol of Perl:
ld.so.1: perl: fatal: relocation error: file /opt/mylib/libAPIPerl.so: symbol Perl_sv_2pv: referenced symbol not found
Killed
Solaris 9/10
Perl was built from source code tar ball.
zcyds4d6-85> perl -v
This is perl, v5.8.0 built for sun4-solaris-64int
zcyds4d6-89> nm /bin/perl | grep -i Perl_sv_2pv
[2590] | 597800| 2980|FUNC |GLOB |0 |11 |Perl_sv_2pv_flags
[2234] | 597504| 28|FUNC |GLOB |0 |11 |Perl_sv_2pv_nolen
[2106] | 601164| 76|FUNC |GLOB |0 |11 |Perl_sv_2pvbyte
[921] | 601140| 24|FUNC |GLOB |0 |11 |Perl_sv_2pvbyte_nolen
[1338] | 601264| 76|FUNC |GLOB |0 |11 |Perl_sv_2pvutf8
[1487] | 601240| 24|FUNC |GLOB |0 |11 |Perl_sv_2pvutf8_nolen
But from perl5.6.1 to perl 5.8.8, I can find the reference in every release except 5.8.0.
Perl5.8.4 sample:
nm /usr/local/bin/perl | grep -i Perl_sv_2pv
[1926] | 596152| 28|FUNC |GLOB |0 |9 |Perl_sv_2pv
[1540] | 596180| 2872|FUNC |GLOB |0 |9 |Perl_sv_2pv_flags
[1677] | 595996| 28|FUNC |GLOB |0 |9 |Perl_sv_2pv_nolen
[2571] | 599204| 132|FUNC |GLOB |0 |9 |Perl_sv_2pvbyte
[2454] | 599180| 24|FUNC |GLOB |0 |9 |Perl_sv_2pvbyte_nolen
[2084] | 599360| 132|FUNC |GLOB |0 |9 |Perl_sv_2pvutf8
[2450] | 599336| 24|FUNC |GLOB |0 |9 |Perl_sv_2pvutf8_nolen
The Perl 5.8.0 delta ( http://search.cpan.org/dist/perl/pod/perl58delta.pod#Perl_get_sv ) said that it that is no more the case. what does it mean?
Perl_get_sv
You may get errors like 'Undefined symbol "Perl_get_sv"' or "can't resolve symbol 'Perl_get_sv'", or the symbol may be "Perl_sv_2pv". This probably means that you are trying to use an older shared Perl library (or extensions linked with such) with Perl 5.8.0 executable. Perl used to have such a subroutine, but that is no more the case. Check your shared library path, and any shared Perl libraries in those directories.
Sometimes this problem may also indicate a partial Perl 5.8.0 installation, see "Mac OS X dyld undefined symbols"
I also found a link about this issue, but it did not say whether this symbol was kept in Perl 5.8.0.
http://www.gossamer-threads.com/ ... post_view_printable;post=6902;list=modperl
Why is Perl 5.8.0 so strange? How to resolve this problem?
Thanks in advance.