ghc command not found
Introduction
When you run more command in linux terminal / console, you get the following error message
ghc: command not found
or when using sudo you get the following error message
sudo: ghc: command not found
Solutions to ghc: command not found
How To Fix ghc: command not found in Ubuntu / Debian / Kali Linux / Raspbian
In Ubuntu ghc is provided by ghc package.
ghc is:
The Glorious Glasgow Haskell Compilation system (GHC) is a compiler for Haskell.
Haskell is “the” standard lazy functional programming language. The language definition and additional documentation can be found in the `haskell-doc' package. Alternatively, there is an online version at http://haskell.org/onlinereport/.
To fix this problem, we can install more using the command below.
sudo apt-get -y install ghc
This command might take some time to finish depending on your machine internet connection.
You can also use apt command to install ghc.
sudo apt -y install ghc
Or if you have aptitude installed you can use the following command.
sudo aptitude install ghc
Summary
In this tutorial we learn how to fix ghc command not found error in Ubuntu / Debian / Kali Linux or Raspbian distribution.