代码之家  ›  专栏  ›  技术社区  ›  LiamB

ccnet和.net 4.0

  •  1
  • LiamB  · 技术社区  · 15 年前

    无法加载文件或程序集 “System.Data”或其一个 依赖关系。试图 用不正确的 格式

    我们刚刚将一个项目升级到.NET 4.0,并重新配置了构建服务器(cruise control.net)。有人能帮上忙吗?我在下面列出了更多的线索。

    >     debug:
    >     
    >          [copy] Copying 1 file to 'C:\Builds\SilverChip\Working\sc.website\web.config'.
    >          [copy] Copying 1 file to 'C:\Builds\SilverChip\Working\sc.admin\web.config'.
    >          [copy] Copying 1 file to 'C:\Builds\SilverChip\Working\sc.website\bin\Intelligencia.UrlRewriter.dll'.
    >          [copy] Copying 1 file to 'C:\Builds\SilverChip\Working\sc.website\bin\UrlRewritingNet.UrlRewriter.dll'.
    >          [exec] Microsoft (R) Build Engine Version 4.0.30319.1
    >          [exec] [Microsoft .NET Framework, Version 4.0.30319.1]
    >          [exec] Copyright (C) Microsoft Corporation 2007. All rights
    > reserved.
    >          [exec] 
    >          [exec] Build started 11/05/2010 12:02:16.
    >          [exec] Project "C:\Builds\SilverChip\Working\Silverchip.sln"
    > on node 1 (default targets).
    >          [exec] ValidateSolutionConfiguration:
    >          [exec]   Building solution configuration "Debug|Any CPU".
    >          [exec] Project "C:\Builds\SilverChip\Working\Silverchip.sln"
    > (1) is building
    > "C:\Builds\SilverChip\Working\sc.lib\sc.lib.csproj"
    > (2) on node 1 (default targets).
    >          [exec] CoreCompile:
    >          [exec] Skipping target "CoreCompile" because all output files
    > are up-to-date with respect to the
    > input files.
    >          [exec] _CopyAppConfigFile:
    >          [exec] Skipping target "_CopyAppConfigFile" because all
    > output files are up-to-date with
    > respect to the input files.
    >          [exec] CopyFilesToOutputDirectory:
    >          [exec]   sc.lib -> C:\Builds\SilverChip\Working\sc.lib\bin\Debug\sc.lib.dll
    >          [exec] Done Building Project "C:\Builds\SilverChip\Working\sc.lib\sc.lib.csproj"
    > (default targets).
    >          [exec] Project "C:\Builds\SilverChip\Working\Silverchip.sln"
    > (1) is building
    > "C:\Builds\SilverChip\Working\sc_admin.metaproj"
    > (3) on node 1 (default targets).
    >          [exec] Build:
    >          [exec]   Copying file from "C:\Builds\SilverChip\Working\sc.lib\bin\Debug\sc.lib.dll"
    > to "sc.admin\\Bin\sc.lib.dll".
    >          [exec]   Copying file from "C:\Builds\SilverChip\Working\sc.lib\bin\Debug\SubSonic.Core.dll"
    > to "sc.admin\\Bin\SubSonic.Core.dll".
    >          [exec]   Copying file from "C:\Builds\SilverChip\Working\sc.lib\bin\Debug\sc.lib.pdb"
    > to "sc.admin\\Bin\sc.lib.pdb".
    >          [exec]   C:\Windows\Microsoft.NET\Framework\v4.0.30319\aspnet_compiler.exe
    > -v /sc.admin -p sc.admin\ -u -f -d PrecompiledWeb\sc.admin\ 
    >          [exec] ASPNETCOMPILER : error ASPCONFIG: Could not load file or
    > assembly 'System.Data' or one of its
    > dependencies. An attempt was made to
    > load a program with an incorrect
    > format.
    > [C:\Builds\SilverChip\Working\sc_admin.metaproj]
    >          [exec] Done Building Project "C:\Builds\SilverChip\Working\sc_admin.metaproj"
    > (default targets) -- FAILED.
    >          [exec] Project "C:\Builds\SilverChip\Working\Silverchip.sln"
    > (1) is building
    > "C:\Builds\SilverChip\Working\sc_website.metaproj"
    > (4) on node 1 (default targets).
    >          [exec] Build:
    >          [exec]   Copying file from "C:\Builds\SilverChip\Working\sc.lib\bin\Debug\sc.lib.dll"
    > to "sc.website\\Bin\sc.lib.dll".
    >          [exec]   Copying file from "C:\Builds\SilverChip\Working\sc.lib\bin\Debug\SubSonic.Core.dll"
    > to
    > "sc.website\\Bin\SubSonic.Core.dll".
    >          [exec]   Copying file from "C:\Builds\SilverChip\Working\sc.lib\bin\Debug\sc.lib.pdb"
    > to "sc.website\\Bin\sc.lib.pdb".
    >          [exec]   C:\Windows\Microsoft.NET\Framework\v4.0.30319\aspnet_compiler.exe
    > -v /sc.website -p sc.website\ -u -f -d PrecompiledWeb\sc.website\ 
    >          [exec] ASPNETCOMPILER : error ASPCONFIG: Could not load file or
    > assembly 'System.Data' or one of its
    > dependencies. An attempt was made to
    > load a program with an incorrect
    > format.
    > [C:\Builds\SilverChip\Working\sc_website.metaproj]
    >          [exec] Done Building Project "C:\Builds\SilverChip\Working\sc_website.metaproj"
    > (default targets) -- FAILED.
    >          [exec] Done Building Project "C:\Builds\SilverChip\Working\Silverchip.sln"
    > (default targets) -- FAILED.
    >          [exec] 
    >          [exec] Build FAILED.
    >          [exec] 
    >          [exec] "C:\Builds\SilverChip\Working\Silverchip.sln"
    > (default target) (1) ->
    >          [exec] "C:\Builds\SilverChip\Working\sc_admin.metaproj"
    > (default target) (3) ->
    >          [exec] (Build target) -> 
    >          [exec]   ASPNETCOMPILER : error ASPCONFIG: Could not load file
    > or assembly 'System.Data' or one of
    > its dependencies. An attempt was made
    > to load a program with an incorrect
    > format.
    > [C:\Builds\SilverChip\Working\sc_admin.metaproj]
    >          [exec] 
    >          [exec] 
    >          [exec] "C:\Builds\SilverChip\Working\Silverchip.sln"
    > (default target) (1) ->
    >          [exec] "C:\Builds\SilverChip\Working\sc_website.metaproj"
    > (default target) (4) ->
    >          [exec]   ASPNETCOMPILER : error ASPCONFIG: Could not load file
    > or assembly 'System.Data' or one of
    > its dependencies. An attempt was made
    > to load a program with an incorrect
    > format.
    > [C:\Builds\SilverChip\Working\sc_website.metaproj]
    >          [exec] 
    >          [exec]     0 Warning(s)
    >          [exec]     2 Error(s)
    >          [exec]
    
    1 回复  |  直到 15 年前
        1
  •  1
  •   LiamB    15 年前

    我通过删除bin文件夹中的所有dll并允许生成重新加载新的.NET 4.0 dll来修复此问题。