As of earlier today, a snap package for LDC 1.1.0 has been published in the 'edge' channel of the Ubuntu store.

Snap packages are a new format developed by Ubuntu to facilitate upstreams being able to provide the latest versions of their apps directly to users. The format is also designed to provide effective confinement for apps, so that they can only access the parts of the host system that they need to. While developed by Ubuntu, the format is gaining quite a bit of of cross-distro traction: see http://snapcraft.io/ for more information.

On Ubuntu 16.04 or later, or Debian Sid, it should be possible to install this package using the following commands:

sudo apt install snapd # in order to be able to install snap packages at all

    sudo snap install --classic --edge ldc2

The `--classic` flag is needed in order to accept the confinement choice of the ldc2 package, while the `--edge` flag is needed to search in the similarly-named package channel. As the name suggests this is for 'bleeding edge' packages.

The package includes the ldc2 compiler plus its 'dmd-like' version ldmd2, as well as ldc-profdata and ldc-prune-cache. You'll find the commands in /snap/bin/ : note that the latter three will (for now) be called ldc2.ldmd2, ldc2.ldc-profdata and ldc2.ldc-prune-cache (these names will hopefully be simplified in a future release).

It should be possible to use ldc2 and ldc2.ldmd2 in the same way that you would use their equivalents installed by any other package manager. Please let me know of any issues you encounter in trying to use this!

In principle it should also be possible to install this snap on other distros that have support for snap packages (e.g. Arch, Gentoo, Fedora, OpenSUSE); however, it will require an up-to-date version of snapd (2.21 or later) which some distros may not yet have made available. For instructions on how to install snapd on other distros, see:
http://snapcraft.io/docs/core/install

For information on 'classic' confinement, see:
https://insights.ubuntu.com/2017/01/09/how-to-snap-introducing-classic-confinement/

Finally, for the snap package definition, see:
https://github.com/ldc-developers/ldc2.snap

I would be happy to explain any aspects of the snap packaging process or syntax that anyone is interested in.

Finally, thanks to the LDC developers who eagerly embraced this project to create and distribute an LDC snap package, and for all the helpful advice and support they have offered throughout the process.

Please do let me know what your experience is trying the package!

Thanks & best wishes,

    -- Joe

Reply via email to