www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.learn - Linker error with dmd

reply Chris <wendlec tcd.ie> writes:
Why do I get this error msg with dmd 2.067.1 and 2.068.0 in 
release mode:

$ dub --build=release

(.data._D65TypeInfo_xC3std5range10interfaces18__T10InputRangeTiZ10Input
ange6__initZ+0x10): undefined reference to
`_D64TypeInfo_C3std5range10interfaces18__T10InputRangeTiZ10InputRange6__initZ'
collect2: error: ld returned 1 exit status
--- errorlevel 1
dmd failed with exit code 1.

It works fine with the latest version of ldc2.
Oct 02 2015
parent reply John Colvin <john.loughran.colvin gmail.com> writes:
On Friday, 2 October 2015 at 09:43:54 UTC, Chris wrote:
 Why do I get this error msg with dmd 2.067.1 and 2.068.0 in 
 release mode:

 $ dub --build=release

 (.data._D65TypeInfo_xC3std5range10interfaces18__T10InputRangeTiZ10Input
ange6__initZ+0x10): undefined reference to
`_D64TypeInfo_C3std5range10interfaces18__T10InputRangeTiZ10InputRange6__initZ'
 collect2: error: ld returned 1 exit status
 --- errorlevel 1
 dmd failed with exit code 1.

 It works fine with the latest version of ldc2.
What is it that you are building?
Oct 02 2015
parent Chris <wendlec tcd.ie> writes:
On Friday, 2 October 2015 at 14:03:08 UTC, John Colvin wrote:
 On Friday, 2 October 2015 at 09:43:54 UTC, Chris wrote:
 Why do I get this error msg with dmd 2.067.1 and 2.068.0 in 
 release mode:

 $ dub --build=release

 (.data._D65TypeInfo_xC3std5range10interfaces18__T10InputRangeTiZ10Input
ange6__initZ+0x10): undefined reference to
`_D64TypeInfo_C3std5range10interfaces18__T10InputRangeTiZ10InputRange6__initZ'
 collect2: error: ld returned 1 exit status
 --- errorlevel 1
 dmd failed with exit code 1.

 It works fine with the latest version of ldc2.
What is it that you are building?
An executable. I mainly use a code base that compiles perfectly well in release mode. I couldn't find the reason for this error message, plus, ldc2 has no problem with it.
Oct 06 2015