Closed AlexGoico closed 5 years ago
Hey @AlexGoico,
Based on your --verbose
output it seems like you may be experiencing this problem - would you please try running xcode-select --install
and see if that resolves the issue?
Running xcode-select --install
yields code-select: error: command line tools are already installed, use "Software Update" to install updates
. Upon opening "Software Update" I get a "Your Mac is up to date".
Any other suggestions I could try?
I see the same on 1.9.3. The config.log
shows a few errors:
Hey @AlexGoico and @mpereira - sorry it's taken me so long to respond.
I still can't reproduce this on my macOS Mojave machine, and I'm not sure what else to try at this point, but I wonder if the problem has something to do with installing via the Haskell Platform vs. the shell script method documented here (which is what I used).
I can see from Alex's original message that he used the Haskell Platform - did you as well, @mpereira?
This wouldn't be the first odd error I've seen on macos involving haskell platform — e.g. #4504
I tried installing from scratch on Mojave both by using homebrew and via the shell script method and the problem appears on both occasions. I also removed the command line tools and reinstalled them using xcode-select --install
, but that was of no help either. I think it might be caused by an error when trying to compile a C program on Mojave.
Cross-linking with this discussion on the gitter.im channel since it has some potentially useful diagnostic info.
Does this problem occur if you try manually download, unpacking, and ./configure
ing the GHC tarball for OS X?
No follow up, closing
Don't know if it's still relevant but I found a solution, instead of
xcode-select --install
, which doesn't install SDK_headers in Mojave, you should do:
cd /Library/Developer/CommandLineTools/Packages/
open macOS_SDK_headers_for_macOS_10.14.pkg
then follow the instructions from the wizard.
I found the solution here: https://stackoverflow.com/questions/19580758/gcc-fatal-error-stdio-h-no-such-file-or-directory
A PR to add that information to the FAQ doc or similar would definitely be welcome.
@valsan Even with running the solution you've posted I'm still receiving the same issues. Have you heard of anything like that happening still?
In my case the problem was about gawk. running stack
brew unlink gawk brew install awk
Ends up this was all a false alarm.
It was an old clang version blocking the apple version in my path (an old Anaconda installation).
General summary/comments
I am on MacOS Mojave (10.14) and am unable to get past stack setup.
Steps to reproduce
stack new projectName
stack setup
Expected
ghc to be installed into the project
Actual
Here is
stack setup --verbose
output.Stack version
Method of installation