dmd -run fails with Nix on macOS Mojave

Jonathan Marler johnnymarler at gmail.com
Tue Feb 19 21:34:30 UTC 2019


On Tuesday, 19 February 2019 at 21:27:19 UTC, Thomas Mader wrote:
> On Tuesday, 19 February 2019 at 21:06:29 UTC, Jonathan Marler 
> wrote:
>> On Tuesday, 19 February 2019 at 20:37:48 UTC, Thomas Mader 
>> wrote:
>>> On Tuesday, 19 February 2019 at 20:32:32 UTC, Thomas Mader 
>>> wrote:
>>>> I don't know what the compiler wants to write to 
>>>> /var/tmp/dmd_runNVSCJp and why that fails with a Permission 
>>>> denied.
>>>
>>> Ok I found it, it's created in link.d
>>
>> Not sure if macos does this, but on linux you can mount 
>> directories as "noexec" which means you can't run executables 
>> that live inside those mounts.  On linux you could check this 
>> with "mount | grep /var/tmp", not sure if it's the same on 
>> MacOS.
>>
>> (Related Issue: https://github.com/dragon-lang/rund/issues/17)
>
> No that's not the problem.
> Nix does not change mounts when a binary is run. All it's doing 
> is specify it's own directories and this also includes the 
> System Libs of macOS.

Yes I'm pretty familair with how Nix works.  I'm not talking 
about Nix changing mount settings or installing files in places 
it shouldn't, I'm talking about where dmd stores the executable 
its going to run.  Of course I don't know if this is the issue 
you're running into, but if it is then it's not necessarily a 
problem with Nix, it could just be a configuration issue with DMD 
as to where it store temporary executables.




More information about the Digitalmars-d mailing list