Installing D locally

Learn how to install D locally to solve Exercism's exercises on your own machine


The D language track requires that you have the following software installed on your system:

  • a D version 2 compiler
  • (optional but recommended) DUB

Prerequisite: D version 2 Compiler

On the D language's website dlang.org, the most recent compiler version of the reference compiler DMD (Digital Mars D) can be downloaded and installed for several platforms. See the official downloads page for more information. On Windows, an alternative solution is to use Chocolatey. On Intel-based Macs, an alternative solution is to use Homebrew.

Other compilers

Besides the DMD reference compiler which uses its own backend, there are two other compilers that can be fetched through the dlang.org download section:

  • GDC which uses the GCC backend
  • LDC based on the LLVM backend

GDC and LDC aren't always at the most recent DMD frontend's versions but provide better optimization levels as well as support for other platforms like e.g. ARM.

See the wiki for more information.

IDE support

There are also support for the D language in various IDEs, e.g. VisualD for Visual Studio and D plugin for IntelliJ's CLion. See the wiki for more information.

Prerequisite: DUB

DUB is a build manager for D.

We recommend it as a way to simplify the process of running the tests, but it is still possible to run without DUB if you cannot or do not want to install it.

Windows

The DUB website's download page has a Windows installer.

MacOS

Linux