Using the latest release (currently stack-1.7.1).
Upgraded system gcc to gcc-7.3.0 last week and now when I try to stack setup I get:
<no location info>: error:
Warning: Couldn't figure out C compiler information!
Make sure you're using GNU gcc, or clang
ghc: could not execute: /usr/x86_64-pc-linux-gnu/gcc-bin/6.4.0/gcc
The GHC located at /home/waivina/.stack/programs/x86_64-linux/ghc-ncurses6-8.0.2/bin/ghc failed to compile a sanity check.
It appears to still be looking for gcc-6.4.0...
Does Stack work with gcc-7.3.0? I searched for awhile and didn't find any documentation about what version of gcc Stack requires.
I attempted to use --with-gcc with no success.
stack setup.I expect Stack to be compatible with past and present versions of gcc, and/or documentation about what versions of gcc Stack is compatible with.
Stack appears to not be compatible with gcc-7.3.0
$ stack --version
Version 1.7.1, Git revision 681c800873816c022739ca7ed14755e85a579565 (5807 commits) x86_64 hpack-0.28.2
Gentoo Linux
GCC-7.3.0
Can you please post the output of
/usr/x86_64-pc-linux-gnu/gcc-bin/6.4.0/gcc --version
Thanks
There is no longer a 6.4.0, it was uninstalled.
I reinstalled gcc-6.4.0 and everything is working again, so the immediate concern is solved.
It seems there are issues with --with-gcc and gcc-7.3.0, and not much documentation on which version of gcc is required as a dependency.
Thanks,
Nathan.
--with-gcc do not work, maybe.
relation?
Can you link ${path}/gcc -> /usr/bin/gcc-7.3.0
Adding the symlink:
$ ln -s /usr/x86_64-pc-linux-gnu/gcc-bin/7.3.0/gcc /usr/x86_64-pc-linux-gnu/gcc-bin/6.4.0/gcc
appears to be another workaround. It successfully resolved the issue.
By the way, any idea who's hard coding gcc-6.4.0?
I skimmed the code base and didn't find any hardcoding.
When I query ~/.local/bin/stack path
It is including: /usr/x86_64-pc-linux-gnu/gcc-bin/7.3.0
I also read about a similar issue on Windows, something about the version of gcc that the binary ghc was built with GHC Issue #13560. Could it be something similar here?
Unlikely. Could you try wiping out the ~/.stack directory and trying again? My best guess is that, when installing GHC itself, the GHC configure scripts detect the GCC path.
Closing due to no response