4
votes

I am using VS2010 (pro) and VS2015 Express.

Recently (probably as a result of installing some other software) all my 32 bit builds started failing with

TRACKER : error TRK0002: Failed to execute command: ""C:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\bin\CL.exe" @C:\Users....rsp". The handle is invalid.

(64 bit builds continue to work)
The problem appears to be MSBuild invoking the 64 bit version of Tracker.
Google tells me that others have had the opposite problem in that 64 bit builds get the same error, whilst 32 bit builds succeed

Looking at procmon I find that MSBUILD
(1) opens Registry Key
HKLM\SOFTWARE\Wow6432Node\Microsoft\NET Framework Setup\NDP\v4\Full which has an InstallPath value of

        C:\Windows\Microsoft.NET\Framework\v4.0.30319\  

(2) tries to open C:\Windows\Microsoft.NET\Framework64\v4.0.30319\Tracker.exe which does not exist
(3) opens registryKey
HKLM\SOFTWARE\Wow6432Node\Microsoft\Microsoft SDKs\Windows\v8.0A\WinSDK-NetFx40Tools-x86
(which does not exist, although
HKLM\SOFTWARE\Wow6432Node\Microsoft\Microsoft SDKs\Windows\v8.1A\WinSDK-NetFx40Tools-x86
does)
(4)opens file
C:\Program Files (x86)\Microsoft SDKs\Windows\v7.0A\Bin\NETFX 4.0 Tools\x64\Tracker.exe
Which generates the error above

I'm at a loss to explain the presence of the "x64", especially as MSBuild appears to be looking for a file path in a registry key that ends in -86

From http://community.sharpdevelop.net/forums/p/11439/31258.aspx there is a wordaround to disable tracker by adding "False" to a property group in the .vcxproj file. But this entails changing many such files Any advice welcome

1

1 Answers

2
votes

I've been able to solve the same issue by making sure _IsNativeEnvironment environment variable is set to false.