How do I call the "--enable-stdcall-fixup" parameter?

When building a DLL under Windows, I get the following output:

Linking main.exe ...
Warning: resolving _findPeaksWrapper by linking to _findPeaksWrapper@16
Use --enable-stdcall-fixup to disable these warnings
Creating library file: HSdll.dll.a
Use --disable-stdcall-fixup to disable these fixups

      

It is not clear to me where I should place the flag --enable-stdcall-fixup

. Typing in the field of ghc-options

my .cabal file gives a GHC error, and putting it in cc-options

or ld-options

seems to do nothing (warnings are still showing). Where should this flag go?

+3


source to share


1 answer


Googling indicates what --enable-stdcall-fixup

is the ld option. There are several different ways in which the final stage of the connection at the box office can occur, but in your case it seems to be

Cabal -> ghc (link step) -> gcc -> ld

      



so to fit this you must specify

ghc-options: -optl-Wl,--enable-stdcall-fixup

      

+1


source







All Articles