[GHC] #11072: Runtime linker doesn't search for DLLs referenced in import libraries on Windows
GHC
ghc-devs at haskell.org
Wed Nov 18 13:28:59 UTC 2015
#11072: Runtime linker doesn't search for DLLs referenced in import libraries on
Windows
-------------------------------------+-------------------------------------
Reporter: RyanGlScott | Owner: Phyx-
Type: bug | Status: new
Priority: normal | Milestone: 8.0.1
Component: Compiler | Version: 7.10.2-rc2
(Linking) |
Resolution: | Keywords:
Operating System: Windows | Architecture:
| Unknown/Multiple
Type of failure: Runtime crash | Test Case:
Blocked By: | Blocking:
Related Tickets: | Differential Rev(s):
Wiki Page: |
-------------------------------------+-------------------------------------
Comment (by YitzGale):
Replying to [comment:5 Matt]:
> If you check existing archive loading mechanics in GHCi it doesn't look
for `.lib` files either. Those files are usually produces by MSVC compiler
which its not officially supported by GHC as far as i know.
I'm not sure what you mean by "not officially supported". Specifying .lib
files + DLL files has always been the standard way to use FFI for third
party libraries on Windows.
> I think preferable way of getting libraries on Windows should be MSYS2
anyway as it uses the same compiler as GHC and already comes with really
big collection of packages.
MSYS2 is very nice, but its "really big collection of packages" is
insignificant compared to the amount of libraries compiled with MSVC and
available as lib + DLL. And that's just open source - for proprietary
libraries that commercial users of GHC need to link against, MSVC is
basically the only option. Mingw is designed to support those, and it has
always worked fine in the past.
MSYS2 is a rock-solid option, when it's available. And we were grateful
for that for {{{text-icu}}}. But is seems to me that it will always be a
fallback. The normal way to link to a third-party library on Windows is
with .lib files and DLLs.
--
Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/11072#comment:6>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
More information about the ghc-tickets
mailing list