7

I've been using VS2015 RC until July 19th, then uninstalled and subsequently installed VS2015 Community (the official release). I was able to successfully debug and run C++ programs on VS2015 RC, but however, when I now try to run any simple program that I have successfully debugged in the past or any new one, VS2015 Community gives me a popup that says: "This project is out of date. ProjectName - Debug Win32. Would you like to build it?"

I've been on SO and found this: Visual Studio Project out of date, but even after deleting all the .tlog files, I've still been getting the same issue. I've also deleted all the .pdbs, but that hasn't helped either. Does anyone know what a fix might be? Thanks!

Community
  • 1
  • 1
JXX
  • 71
  • 1
  • 3

2 Answers2

14

You can change the build output verbosity setting to make Visual Studio 2015 tell you why it is rebuilding:

  1. Build the solution
  2. Change MSBuild project build output verbosity setting to Detailed or Diagnostics. It's found here:

    • Tools (menu)
    • Options
    • Project and Solution
    • Build and Run
  3. Build the solution and check the Output view.

In my case it printed a message like this:

1>------ Up-To-Date check: Project: xyz, Configuration: xyz ------
1>Project not up to date because build input 'C:\ws\Missing.h' is missing.

... and removing that header from the project fixed the problem.

CrouZ
  • 1,721
  • 17
  • 17
  • This worked for me. Somehow I had a file that was referenced in the project, but it was missing on disk. Thanks. – Martin May 18 '17 at 17:21
3

If you are reading this then probably a Full Rebuild didn't help.

Most likely you have a reference to a header file in your project that does not exist on the filesystem.

Try opening every header file that your project refers to, and remove the ones that can't be opened.

rustyx
  • 80,671
  • 25
  • 200
  • 267
  • Opening every header file can be almost impossible if you have a huge project with hundreds of source and header files. The build output verbosity tip from CrouZ is pretty quick and painless – Paulus Jun 07 '17 at 14:33
  • Yes, the build diagnostics will tell you that a header is missing. The problem is that it only tells you the FIRST missing header. If there are multiple headers missing, you'll have to re-do the build, with the diagnostics, for each missing header. So, if you do have a huge project with hundreds of sources and headers, it's likely you'll have multiple missing files, in which case you need to do what this answer suggests anyway. – Dan Korn Mar 08 '18 at 21:47