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
Fix the Windows build #342
Conversation
Well spotted, thanks Ryan! |
By the way, did you perchance try to build |
No, but I can try that next :) |
Cool. Let me know how it goes (: |
Well, that went disastrously :) The proximal cause the failure I got when trying to build
This definitely seems like GHC's fault, though. I don't know what causes the GHC panic in particular, but that I've opened GHC Trac #13093 to track this GHC bug. |
You got much further than I expected! I though the mess of C++ that is Try installing |
Unfortunately, it looks like the MinGW-w64 build of |
FWIW, this error is also reproducible on OS X, so it might not be a Windows-exclusive bug for once ;) https://ghc.haskell.org/trac/ghc/ticket/13137 |
I have my custom shared libraries build of Thus |
@awson, thanks for the tip! After installing Yay! It wasn't totally trivial, though. Aside from needing to use GitHub repos for most the dependencies, I had to make a small patch to diff --git a/llvm-general/Setup.hs b/llvm-general/Setup.hs
index 37553d6..0686465 100644
--- a/llvm-general/Setup.hs
+++ b/llvm-general/Setup.hs
@@ -128,7 +128,7 @@ main = do
[llvmVersion] <- liftM lines $ llvmConfig "--version"
let sharedLib = case llvmVersion of
"3.2" -> "LLVM-3.2svn"
- x -> "LLVM-" ++ x
+ x -> "LLVM"
staticLibs <- liftM (map (fromJust . stripPrefix "-l") . words) $ llvmConfig "--libs"
systemLibs <- liftM (map (fromJust . stripPrefix "-l") . words) $ llvmConfig "--system-libs"
This is because for some bizarre reason, the dynamically linked LLVM library is called |
Whoo! Thanks for checking this works @RyanGlScott. RE dependencies, I'm just waiting on a GHC-8 compatible release of |
@RyanGlScott, LLVM upstream decided (or made mistake) to name
You can report it to upstream and MSYS2 will follow their solution. |
Good to know, @mati865. Once https://github.com/Alexpux/MINGW-packages/issues/2107 is fixed, my plan is to submit a patch to |
Once bscarlet/llvm-general#203 is merged into However, I'm not sure if |
Yeah, I have been wondering that as well \: |
In any case, my patch did get merged into |
That is interesting. If |
There were two sneaky issues preventing
accelerate
from building on Windows:There was a mysterious error about
ProcessId
being out of scope inData.Array.Accelerate.Debug
. As it turns out,ProcessId
was only being imported ifACCELERATE_DEBUG
was on, andProcessId
wasn't being used within an#if ACCELERATE_DEBUG ... #endif
.Even more mysteriously,
rotateDefault
was failing to typecheck. This led me to discover that theBitSize CULong
instance was using the size ofCULLong
, notCULong
! This matters for Windows, since the size ofCULong
is 4 bytes, and the size ofCULLong
is 8 bytes.