How to run lit tests on Mac OSX without gcc?

Thomas Mader via digitalmars-d-ldc digitalmars-d-ldc at
Mon Aug 28 13:01:40 PDT 2017

On Monday, 28 August 2017 at 08:55:22 UTC, David Nadlinger wrote:
> I'm still not sure I understand. Are you saying that Nix 
> purposely doesn't allow the system Xcode installation to be 
> found (which makes sense for a reproducible build system), but 
> doesn't provide a `gcc` symlink in its Clang/Xcode/… package?

Exactly, all packages are under /nix/store/ and each package has 
a different directory in which all files are contained.
The name of the directory starts with a hash which describes the 
container uniquely and changes each time something in the build 
description of the package changes or some dependency package 

The dependencies are nothing else then the full paths to the 
container directories in /nix/store

Everything should be pure (work in progress) and so the OS clang 
package isn't used. Nix needs to provide that on it's own. I 
opened an issue for it:

You are right that if the default system provides the symlink, 
Nix should too.
But as you said in your later post, ldc works with clang and 
clang is the default on Darwin, so it seems nicer to just support 
it that way.

> Also, if the CC environment variable is set to the path of an 
> executable, LDC should automatically use it already. What the 
> default program is should be inconsequential then.

If I understood the ldc code correctly (driver/tool.cpp), only 
gcc is searched for in the environment but not clang. clang is 
used on FreeBSD only.

More information about the digitalmars-d-ldc mailing list