Please let us know if there are problems.
We build on the above OSs, but often these packages will work on other Debian/Ubuntu versions. For example the 'stretch' versions work on Ubuntu 18.04 and Mint 19.
Support has been removed for Debian 8 (jessie) and Ubuntu 16.04, if you need them file an issue and I can make a backport.
The packaged version of Mercury contains a reasonable number of grades for the C backends. It does not contain the Java, C# or Erlang backends. The included grades are:
Depending on the C compiler some packages may use "reg" grades rather than "asm_fast" grades.
There are two groups of packages to choose from. The stable version of Mercury's packages begin with "mercury", a more recent snapshot begins with "mercury-rotd".
This Mercury has been bootstrapped (the compiler is built with 3 tag bits
and other settings) and separated into multiple packages.
It does not support multiple concurrent installation versions, nor do the
dynamic libraries support this.
As always, make sure that there is no other version of Mercury in your
$PATH, you can run into
First download my GPG key and tell your Debian based system that you trust me. This command means that you are authorising your computer to download any software I publish.
sudo apt install wget ca-certificates gnupg cd /tmp wget https://paul.bone.id.au/paul.asc sudo apt-key add paul.asc
Now tell your system where the repository is.
Create a new file in
/etc/apt/sources.list.d, name it
mercury.list and paste in it:
deb http://dl.mercurylang.org/deb/ DISTRO main deb-src http://dl.mercurylang.org/deb/ DISTRO main
Depending on your OS version
replace DISTRO with one of:
|You have||Then use|
|Debian 9 (stretch)||stretch|
|Debian 10 (buster)||buster|
|Ubuntu 18.04 (bionic)||stretch|
|Ubuntu 19.04 (disco)||disco|
|Ubuntu 20.04 (focal)||focal|
If your OS version isn't listed then try some of the others, depending on what dependencies you have available.
Note that Ubuntu and derivatives must have the universe repository enabled.
Update your packages list.
sudo apt update
Either browse the packages or install
mercury-recommended which will install a reasonable set of
Mercury packages for most developers.
or for a recent ROTD version of Mercury:sudo apt install mercury-recommended
sudo apt install mercury-rotd-recommended
Or choose specific packages to install. You can see a list with the command:
apt-cache showsrc mercury