Building Win32 DLLs: Manual is not up-to-date
Simon Marlow
simonmarhaskell at gmail.com
Wed Mar 1 08:08:05 EST 2006
Michael Marte wrote:
> I am trying to turn a prototype written in Haskell into something
> I can call from a Visual Studio C++ 6.0 program. (The prototype is
> so clean and fast that there is no point in recoding everything.)
> So I followed the instructions in section 11.5 of the ghc manual
> ("Building and using Win32 DLLs") and ended up as follows:
>
> $ ghc -c dllMain.c
> dllMain.c:4: warning: type defaults to `int' in declaration of `EXTFUN'
> dllMain.c:4: warning: parameter names (without types) in function
> declaration
> dllMain.c:4: warning: data definition has no type or storage class
> dllMain.c: In function `DllMain':
> dllMain.c:18: error: `__stginit_Adder' undeclared (first use in this
> function)
> dllMain.c:18: error: (Each undeclared identifier is reported only once
> dllMain.c:18: error: for each function it appears in.)
>
> Section 8.2 proposes to add
>
> extern void __stginit_Adder(void)
>
> which actually works.
docs fixed, thanks.
Simon
More information about the Glasgow-haskell-users
mailing list