Rob Bowman
Rob Bowman

Reputation: 8701

TFS 2010 Solution with multiple dependencies

I am new to build on TFS 2010.

I have 4 C# solutions. One of these solution has a dependency on the assembly produced by each of the other 3 "helper solutions".

I'd like to create a build definition which would build my 3 helper solutions then build the top level solution.

On the build definition dialog I have tried to add each of the 4 solution files to the Workspace tab, with a build agent folder of $(SourceDir) - but I get the error dialog "TF215040: The path $(SourceDir) can only be mapped one time in a given workspace". So I change the mapping for the helper solutions to the build folder used by their respective individual build definition.

On the Process Tab, under the Items to Build property I've added the solution file for each of the 4 solutions, with the parent solution listed last.

When I queue the top level build defintion I get the error message: "The path C:\Builds\3\x.Int.Common\x.Int.Common\Sources is already mapped in workspace xBLD01."

Note: when I run "tf.exe workspaces /owner:*" I notice that my workspaces is listed multiple times, with different owners but the computer name is also the same. I guess this is because there's 3 in the team using the same VM image - they're not connected to the domain. Maybe this is the cause of the problem?

Could anyone please suggest a solution?

Thanks

Rob.

Upvotes: 0

Views: 890

Answers (1)

Dylan Smith
Dylan Smith

Reputation: 22235

Just map the root folder that contains all 4 solutions under it in the workspace mapping. For example, if your folder structure looks like this:

C:\MyProject\Solution1\1.sln

C:\MyProject\Solution2\2.sln

...

Just map C:\MyProject\ -> $(SourceDir)

If the workspace mappings have gotten messed up on your build server you can download the TFS SideKicks tool to delete all the workspaces on the build server, and the TFS Build will just recreate them proper ones next time you run it.

Upvotes: 2

Related Questions