Skip to content

GHC fails to configure on MacOS if Cuda is installed

Hello,

I had the following issue trying to build ghc (indirectly via stack)

[error] Running /usr/bin/make install in directory /Users/nehal/.stack/programs/x86_64-osx/ghc-8.0.2.temp/ghc-8.0.2/ exited with ExitFailure 2


mk/config.mk:521: *** missing separator.  Stop.

@(Stack/Setup.hs:991:21)
2017-10-16 07:16:01.831719: [error]
Error: Error encountered while installing GHC with
         make install
         run in /Users/nehal/.stack/programs/x86_64-osx/ghc-8.0.2.temp/ghc-8.0.2/

Here is the line from mk/config.mk:521:

519  WhatGccIsCalled       = /usr/bin/gcc
520  GccVersion            = 9.0.0
521  8.0
522  ifeq "$(phase)" "0" 
...

output from gcc:

nehal$ gcc -v
Configured with: --prefix=/Applications/Xcode.app/Contents/Developer/usr --with-gxx-include-dir=/usr/include/c++/4.2.1
Apple LLVM version 9.0.0 (clang-900.0.37)
Target: x86_64-apple-darwin16.7.0
Thread model: posix
InstalledDir: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin
Found CUDA installation: /usr/local/cuda, version 8.0

It looks like the version detection is getting confused by the cuda installation (and so is thinking the version is something like "9.0.0\n8.0")

This could be something for further upstream (e.g. autotools mainainters), but I'm just rebooting my "try to grok Haskell" efforts, so I am going to take the lazy approach and report it here....

Thanks for ghc!

(downstream bug report is here: https://github.com/commercialhaskell/stack/issues/1582#issuecomment-346917482 -- two others have hit this in the past month or so)

Trac metadata
Trac field Value
Version 8.0.2
Type Bug
TypeOfFailure OtherFailure
Priority normal
Resolution Unresolved
Component Build System
Test case
Differential revisions
BlockedBy
Related
Blocking
CC
Operating system
Architecture
To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information