views:

55

answers:

3

I've got the weirdest thing I've seen in a long while with VS2010. I have the same solution, checked out from svn, into two different folders. One builds one doesn't... but MSBuild doesn't actual fail to build. All the assemblies build and it will run, but VS2010 keeps saying one project fails. If anyones seen this before or can see what I'm missing in my logs it would help heaps.

Looking closer at the second log, I read three "Build succeeded." messages but a final "========== Build: 2 succeeded or up-to-date, 1 failed, 0 skipped ==========". Go figure. There's no post build events. I really don't get this one.

------ Build started: Project: Data.Connection, Configuration: Debug Any CPU ------
Build started 23/09/2010 9:55:30 a.m..
Build succeeded.
Time Elapsed 00:00:00.02

------ Build started: Project: Common, Configuration: Debug Any CPU ------
Compile complete -- 0 errors, 0 warnings
Build succeeded.
Time Elapsed 00:00:01.12

------ Build started: Project: ClientA, Configuration: Debug Any CPU ------
Build started 23/09/2010 9:55:31 a.m..
Build succeeded.
Time Elapsed 00:00:02.14
========== Build: 3 succeeded or up-to-date, 0 failed, 0 skipped ==========

and

------ Build started: Project: Connection, Configuration: Debug Any CPU ------
Build started 23/09/2010 9:53:16 a.m..
Build succeeded.
Time Elapsed 00:00:00.03

------ Build started: Project: Common, Configuration: Debug Any CPU ------
Compile complete -- 0 errors, 0 warnings
Build started 23/09/2010 9:53:16 a.m..
Build succeeded.
Time Elapsed 00:00:00.87

------ Build started: Project: ClientA, Configuration: Debug Any CPU ------
Build started 23/09/2010 9:53:17 a.m..
Build succeeded.
Time Elapsed 00:00:01.95
========== Build: 2 succeeded or up-to-date, 1 failed, 0 skipped ==========
A: 

Not sure exactly. My guess would be that you have absolute references in something (maybe one of your project files, as they are MSBuild files as well).

You know you can, via visual studio, right-click on a project in your solution, select the "Unload Project", and then edit the csproj file to meet your needs, right?

You may want to try that, and see if there's an absolute reference in one of the projects that is breaking.

Richard B
A: 

The logs are the same except for the name and the duration.

It could be a path problem like Richard B said, try searching the "X:\Projects\TaskRunner" in your .csproj/.vbproj files.

This might also be a rights problem, are the rights for the two directories the same? Are there svn problems (locks?)?

Either way, Making a rebuild or a clean and then a build and increasing the verbosity of the logger would help.

Benjamin Baumann
A: 

As a note for anyone else who comes across this, the actual problem was related to NTFS's maximum path length.

To explain further NTFS has a maximum length to a full path to a file (http://msdn.microsoft.com/en-us/library/aa365247.aspx). Our path structure was something along the lines of ( g:[...]\projects\Client\Client.Project\Client.Project.Library[...]. In short we blew out the maximum path length.

Renaming some of the directory names resolved the issue. Just a shame that VS2010 couldn't give a more reasonable error message / explanation.

cdmdotnet