【问题标题】:VS2005 Web Deployment Project to VS2008 - ASPNET compiler errorsVS2005 Web 部署项目到 VS2008 - ASPNET 编译器错误
【发布时间】:2009-11-09 17:47:18
【问题描述】:

我在使用 wdproj 时遇到问题,我已升级到 VS2008;这是我在尝试使用 msbuild 编译项目时遇到的错误:

ASPNETCOMPILER : error ASPRUNTIME: The precompilation target directory (C:\code\CCI\CORUS\Website\Website_DeploymentProject\TempBuildDir\) cannot be in the same tree as the source application directory (C:\code\Website\).

这是我的wdproj 文件的相关部分的样子:

<Project DefaultTargets="Build;AfterBuild" xmlns="http://schemas.microsoft.com/developer/msbuild/2003" ToolsVersion="3.5">
 <PropertyGroup>
  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
    <Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
    <ProductVersion>8.0.60403</ProductVersion>
    <SchemaVersion>2.0</SchemaVersion>
    <ProjectGuid>{36799864-6917-499B-814B-F542D3C6828B}</ProjectGuid>
    <SourceWebPhysicalPath>..\SWebSite</SourceWebPhysicalPath>
    <SourceWebProject>{283D5526-6B10-4CD1-B492-0283D351DC77}|WebSite\WebSite.csproj</SourceWebProject>
    <SourceWebVirtualPath>/WebSite</SourceWebVirtualPath>
    <DebugSymbols>true</DebugSymbols>
    <OutputPath>$(BuildSourceCodePath)\WebSites\$(Configuration)</OutputPath>
    <EnableUpdateable>true</EnableUpdateable>
    <UseMerge>true</UseMerge>
    <UseWebConfigReplacement>true</UseWebConfigReplacement>
    <ValidateWebConfigReplacement>true</ValidateWebConfigReplacement>
  </PropertyGroup>

然而,这几乎无关紧要,因为我真正需要做的就是以某种方式更改/覆盖 %(TempBuildDir) 的位置,而无需手动破解 $(MSBuildExtensionsPath)\Microsoft\WebDeployment\v9.0\Microsoft.WebDeployment.targets

【问题讨论】:

    标签: .net asp.net msbuild wdproj


    【解决方案1】:

    解决方案很简单 - 将 .wdproj 文件上移一个级别,即移出您的网站项目,一切正常。

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 2014-07-31
      • 1970-01-01
      • 2010-11-03
      • 2010-11-24
      • 1970-01-01
      • 2011-07-25
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多