Friday, April 3, 2015

MSBuild VCTargetPath, MSBuildToolsPath 프로퍼티

MSBuild 4.0에서 C++용 MSBuild 스크립트를 다루다 보면 다음 두가지의 프로퍼티 변수가 자주 나온다. 예를들어 Microsoft.Cpp.targets를 import할때 $(VCTargetPath)에서 import하는데 그 프로퍼티는 레지스트리에 저장되어 있으며 그 값은 다음과 같다.

이렇게 분리한 이유는 VCTargetPath는 Visual Studio 2010을 설치하면 생기는 C++전용 targets 파일들이고, MSBuildToolsPath에는 C++,C#등 공통적은 targets가 들어있다. 이 프로퍼티들은 import되는 targets를 분석하는데에는 알고있는 것이 유용하다. 왜냐하면 소스를 볼 일이 생길수도 있다.

$(VCTargetPath)
C:\Program Files (x86)\MSBuild\Microsoft.Cpp\v4.0

$(MSBuildToolsPath)
C:\Windows\Microsoft.NET\Framework\v4.0.30319

No comments:

Post a Comment