帮助构建城堡动态代理

发布于 2024-08-12 23:10:09 字数 928 浏览 6 评论 0原文

所以我从 https://svn.castleproject.org/svn/castle 获取源代码/DynamicProxy/trunk/

在 vs.net 2008 中打开它

问题:

  1. vs.net 无法打开 assembly.cs
  2. 程序集签名失败

我在做什么,而不是不做什么?

更新

所以我下载了 nant,在我的 PATH 中设置 .bat 文件,以便它在 cmd 提示符下运行。

我运行:

nant default.build

收到此错误:

构建失败,\buildscripts\common-project.xml (48,3) 无效元素。未知的任务或数据类型。

现在我到底该如何构建dynamicProxy项目呢?

更新 这就是我所做的,请看截图:

哦,我的南特是:

@echo off “E:\dev\tools\nant-bin\nant-0.86-nightly-2009-05-05\bin\Nant.exe” %*

http://img697.imageshack.us/img697/5623/castlebuildscreenshot.png http://img697.imageshack.us/img697/5623/castlebuildscreenshot.png

So I pulled the source from https://svn.castleproject.org/svn/castle/DynamicProxy/trunk/

Open it up in vs.net 2008

problems:

  1. vs.net can't open the assembly.cs
  2. assembly signing failed

What am I doing, rather NOT doing?

Update

So I downloaded nant, setup the .bat file in my PATH so it works in cmd prompt.

I ran:

nant default.build

Getting this error:

build failed, \buildscripts\common-project.xml (48,3)
invalid element . Unknown task or datatype.

How exactly do I build the dynamicProxy project now?

update
This is what I did, see screenshot:

oh and my nant is:

@echo off
"E:\dev\tools\nant-bin\nant-0.86-nightly-2009-05-05\bin\Nant.exe" %*

http://img697.imageshack.us/img697/5623/castlebuildscreenshot.png http://img697.imageshack.us/img697/5623/castlebuildscreenshot.png

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(3

说不完的你爱 2024-08-19 23:10:09

您需要首先使用 NAnt (http://nant.sf.net) 运行构建脚本。这将生成 assembly.cs 文件。查看树中的 .build 文件以了解它们在做什么。

至于程序集签名失败,请检查项目设置以删除对 CastleKey.snk 的引用。它应该使用 DynProxy.snk (理论上)对其进行签名。

You need to run the build script first using NAnt (http://nant.sf.net). This will generate the assembly.cs file. Take a look at the .build files in the tree to see what they are doing.

As for the assembly signing failing, check the project settings to get rid of references to CastleKey.snk. It should sign it using DynProxy.snk (in theory).

不必了 2024-08-19 23:10:09

更新:

NUnit 的问题现已修复。进行干净的检查。我真的不知道你为什么会收到这个错误。您使用的是哪个版本的 NAnt?确保您拥有最新版本(之前不支持 . NET 3.5)


您应该能够从主干中提取源代码,并使用 nant 进行构建(我刚刚这样做了并且它有效)。好吧,我撒谎了,看起来对 NUnit 的引用是错误的,因此单元测试项目将无法正确构建:

 构建失败 - 0 个非致命错误,1 个警告

        D:\ OLD \ DynamicProxy \ buildscripts \ common-project.xml(295,5):
        “nunit-console.exe”无法启动。
            系统找不到指定的文件

        总时间:1.2秒。

构建失败

嵌套构建失败。参考构建
记录确切原因。

总时间:3.4秒。

然而,重要的事情(程序集信息生成)将会成功,您应该能够打开 Castle.DynamicProxy2-vs2008.sln,修复对 NUnit 程序集的引用,按 F5 并构建代码,没有任何问题。

我只是在一次干净的检查中完成了它,并且成功了。

一般来说,如果您打算对 DP 代码库进行修改,建议先去 Castle 用户组并在那里进行讨论。

UPDATE:

The issue with NUnit is now fixed. Do a clean check out. I really have no idea why you're getting that error. Which version of NAnt are you using? Make sure you have the latest (earlier do not have support for .NET 3.5)


You should be able to just pull the source from the trunk, and build with nant (I just did that and it worked). Ok, I lied, looks like the reference to NUnit is wrong, so the unit test project will not build correctly:

        BUILD FAILED - 0 non-fatal error(s), 1 warning(s)

        D:\OLD\DynamicProxy\buildscripts\common-project.xml(295,5):
        'nunit-console.exe' failed to start.
            The system cannot find the file specified

        Total time: 1.2 seconds.

BUILD FAILED

Nested build failed. Refer to build
log for exact reason.

Total time: 3.4 seconds.

However the important stuff (assemblyinfo generation) will succeed and you should be able to just open Castle.DynamicProxy2-vs2008.sln, fix the reference to the NUnit assembly hit F5 and build the code with no issues.

I just did it on a clean check out, and it worked.

Generally if you're planning to do modifications in DP codebase, it is advised to go to the Castle user group first, and discuss it there.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文