Build Note

.net compactframework 3.5 에서 빌드 타임이 오래 걸리네..

김모작자 2011. 4. 17. 21:35

Visual Studio 2008 에서 WinCE 5 용 프로그램 만들던중..
4달 동안 작업한 소스를 빌드할때마다 특별한 이유없이 4~10분씩 걸리게 하던 문제였는데...
MSbuild 시스템의 플랫폼 체크하는 루틴의 문제였더라는..

몇 가지 더 있었는데..
암튼 해결 방법은

해당 프로젝트에서 사용하는 .net 버전을 따라가서...
예를 들면 난 3.5 였으니

C:\Windows\Microsoft.NET\Framework\v3.5

로 가서

Microsoft.CompactFramework.Common.targets 파일을 뒤져보자!!
xml 파일이라서 복잡한데.. 이중에..


    <Target
        Name="PlatformVerificationTask">
        <PlatformVerificationTask
            PlatformFamilyName="$(PlatformFamilyName)"
            PlatformID="$(PlatformID)"
            SourceAssembly="@(IntermediateAssembly)"
            ReferencePath="@(ReferencePath)"
            Condition="'$(SkipPlatformVerification)' != 'true'"
            TreatWarningsAsErrors="$(TreatWarningsAsErrors)"
            PlatformVersion="$(TargetFrameworkVersion)"/>
    </Target>


위와 같은 코드를 찾은 후 위에 두꺼운 글씨로 된 부분을 복사해 넣고나서...
저장하고~

[내 컴퓨터]의 시스템 환경 변수에 SkipPlatformVerification 는 true 를 설정해준다


이렇게 하고 나니깐 비로서 빌드 시간이 줄어들었다..

으미 아까운 내 시간..