Thread overview
[Issue 17355] Path to lib64 and $(DMDInstallDir) not correct
Apr 26, 2017
Thomas
Apr 27, 2017
Rainer Schuetze
Apr 28, 2017
Thomas
Apr 29, 2017
Rainer Schuetze
Jun 05, 2017
Rainer Schuetze
April 26, 2017
https://issues.dlang.org/show_bug.cgi?id=17355

--- Comment #1 from Thomas <thomas.hedstrom@mail.com> ---
Additional notes: No other Visual Studio versions are installed, although the new vs2017 is installed on another drive (not c: ).

--
April 27, 2017
https://issues.dlang.org/show_bug.cgi?id=17355

Rainer Schuetze <r.sagitario@gmx.de> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |r.sagitario@gmx.de

--- Comment #2 from Rainer Schuetze <r.sagitario@gmx.de> ---
This sounds like the DMD install path wasn't detected or set during installation or later. This might happen if you install Visual D before dmd.

Please check the respective setting "DMD install path" on the global options page.

--
April 28, 2017
https://issues.dlang.org/show_bug.cgi?id=17355

--- Comment #3 from Thomas <thomas.hedstrom@mail.com> ---
After a lot of uninstalling/installing DMD/VisualD, my previous global settings for library path etc was still not "refreshed". I suspected some remains from older installations so resided to removing all of Visual D remains in the registry / VisualStudio settings manually. Quite a lot.

When I finally got a hopefully fresh set of global "Visual D Settings" it was back to the same problem as before, $(DMDInstallDir) = .\


Though it seems to have found the path since in the registry it's correct.
Found two keys named "DMDInstallDir" = "C:\D\dmd2". Under:
HKEY_LOCAL_MACHINE\SOFTWARE\WOW6432Node\VisualD
and
HKEY_LOCAL_MACHINE\SOFTWARE\WOW6432Node\Microsoft\VisualStudio\15.0\ToolsOptionsPages\Projects\Visual
D Settings

Setting the "DMD install path" manually in the global settings will do as a work-around but it does not seem to fill it in automatically.

Also, is there a need for an option to force clean/default settings during installation maybe?

--
April 29, 2017
https://issues.dlang.org/show_bug.cgi?id=17355

--- Comment #4 from Rainer Schuetze <r.sagitario@gmx.de> ---
HKEY_LOCAL_MACHINE\SOFTWARE\WOW6432Node\VisualD

is where the installer remembers the setting made during installation. For each Visual Studio version that you choose for Vsiual D installation, it is also set at

HKEY_LOCAL_MACHINE\SOFTWARE\WOW6432Node\Microsoft\VisualStudio\<VS-Version>\ToolsOptionsPages\Projects\Visual D Settings

When starting VS, it copies these settings to the user hive:

HKEY_CURRENT_USER\SOFTWARE\Microsoft\VisualStudio\<VS-Version>_Config\ToolsOptionsPages\Projects\Visual D Settings

If you change any global option for Visual D it saves all of them (including
DMDInstallDir) to

HKEY_CURRENT_USER\SOFTWARE\Microsoft\VisualStudio\<VS-Version>\ToolsOptionsPages\Projects\Visual D Settings

Please note that the last two registry keys are defined by VS and passed to Visual D. To start from scratch, you need to cleanup the latter.

For VS 2017 these registry hives are mapped into a "private" registry that you can only edit with regedit using "Load hive". So there is little the installer can do to cleanup the settings.

The extra step writing the installer value into the VS registry seems gratuitous, though, and might be actually causing the problems for VS2017. Reading the default from the Visual D installer key should be better.

--
June 05, 2017
https://issues.dlang.org/show_bug.cgi?id=17355

Rainer Schuetze <r.sagitario@gmx.de> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|---                         |FIXED

--- Comment #5 from Rainer Schuetze <r.sagitario@gmx.de> ---
Now also reading the installer registry keys of Visual D and DMD. Fixed in https://github.com/dlang/visuald/releases/tag/v0.45.0-beta1

--