Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to statically link on Windows? #29

Open
doivosevic opened this issue Apr 30, 2017 · 1 comment
Open

How to statically link on Windows? #29

doivosevic opened this issue Apr 30, 2017 · 1 comment

Comments

@doivosevic
Copy link

Hi,
I'm aware that this is not a problem specific for this library but I think Haskell generally has a problem that this information is hard to find and this is the first library I'm using that's supposed to used satically linked files. How do I include this into my project?

I did stack install text-icu --extra-include-dirs=C:\msys64\icu4c-59_1-Win64-MSVC2015\include --extra-lib-dirs=C:\msys64\icu4c-59_1-Win64-MSVC2015\lib64

and I tried putting the dll into my .stack-work\install\28cbf0ed\bin folder but when I try stack build I get


ghc.EXE: unable to load package `text-icu-0.7.0.1'
ghc.EXE: addDLL: icuuc59.dll (Win32 error 126): The specified module could not be found.
ghc.EXE: Could not load `icuuc59.dll'. Reason: addDLL: could not load DLL

@alanz
Copy link

alanz commented Jul 20, 2017

From haskell/lsp#41 (comment)

"
Thanks for your help, I got it building, although not by using pacman. Here are the steps:

Download ICU4C for Windows 64-bit from the download page here. The newest version (59.1 at the time of writing, direct link here) is just fine.
Extract the archive to some location, lets say C:\icu.
Open a terminal, navigate to C:\icu\bin64
Make a symbolic link: mklink icudt.dll icudt59.dll
Make a symbolic link: mklink icuin.dll icuin59.dll
Make a symbolic link: mklink icuuc.dll icuuc59.dll
Then clone the repository and build it with some additional references to the extracted archive:

git clone https://github.com/alanz/haskell-lsp
cd haskell-lsp
stack build --extra-include-dirs="C:\icu\include" --extra-lib-dirs="C:\icu\lib64" --extra-lib-dirs="C:\icu\bin64"
"

Perhaps these instructions (or similar) should be added to the README.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants