I have a Perl module, with a large block of CPP subroutines. I have read numerous references on how to link a library, but nothing seems to work. The Inline code compiles correctly, but the functions which require the library (libtiff) fail to be bound to Perl (others bind just fine).
Errors involving failure to bind usually mean that the XS compiler doesn't know how to handle conversions between perl and the C type that the inline function returns and/or takes as its argument(s).
This can be remedied by providing an appropriate typemap - or by maybe providing some 'wrapper code' that uses only those C types with which the XS compiler is already familiar (if that's viable).
The code you supplied looks ok to me. I can't see that there will be any problem in accessing the library - you just have to find a way to handle the perl/C-type conversions. (At least that's the way it looks to me on the basis of the information you provided.)
Cheers, Rob
--
Any emails containing attachments will be deleted from my ISP's mail server before I even get to see them. If you wish to email me an attachment, please provide advance warning so that I can make the necessary arrangements.