www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.bugs - [Issue 13366] New: RDMD - Symbol Undefined

https://issues.dlang.org/show_bug.cgi?id=13366

          Issue ID: 13366
           Summary: RDMD - Symbol Undefined
           Product: D
           Version: D2
          Hardware: x86_64
                OS: All
            Status: NEW
          Severity: regression
          Priority: P1
         Component: tools
          Assignee: nobody puremagic.com
          Reporter: dev nomad.so

I have 2 reduced files, wich i can't compile with new (DMD 2.066) 
rdmd.exe under Windows 7 32-bit. Also confirmed on Linux (Ubuntu) x64

Command: rdmd --force --build-only aaa.d
Message "Error 42: Symbol Undefined _D3etc3bbb3fooFZi"

But command: dmd aaa.d etc\bbb.d
Compile without errors.
And then i replace rdmd.exe by old (from DMD 2.065) compile OK 
too.

Sample code:

/*** begin of file aaa.d ***/
import etc.bbb;

void main()
{
  int i = foo();
}
/***/


/*** begin of file etc\bbb.d ***/
module etc.bbb;

public int foo()
{
  return 1;
}
/***/

Compiled:
$ rdmd --force --build-only -I../ aaa.d
/tmp/.rdmd-1000/rdmd-aaa.d-869564B02B64C83C3AB4137B2C9D7507/objs/aaa.o: In
function `_Dmain':
aaa.d:(.text._Dmain+0x5): undefined reference to `_D3etc3bbb3fooFZi'
collect2: error: ld returned 1 exit status

If you change the module name everything works. i.e. 
change `etc` to something else.

--
Aug 23 2014