2009-08-27 3 views
11
를 사용하는 경우

내가 델파이 2009 년에 나는 .NET 3.5는 msbuild를 + Delphi2009

와 msbuild를 사용하고

을 프로젝트의 빌드를 자동화하기 위해 노력하고있어 "ERROR 프로젝트에는 대상이 없습니다 MSB4040"

는 단순히 전화 :

Z:\Server>C:\WINDOWS\Microsoft.NET\Framework\v3.5\msbuild "BestSellerAppServer.g 
roupproj" /target:Build 

그리고이 얻을 :

Build started 27/08/2009 01:15:45 p.m.. 
Project "Z:\Server\BestSellerAppServer.groupproj" on node 0 (Build target(s)). 
Project "Z:\Server\BestSellerAppServer.groupproj" (1) is building "Z:\Server\Be 
stSellerAppServer.dproj" (2) on node 0 (default targets). 
Z:\Server\BestSellerAppServer.dproj : error MSB4040: There is no target in the 
project. 
Done Building Project "Z:\Server\BestSellerAppServer.dproj" (default targets) - 
- FAILED. 

Done Building Project "Z:\Server\BestSellerAppServer.groupproj" (Build target(s 
)) -- FAILED. 


Build FAILED. 

"Z:\Server\BestSellerAppServer.groupproj" (Build target) (1) -> 
"Z:\Server\BestSellerAppServer.dproj" (default target) (2) -> 
    Z:\Server\BestSellerAppServer.dproj : error MSB4040: There is no target in th 
e project. 

    0 Warning(s) 
    1 Error(s) 

Time Elapsed 00:00:00.06 

나는 IDE 내에서 잘 컴파일합니다.

이 내용은 http://huwk.blogspot.com/2009/02/msbuild-fails-to-compile-delphi-2009.html이지만 문제는 해결되지 않았습니다.

답변

13

rsvars.bat라는 배치 파일 (RAD Studio 폴더에서 검색)이 있습니다. MSBuild를 호출하기 전에 호출하면 필요한 환경 변수가 설정됩니다. 컴파일러가 기본 위치와 다른 위치에 있으면 rsvars.bat에서 폴더가 올바른지 확인하십시오.

+0

고마워, 그건 속임수 야. – mamcx

+0

예, MSBuild.exe의 PATH 변수 업데이트 포함! – Nashev

5

"BDS"라는 환경 변수를 RAD Studio 폴더와 동일하게 설정 했습니까?

+1

예. 이것은해야 할 정확한 일입니다. 고맙습니다! –

관련 문제