Visual D in Visual Studio 2013 on Win 8.1 with DMD x64 Linker Problem Solved
Tyler Jensen
tyler at tsjensen.com
Fri Nov 29 14:54:19 PST 2013
I removed the modifications from [Environment] and
[Environment32] and all worked as expected, so those were
unnecessary. Thanks for pointing that out. I tried going back to
the original [Environment64] section and change paths in the VS
tools / options section mentioned, but still with no luck. So I
went back to the solution I found that worked.
On Friday, 29 November 2013 at 21:14:25 UTC, Tyler Jensen wrote:
> On Monday, 18 November 2013 at 07:45:31 UTC, Rainer Schuetze
> wrote:
>> Thanks for the report.
>>
>> On 18.11.2013 00:41, Tyler Jensen wrote:
>>> Question and answer in one. I found the answer to my question
>>> not long
>>> after composing the question. Posted here for others who are
>>> on the
>>> bleeding OS edge as well.
>>>
>>> My environment:
>>> Running Windows 8.1.
>>> Visual Studio 2013 Premium installed.
>>> Install Visual D with VisualD-v0.3.37.exe.
>>>
>>> Create new D console app DMD/GDC.
>>>
>>> Switch solution config to "Debug DMD|x64"
>>>
>>> Hit F6 to build and get the following:
>>>
>>> ------ Build started: Project: ConsoleApp1, Configuration:
>>> Debug DMD x64
>>> ------
>>> Building Debug DMD x64\ConsoleApp1.exe...
>>> LINK : fatal error LNK1181: cannot open input file
>>> 'user32.lib'
>>> Building Debug DMD x64\ConsoleApp1.exe failed!
>>> ------
>>>
>>> How to fix this? That is the question.
>>>
>>> Partial answer found in known issues page:
>>> http://rainers.github.io/visuald/visuald/KnownIssues.html
>>>
>>
>> This is a bit out of date, it should not be necessary anymore
>> with newer versions of Visual D.
>
> I'm using the latest release of Visual D 0.3.37. (I just
> checked for a new release but that seems to be the most recent.)
>
>>
>>> That fix did not work but it led to trying this change to
>>> sc.ini (only
>>> showing changed lines):
>>>
>>> ; environment for both 32/64 bit
>>> [Environment]
>>> LIB="%@P%\..\lib";\dm\lib;"C:\Program Files (x86)\Windows
>>> Kits\8.0\Lib\win8\um\x86";%DMD_LIB%
>>> ; original LIB="%@P%\..\lib"
>>>
>>> [Environment32]
>>> ; original LIB="%@P%\..\lib"
>>> LIB="%@P%\..\lib";\dm\lib;"C:\Program Files (x86)\Windows
>>> Kits\8.0\Lib\win8\um\x86";%DMD_LIB%
>>
>> You should not pass the path to COFF libraries in the SDK to
>> the Win32 linker, it only understands libraries in OMF format
>> (coffimplib needed to convert the libraries).
>>
>>>
>>> [Environment64]
>>> ; original LIB="%@P%\..\lib64"
>>> LIB="%@P%\..\lib64";\dm\lib;"C:\Program Files (x86)\Windows
>>> Kits\8.0\Lib\win8\um\x64";%DMD_LIB%
>>
>> What version of DMD are you using? DMD 2.064 was tweaked to
>> have the path to the SDK libraries in sc.ini. Unfortunately it
>> is not working with the Windows SDK 8.1, as Microsoft changed
>> the SDK layout again.
>
> I had downloaded and installed dmd-2.064.2 which appears to be
> the latest.
>
>>
>> Visual D also allows setting additional library paths in the
>> Tools->Options->Project and Solution->Visual D Settings->DMD
>> Directories->x64 page.
>
> I did try to use these settings but never had any success in
> getting it to work. I'm really a newb here, so if you have
> recommendations for a better solution, I'm eager to try it.
More information about the Digitalmars-d-ide
mailing list