[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Hamlib Perl bindings



Hello,

it appears to me that the Debian libhamlib2-perl package is broken.

I first tried to compile hamlib with all bindings myself, but
ultimatively failed. Tcl- and Python bindings worked, Perl bindings
didn't (occasional segfaults, nonsense values when querying the rig
etc).

Then I apt-get'ed (without first removing the remains of my own
compilation attempts) libhamlib2, libhamlib2-perl, libhamlib-dev,
libhamlib-utils and Hamlib.pm worked fine.

On another machine however, with a fresh install of Debian 3.1, Hamlib.pm
with the packages above installed does *not* work:

,------[ perl -e 'use Hamlib' ]----------------------------------------
| Can't load '/usr/lib/perl5/auto/Hamlib/Hamlib.so' for module Hamlib:
| /usr/lib/perl5/auto/Hamlib/Hamlib.so: undefined symbol: hamlib_version
| at /usr/lib/perl/5.8/DynaLoader.pm line 225.
|  at /usr/lib/perl5/Hamlib.pm line 11
`----------------------------------------------------------------------

And a quick check revealed:

,------[ ldd -r /usr/lib/perl5/auto/Hamlib/Hamlib.so ]-----------------
|        libc.so.6 => /lib/libc.so.6 (0x4010d000)
|        /lib/ld-linux.so.2 (0x80000000)
| undefined symbol: hamlib_version    (/usr/lib/perl5/auto/Hamlib/Hamlib.so)
| undefined symbol: hamlib_copyright  (/usr/lib/perl5/auto/Hamlib/Hamlib.so)
| [... a million more undefined symbols ...]
`----------------------------------------------------------------------

Oops. But why does it work on my other system? Because there is
another Hamlib.so, left from my own compilation, which differs 
from the one from the Debian package:

1138578 2007-08-07 02:53 /usr/local/lib/perl/5.8.8/auto/Hamlib/Hamlib.so (mine)
1067800 2007-01-21 19:50 /usr/lib/perl5/auto/Hamlib/Hamlib.so (debian)

And this Hamlib.so seems to be ok, a check with ldd shows some
undefined symbols (Perl_sv_free, Perl_croak_nocontext, ..) but all the
hamlib symbols seem to be defined.

Replacing the original Debian Hamlib.so with this one on my fresh test
system resulted in a functional Hamlib.pm.

Can anyone replicate/confirm/explain this problem?

Thanks & 73,
-- 
Fabian Kurz, DJ1YFK * Dresden, Germany * http://fkurz.net/



Reply to: