Warn if there are no `cc` command.
On a fresh Arch Linux install (try e.g. with docker run -ti --rm base/archlinux
):
[root@4d020a477a06 ghcup]# ./ghcup install
Installing GHC-8.4.4 for Arch Linux on architecture x86_64
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 145M 100 145M 0 0 13.3M 0 0:00:10 0:00:10 --:--:-- 17.7M
checking build system type... x86_64-pc-linux-gnu
checking host system type... x86_64-pc-linux-gnu
checking target system type... x86_64-pc-linux-gnu
Build platform inferred as: x86_64-unknown-linux
Host platform inferred as: x86_64-unknown-linux
Target platform inferred as: x86_64-unknown-linux
GHC build : x86_64-unknown-linux
GHC host : x86_64-unknown-linux
GHC target : x86_64-unknown-linux
LLVM target: x86_64-unknown-linux
checking for path to top of build tree... /tmp/tmp.KF7V7gadPN/ghc-8.4.4
checking for perl... /usr/sbin/perl
checking for a BSD-compatible install... /usr/bin/install -c
checking for gfind... no
checking for find... /usr/sbin/find
checking whether ln -s works... yes
checking for gsed... sed
checking for gcc... no
checking for clang... no
configure: error: in `/tmp/tmp.KF7V7gadPN/ghc-8.4.4':
configure: error: no acceptable C compiler found in $PATH
See `config.log' for more details
Failed to install, consider updating this script via: ghcup upgrade
Upgrading is a valid thing to offer, but it won't help here. I think checking for existence of make
and cc
in $PATH
will catch clear cases where there are no development tools installed.
Btw, sorry for spamming ghcup
with issues; but I'd like it to become good enough I dare to recommend it! It's close, but not there yet.