defcfun cannot find foreign function in library

Mirko Vukovic mirko.vukovic at gmail.com
Wed Jun 26 15:01:50 UTC 2013


On Wed, Jun 26, 2013 at 8:40 AM, Reini Urban <rurban at x-ray.at> wrote:

> On Tue, Jun 25, 2013 at 3:22 AM, Luís Oliveira
> <loliveira at common-lisp.net> wrote:
> > On Tue, Jun 25, 2013 at 1:56 AM, Mirko Vukovic <mirko.vukovic at gmail.com>
> wrote:
> >> I am trying to link to a VISA library (VISA is used to control data
> >> acquisition instruments), visa32.lib compiled for Windows.  The library
> is
> >> shipped with Tektronix software.
> >
> > I'm surprised loading it works. That sounds like a static library.
> >
> >> Using `nm' I did find:
> >> 00000000 I __imp__viOpenDefaultRM at 4
> >> 00000000 T _viOpenDefaultRM at 4
>
> .lib is the naming convention for an MSVC import library, forwarding to a
> .dll.
> In cygwin and mingw it is usually named .dll.a.
> See the I type, and the __imp__ prefix.
>
> With gnu binutils you can find the matching dll
> (they have versioned names, and no symlink support)
> via dllimport -I libname
>

Did you mean dlltool (http://www.gnu.org/software/binutils/)


>
> --
> Reini Urban
> http://cpanel.net/   http://www.perl-compiler.org/
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mailman.common-lisp.net/pipermail/cffi-devel/attachments/20130626/d5907e00/attachment.html>


More information about the cffi-devel mailing list