Fresh install of DMD and when trying to use ex. std.file from Phobos I get the following linking error: (I can trigger different ones depending on modules imported etc.)

```
lld-link: error: undefined symbol: tzset
```

I assume it has something to do with the C runtime or something, but everything should be setup correct, so maybe some path or something that is incorrect that I may need to modify? I have no idea what I need to do however.

I am using dub as well, so basically compiling using:

```
dub build -a=x86_64
```

Is there anything I am missing or what should I do? Currently D is unusable for me on my new machine because of this.

If anybody knows how I can just get things to work, it seems like D never works out of the box, which is very unfortunate.

This is literally my file:

```d
module main;

import std.file : readText, exists, write;

void main() {}
```

It's as minimal as an example as I can give pretty much.

A similar issue was with C++ runtime libraries such as libcmt.lib not being linked and I ended up having to move the files manually to my project folder, as I don't know how to fix it properly as there aren't any clear instructions anywhere on how to fix invalid paths etc. or what to do when linking just doesn't find the files despite them existing.

If anyone can help me fix this then I will be very grateful.

Reply via email to