Bug 13774 – Multiple definition of `conv_50c_dc8` with three libraries and `std.file` import
Status
RESOLVED
Resolution
FIXED
Severity
regression
Priority
P1
Component
phobos
Product
D
Version
D2
Platform
All
OS
All
Creation time
2014-11-25T13:57:39Z
Last change time
2019-07-23T01:29:58Z
Keywords
link-failure, pull, rejects-valid
Assigned to
Martin Nowak
Creator
Denis Shelomovskii
Comments
Comment #0 by verylonglogin.reg — 2014-11-25T13:57:39Z
The first library is Phobos. This code should build fine:
m1.d & m2.d:
---
import std.file;
---
Command (for Windows):
---
dmd -debug -lib m1.d
dmd -debug -lib m2.d m1.lib
---
m2.lib: Error: multiple definition of conv_50c_dc8: _D3std4conv52__T18emplaceInitializerTSАЕдfile15DirIterato∙АГкZАФ▒FNaNbNcNeKАЬ║4iАГ▓yАЫв and conv: _D3std4conv52__T18emplaceInitializerTSАЕдfile15DirIterato∙АГкZАФ▒FNaNbNcNeKАЬ║4iАГ▓yАЫв
---
(command output is probably encoded in CP1251)
This issue almost blocks Phobos usage in real projects as it breaks building libraries and linker error doesn't give any clue of its reason.
Also see Issue 13359.
Note: this report is about Phobos regression preventing its usage. Underlying compiler bug is some critical bug triggered by current Phobos version.
Tools versions:
dmd: c0e814350948feac34946c29186d17518ea954dd
druntime: 2350ee4ec77d7b919454eb2f16d91b23c3891cb6
phobos: e46ccaae82d6ddbd0c98ac233562204c7007f296
Comment #1 by dlang-bugzilla — 2014-12-02T11:51:08Z