Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Visual studio 2010 IDE build fails mysteriously with no errors or warnings

If I try to build my .sln file in visual studio (using release configuration, but actually none of my configurations build), the build fails with zero errors in the output window and none the error list. In fact, in the build output window, I have 7 projects listed. And under normal verbosity, I have 7 "Build succeeded." lines after each project. Yet at the bottom:

========== Build: 6 succeeded or up-to-date, 1 failed, 0 skipped ==========

By building the projects one by one, I have found the 'failing' project and I tried to build it all by itself. It depends on one other project and that builds just fine all by itself. I try building the 'failing' project by itself and I get zero errors and no warnings and a build failed. However in the 'bin' folder for that project, (if I delete the old bin file) I am getting a built dll. Doesn't do me much good though, since the build is 'failing', visual studio makes no effort to launch my project in debug mode.

Here's something puzzling: In the command line, I have navigated to the directory with my .sln file in it, and I then run this command:

C:\Windows\Microsoft.NET\Framework\v4.0.30319\msbuild.exe /ToolsVersion:4.0 /p:Configuration=Release

Then, in bin/Release, voila, I have my built project. The build passes in the command line but not the IDE.

Does anyone have any suggestions? This problem has happened to me twice: Once on windows server 2008 and once on windows xp sp3.

like image 522
Isaac Bolinger Avatar asked Jun 30 '12 21:06

Isaac Bolinger


2 Answers

Visual Studio 2010 says Build failed with no errors after I change a source file

One answer there suggested that I change the place from where I'm building. Here's the path of the debug directory:

C:\Users\Isaac\Documents\Visual Studio 2010\Projects\checkout\Library Projects\BaseSystemCore\BaseSystemCore\bin\Debug

Just moving the checkout directory to c:\ did the trick. Something to do with the build path being too long.

like image 138
Isaac Bolinger Avatar answered Oct 22 '22 05:10

Isaac Bolinger


I had the same error, it would not build but no errors. Restarting visual studio worked for me, this was in visual studio 2012.

like image 22
nldev Avatar answered Oct 22 '22 03:10

nldev