本文介绍了将解决方案从VS2005转换为VS2012的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试将解决方案从VS2005转换为VS2012.我遇到的问题之一是目录名称.例如,如果我将输出目录设置为:

$(SolutionDir).. \ VisualStudioBuildProducts \ $(ProjectName)\ $(PlatformName)\ $(Configuration)\ Products

构建工作正常,但是,如果我尝试进行清洁,则会得到:

搜索模式不能包含".."以向上移动目录,并且只能在内部包含在文件/目录名称中,例如"a..b".

假设我删除".."并将输出目录设置为:

(SolutionDir)VisualStudioBuildProducts \ $(项目名称)\ $(平台名称)\ $(配置)\产品

我收到错误消息:

C:\ Program Files(x86)\ MSBuild \ Microsoft.Cpp \ v4.0 \ V110 \ Microsoft.CppClean.targets(75,5):错误:第二个路径片段不能是驱动器或UNC名称. br/>
C:\ Program Files(x86)\ MSBuild \ Microsoft.Cpp \ v4.0 \ V110 \ Microsoft.CppClean.targets(75,5):错误:参数名称:path2


有人可以解释我该如何解决吗?我确实更喜欢在目录路径中包含"..",但是如果没有,至少如何消除第二个错误?

I am trying to convert solution from VS2005 to VS2012. One of the problem I have is with directories names. For example, if I set Output Directory to be:

$(SolutionDir)..\VisualStudioBuildProducts\$(ProjectName)\$(PlatformName)\$(Configuration)\Products

the build works, however if I try to make Clean I get:

Search pattern cannot contain ".." to move up directories and can be contained only internally in file/directory names, as in "a..b".

Suppose I remove ".." and set Output Directory to be:

(SolutionDir)VisualStudioBuildProducts\$(ProjectName)\$(PlatformName)\$(Configuration)\Products

I get the error:

C:\Program Files (x86)\MSBuild\Microsoft.Cpp\v4.0\V110\Microsoft.CppClean.targets(75,5): error : Second path fragment must not be a drive or UNC name.

C:\Program Files (x86)\MSBuild\Microsoft.Cpp\v4.0\V110\Microsoft.CppClean.targets(75,5): error : Parameter name: path2


Can someone explain me how to fix it? I do prefer to have ".." inside the directory path, but if not, at least how to remove the second error?

推荐答案




这篇关于将解决方案从VS2005转换为VS2012的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

09-03 03:48