Reputation: 11011
I have two dll files made by around 1500 cpp files. When I need to edit one, I usually then recompile all the 1500 files from the start. But I heard there is a way to make Visual Studio recompile the modifies only, taking a lot less time... How do I do this?
Upvotes: 3
Views: 8351
Reputation: 224149
VS is actually pretty good in doing the dependency checks so that only necessary stuff is re-compiled. I can see a couple of (more or less likely) reasons for what you're seeing:
That's in what I consider decreasing probability order.
Upvotes: 15
Reputation: 444
Look for Precompiled Header option in Projects Properties -> C/C++ -> Precompiled Headers menu. Set it to Use instead of Create. That helped me. Below is my original message which i wanted to post here :)
Hi. I too have same problem with VS 2010. I have run build command few times so all projects are up to date. I added to one solution .cpp and .h file containing empty class. .cpp file contained only precompiled header and .h file, while .h file only #pragma once and 'class test{};'. After few builds (4 thread building) i get all up to date message. Then i changed .h file to 'class test{int a};' and after selecting build all files where rebuilt.
Also i checked for minimal recompile option and its turned on. Probably is precompiled header causing trouble. Ill check it now :D
Upvotes: 3
Reputation: 557
Select the modified files, right mouse click and compile then it compiles only modified files and then build it.. it takes less time compare to simply build the whole project. Not sure about new versions of VS.net IDE.. I think VS.net IDE take cares only the modified files.. if you run "build" only not "rebuild"
Upvotes: 3