Bug 10255 – When creating lib files, dmd no longer splits module into multiple obj files

Status
RESOLVED
Resolution
FIXED
Severity
regression
Priority
P2
Component
dmd
Product
D
Version
D2
Platform
x86
OS
Windows
Creation time
2013-06-03T11:25:00Z
Last change time
2015-06-09T05:11:49Z
Assigned to
nobody
Creator
bugzilla

Comments

Comment #0 by bugzilla — 2013-06-03T11:25:29Z
Given: ----- foo.d -------- void foo1() { } void foo2() { } -------------------- and compiling with: dmd -lib foo.d lib -l foo.lib will create the .lst file: ------------------- Publics by name module _D3foo12__ModuleInfoZ foo _D3foo15__unittest_failFiZv foo _D3foo4foo1FZv foo _D3foo4foo2FZv foo _D3foo7__arrayZ foo _D3foo8__assertFiZv foo Publics by module foo _D3foo12__ModuleInfoZ _D3foo15__unittest_failFiZv _D3foo4foo1FZv _D3foo4foo2FZv _D3foo7__arrayZ _D3foo8__assertFiZv --------------------- showing that they are all put in one module. However, dmd -c -multiobj foo.d will correctly create multiple .obj files.
Comment #1 by r.sagitario — 2013-06-11T23:58:05Z
It seems there are actually multiple object files with the same name in the library which are merged in the list file. If you extract a module it only contains some of the listed symbols, not all. Opening the lib in IDA also reveals multiple files with the same name.
Comment #2 by bugzilla — 2013-10-10T15:48:32Z
Comment #3 by github-bugzilla — 2013-10-10T23:47:12Z
Commits pushed to master at https://github.com/D-Programming-Language/dmd https://github.com/D-Programming-Language/dmd/commit/35d857ea2a612bafe3321c230db320c6dbddfd48 fix Issue 10255 - When creating lib files, dmd no longer splits module into multiple obj files https://github.com/D-Programming-Language/dmd/commit/0e6d523e9a783eae00c0008db8ed849d7f953887 Merge pull request #2651 from WalterBright/fix10255 fix Issue 10255 - When creating lib files, dmd no longer splits module i...
Comment #4 by github-bugzilla — 2013-10-11T11:37:06Z
Commit pushed to dmd-1.x at https://github.com/D-Programming-Language/dmd https://github.com/D-Programming-Language/dmd/commit/605ba81b50f4227e420937c1893b0521796fdb5b Merge pull request #2651 from WalterBright/fix10255 fix Issue 10255 - When creating lib files, dmd no longer splits module i...