Thread overview
Freshly Compiled DMD + Visual Studio
Aug 27, 2013
Meta
Aug 27, 2013
Dmitry Olshansky
Aug 27, 2013
Meta
Aug 27, 2013
Andre Artus
Aug 27, 2013
Meta
Aug 27, 2013
Andre Artus
August 27, 2013
I decided to compile D from Github for the first time, and
everything seemed to be working. I can build and run stuff fine
from the command line. However, then I tried to make Visual
Studio use my newly compiled DMD, and things blew up. I'm using
VisualD 0.3.37. When I try to compile a small project (which
compiles correctly when doing it from the command line) it gets
as far as linking, and then spits out a bunch of errors:

Debug\Algorithms.obj(Algorithms)
  Error 42: Symbol Undefined
_D3std3uni42__T11Uint24ArrayTS3std3uni13ReallocPolicyZ11Uint24Array5emptyMxFNaNbNdNeZb
(const(pure nothrow @property @trusted bool function())
std.uni.Uint24Array!(std.uni.ReallocPolicy).Uint24Array.empty)
Debug\Algorithms.obj(Algorithms)
  Error 42: Symbol Undefined
_D3std3uni42__T11Uint24ArrayTS3std3uni13ReallocPolicyZ11Uint24Array6__dtorMFNbNeZv
(nothrow @trusted void
std.uni.Uint24Array!(std.uni.ReallocPolicy).Uint24Array.__dtor())
Debug\Algorithms.obj(Algorithms)
  Error 42: Symbol Undefined
_D3std3uni36__T11Uint24ArrayTS3std3uni8GcPolicyZ11Uint24Array6__dtorMFNaNbNeZv
(pure nothrow @trusted void
std.uni.Uint24Array!(std.uni.GcPolicy).Uint24Array.__dtor())
Debug\Algorithms.obj(Algorithms)
  Error 42: Symbol Undefined
_D3std3uni36__T11Uint24ArrayTS3std3uni8GcPolicyZ11Uint24Array5emptyMxFNaNbNdNeZb
(const(pure nothrow @property @trusted bool function())
std.uni.Uint24Array!(std.uni.GcPolicy).Uint24Array.empty)
Debug\Algorithms.obj(Algorithms)
  Error 42: Symbol Undefined
_D4core4time13TimeException6__ctorMFNaNbNfAyaAyakC6object9ThrowableZC4core4time13TimeException
(pure nothrow @safe core.time.TimeException
core.time.TimeException.__ctor(immutable(char)[],
immutable(char)[], uint, object.Throwable))
Debug\Algorithms.obj(Algorithms)
  Error 42: Symbol Undefined
_D3std3utf12UTFException6__ctorMFNaNfAyakAyakC6object9ThrowableZC3std3utf12UTFException
(pure @safe std.utf.UTFException
std.utf.UTFException.__ctor(immutable(char)[], uint,
immutable(char)[], uint, object.Throwable))
Debug\Algorithms.obj(Algorithms)
  Error 42: Symbol Undefined
_D3std6format15FormatException6__ctorMFNaNbNfAyaAyakC6object9ThrowableZC3std6format15FormatException
(pure nothrow @safe std.format.FormatException
std.format.FormatException.__ctor(immutable(char)[],
immutable(char)[], uint, object.Throwable))
Debug\Algorithms.obj(Algorithms)
  Error 42: Symbol Undefined
_D3std4conv21ConvOverflowException6__ctorMFNaNbNfAyaAyakZC3std4conv21ConvOverflowException
(pure nothrow @safe std.conv.ConvOverflowException
std.conv.ConvOverflowException.__ctor(immutable(char)[],
immutable(char)[], uint))
Debug\Algorithms.obj(Algorithms)
  Error 42: Symbol Undefined
_D3std4conv13ConvException6__ctorMFNaNbNfAyaAyakZC3std4conv13ConvException
(pure nothrow @safe std.conv.ConvException
std.conv.ConvException.__ctor(immutable(char)[],
immutable(char)[], uint))
Debug\Algorithms.obj(Algorithms)
  Error 42: Symbol Undefined
_D3std4conv10parseErrorFNaNfLAyaAyakZC3std4conv13ConvException
(pure @safe std.conv.ConvException std.conv.parseError(lazy
immutable(char)[], immutable(char)[], uint))
Debug\Algorithms.obj(Algorithms)
  Error 42: Symbol Undefined
_D3std7variant17__T8VariantNVk20Z8VariantN5opCmpMxFNeKxS3std7variant17__T8VariantNVk20Z8VariantNZi
(const(@trusted int function(ref
const(std.variant.VariantN!(20u).VariantN)))
std.variant.VariantN!(20u).VariantN.opCmp)
Debug\Algorithms.obj(Algorithms)
  Error 42: Symbol Undefined __aaRange
Debug\Algorithms.obj(Algorithms)
  Error 42: Symbol Undefined __aaRangeEmpty
Debug\Algorithms.obj(Algorithms)
  Error 42: Symbol Undefined __aaRangeFrontKey
Debug\Algorithms.obj(Algorithms)
  Error 42: Symbol Undefined __aaRangePopFront
Debug\Algorithms.obj(Algorithms)
  Error 42: Symbol Undefined __aaRangeFrontValue

 From what I can tell, it looks like it cannot link in druntime
correctly... But I'm not really an expert.
August 27, 2013
27-Aug-2013 08:46, Meta пишет:
> I decided to compile D from Github for the first time, and
> everything seemed to be working. I can build and run stuff fine
> from the command line. However, then I tried to make Visual
> Studio use my newly compiled DMD, and things blew up. I'm using
> VisualD 0.3.37. When I try to compile a small project (which
> compiles correctly when doing it from the command line) it gets
> as far as linking, and then spits out a bunch of errors:
>

Linker errors are typically solve by doing clean, then rebuilding from source. There is a decent chance that you (or VisualD) do separate compilation and old object files can't find matching symbols in the new runtime library.
>
>   From what I can tell, it looks like it cannot link in druntime
> correctly... But I'm not really an expert.


-- 
Dmitry Olshansky
August 27, 2013
On Tuesday, 27 August 2013 at 12:09:22 UTC, Dmitry Olshansky wrote:
> Linker errors are typically solve by doing clean, then rebuilding from source. There is a decent chance that you (or VisualD) do separate compilation and old object files can't find matching symbols in the new runtime library.

I rebuilt it, but I am still getting the same linker errors. Both times I built DMD following the directions on this page: http://wiki.dlang.org/Building_DMD. Are they perhaps out of date?
August 27, 2013
On Tuesday, 27 August 2013 at 13:32:06 UTC, Meta wrote:
> On Tuesday, 27 August 2013 at 12:09:22 UTC, Dmitry Olshansky wrote:
>> Linker errors are typically solve by doing clean, then rebuilding from source. There is a decent chance that you (or VisualD) do separate compilation and old object files can't find matching symbols in the new runtime library.
>
> I rebuilt it, but I am still getting the same linker errors. Both times I built DMD following the directions on this page: http://wiki.dlang.org/Building_DMD. Are they perhaps out of date?

Check that your library paths are all set to the  path for of the newly built Phobos. It may be that it's trying to link in the old library.
August 27, 2013
On Tuesday, 27 August 2013 at 13:55:55 UTC, Andre Artus wrote:
> Check that your library paths are all set to the  path for of the newly built Phobos. It may be that it's trying to link in the old library.

Of course it was something as simple as that. Thank you Andre.
August 27, 2013
On Tuesday, 27 August 2013 at 14:04:09 UTC, Meta wrote:
> On Tuesday, 27 August 2013 at 13:55:55 UTC, Andre Artus wrote:
>> Check that your library paths are all set to the  path for of the newly built Phobos. It may be that it's trying to link in the old library.
>
> Of course it was something as simple as that. Thank you Andre.

No problem.