When compiling a C + + program using VS2010, every time you modify a file in the project, click "Generate-only project-Generate * *", often the entire project needs to be recompiled again. Because the project code is too large, it takes about 10 minutes to compile each time the compilation is completed. The most annoying time is when the compilation is done wrong, modified the error to compile again, wasting a lot of time. So how to configure VS2010 like VC6.0, the default can only compile modified files? There are a number of solutions to this problem on the network, and here I am tidying up my modified configuration.
1. Due to timeFirst, in
Debug ModeUnder
DeleteFunction
Debug directory for all Files。 Then find:
Project-Properties-Configuration Properties-c/c++-code generation-Enable Minimal rebuild: Yes (/gm)
Project-Properties-Configuration Properties-c/c++-General-Debug Information Format: Program database (/ZI)
Properties-Configuration Properties-linker-general-Enable incremental links Select Yes
Finally, it's a good idea to change one place:
Tools-Projects and solutions-build and run
At run time, when the project expires, select never Generate
tick-build only projects and dependencies at run time
MSBuild Project build output Details Select "Min"
2. Pre-compiled header files are caused by
Project-Properties-Configuration Properties-Precompiled Header file: Use/yuIn general, after this configuration, VS2010 will compile only the modified files at each compile time.
VS Optimized compilation configuration