Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

My Visual Studio 2010 Professional with SP1 installed won't compile anymore. The shown error is:

TRACKER : error TRK0005: Failed to locate: "CL.exe". 
The system cannot find the file specified.

Strangely it is also not possible anymore to create new projects - the wizard appears but just restarts when I press create. As I found out the paths for Visual Studio are now built from settings in the registry. Namely HKEY_CURRENT_USER\Software\Microsoft\VisualStudio. Comparing a colleagues installation with mine revealed no different settings. So this is how the Property Pages/Configuration Properties/VC++ Directories look like:

Executable Directories: $(ExecutablePath)
Include Directories: $(IncludePath)
Reference Directories: $(ReferencePath)
Library Directories: $(LibraryPath)
Source Directories: $(SourcePath)
Exclude Directories: $(ExcludePath)

From the Visual Studio 2010 Command Prompt, cl.exe is found.

I can only guess that this behavior was caused by a reinstallation of Studio a couple of months ago (to a different folder). As we use an external build-script for our main project there is a good chance that it is broken since then.

Any hints?

share|improve this question
    
Are you sure you installed all the required features? cl.exe is the Visual Studio C/C++ compiler & linker. Make sure you added VC++ support, and not just C# and the other languages. –  Breakthrough Oct 5 '11 at 11:17
    
C++ support is added. I doubt that I would see the C++ templates if it was not installed. –  tuner Oct 6 '11 at 7:27

1 Answer 1

Compilation issue

After some further research I found this question on MSDN. The answer from a Microsoft employee contained some tips how to debug your VS installation. Namely:

  • Run as administrator.
  • Start from command line:
    • Devenv.exe /log C:\VS_error.log
    • Devenv.exe /Resetsettings
    • Devenv.exe /ResetSkipPkgs
    • Devenv.exe /Safemode
    • Devenv.exe /Resetsettings
  • Reboot OS to safe mode.
  • Use Process Monitor to see what VS is trying to do.

None of this helped so I went for a repair installation of VS 2010 and SP1 - it didn't help. After that I reset the settings - didn't help. What got me going again is opening Property Pages of my project, then Configuration Properties/General/Platform Toolset. Here are three options listed in my installation:

  • v100
  • v90
  • Windows7.1SDK

The active one was v100 so I switched to v90. With that toolset VS is able to compile again. Obviously this is not a good solution because the 9 compiler is not the latest compiler so this is a mere workaround for my problem.

Project creation issue

The repair install for VS didn't help here either. This stackoverflow question solved a part of the problem. After adding .vbproj and vcproj to HKEY_CURRENT_USER\Software\Classes in the registry, I was able to create Visual Basic and C# projects again. But still I can't create any C++ projects.

Because of the drawbacks of the solution I will not mark my answer as solution to the problem. To me it looks like the registry is messed up and I would appreciate to get to know the source of my problems.

share|improve this answer
1  
Have you tried a full uninstall/reinstall? –  James Jul 3 '12 at 8:19

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.