c# - MS Build Import Question Path -



c# - MS Build Import Question Path -

quick question msbuild. have next msbuild file in directory d:\mydirectory

<project xmlns="http://schemas.microsoft.com/developer/msbuild/2003" > <import project="d:\mydirectory\buildtest\buildtest\buildtest.csproj"></import> </project>

when run build fails because buildtest.csproj can't find .cs source files , seems looking in d:\mydirectory. expecting working directory set of buildtest.csproj , able resolve references. doing wrong?

i think ,the import element used import other msbuild projects 1 (see here). if want specify c# projects build, should this:

<project xmlns="http://schemas.microsoft.com/developer/msbuild/2003" > <itemgroup> <projectreferences include="d:\mydirectory\buildtest\buildtest\buildtest.csproj" /> <!--more--> </itemgroup>

then if want build referenced projects, can illustration this:

<target name="buildallprojects"> <msbuild continueonerror="false" projects="@(projectreferences)" targets="clean;rebuild"> </msbuild> </target>

remember though, 1 of many ways of doing things msbuild. there lot of articles on msdn on topic, should require more customization.

c# .net msbuild

Comments

Popular posts from this blog

java - How to pass parameters between Request-Scoped Controllers? -

string - what is the difference between "some" == "some\0" and strcmp("some","some\0") in c++? -

actionscript 3 - Flex: moving a point with rotation doesnt change the point XY? -