Bug 19510 – [2.084 REG] random and spurious error about a missing NOLOGO.d file
Status
RESOLVED
Resolution
FIXED
Severity
regression
Priority
P1
Component
dmd
Product
D
Version
D2
Platform
x86
OS
Windows
Creation time
2018-12-23T18:25:07Z
Last change time
2018-12-29T07:27:51Z
Assigned to
No Owner
Creator
Basile-z
Comments
Comment #0 by b2.temp — 2018-12-23T18:25:07Z
1. Go to an empty folder
2. Save the following script in test.bat
```
if not exist "bin" mkdir "bin"
echo(module a; void main(){}| dmd -wi -O -release -m64 -Jbin -
```
3. execute the script many times. You'll randomly get the following error
> Error: module `NOLOGO` is in file '\NOLOGO.d' which cannot be read
> import path[0] = C:\dev\dmd\dmd2\windows\bin\..\..\src\phobos
> import path[1] = C:\dev\dmd\dmd2\windows\bin\..\..\src\druntime\import
> Error: linker exited with status 1
Test Environment:
- Windows 7 64 bit
- DMD 2.084 beta.1
- MS build tools are **not** setup
Seems to be an UB due to the way the linker command line is build:
https://github.com/dlang/dmd/search?q=NOLOGO&unscoped_q=NOLOGO
Comment #1 by b2.temp — 2018-12-23T20:48:22Z
Note that the issue is not related to piping the source code. The problem was observed for the first time when trying to build dcd with -m64. It was also much less random by the way.
to verify if this is fixed:
```
git clone https://www.github.com/dlang-community/dcd
git submodule update --init --recursive
set MFLAGS=-m64
build.bat
```
Other detail: last time before today that I was on win my dmd was at 2.082 so this could be a 2.083 regression as well.
Comment #2 by b2.temp — 2018-12-25T11:19:12Z
adding -v shows that dmd calls dmd.exe to link instead of lld-link.exe