[Haskell-cafe] Linker problems linking FFI import call in Windows

Olivier Boudry olivier.boudry at gmail.com
Wed Jul 16 02:38:33 EDT 2008


On Tue, Jul 15, 2008 at 11:51 PM, PJ Durai <pjdtech2000 at gmail.com> wrote:
> I am trying to import some functions from a windows DLL. I am getting
> strange errors. (This used to work with previous versions of GHC.  6.6
> I think.).

You may have to create an import library for the DLL. I had a similar
problem and solved it that way.

Look at http://www.emmestech.com/moron_guides/moron1.html for advices
on how to create such a library.

My problem was that the exports in the dll were prefixed with an
underscore. I had to remove them from the .def file before creating
the import library.

Best regards,

Olivier.


More information about the Haskell-Cafe mailing list