2010-05-27 61 views
1

我想将我的FluentNHibernate升级到版本1.1,但是我发现它使用了Castle.Core 1.1。FluentNHibernate 1.1/Castle 1.1依赖关系

我在使用Castle.Core 1.2的我的应用程序中使用了Castle.Windsor 1.2。

我现在需要找到使用Castle.Core的早期版本的Castle.Windsor版本,但我无法在任何地方找到它。

你应该怎么做?

  • 等待使用最新Castle.Core的FluentNHibernate版本?

  • 或者使用最新的Castle.Core从源代码构建FluentNHibernate 1.1?

  • 或降级我的Castle.Windsor版本?

+1

你试图使用程序集绑定重定向(HTTP: //msdn.microsoft.com/en-us/library/2fc472t2(VS.71).aspx)? – miensol 2010-05-27 07:10:15

回答

1

如果你不想建立针对FluentNHibernate城堡的最新版本,添加到您的app.config/web.config文件:

<configuration> 
    <runtime> 
    <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> 
     <dependentAssembly> 
     <assemblyIdentity name="Castle.DynamicProxy2" publicKeyToken="407dd0808d44fbdc" culture="neutral" /> 
     <bindingRedirect oldVersion="2.1.0.0" newVersion="2.2.0.0" /> 
     </dependentAssembly> 
    </assemblyBinding> 
    <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"> 
     <dependentAssembly> 
     <assemblyIdentity name="Castle.Core" publicKeyToken="407dd0808d44fbdc" culture="neutral" /> 
     <bindingRedirect oldVersion="1.1.0.0" newVersion="1.2.0.0" /> 
     </dependentAssembly> 
    </assemblyBinding> 
    </runtime> 
</configuration> 
3

只有NHibernate.ByteCode.Castle.dll和Castle.DynamicProxy2.dll依赖于Castle.Core.dll。

你可以从Castle ActiveRecord 2.1.1 release得到它们针对Castle.Core.dll 1.2进行编译。

+0

我有一个稍微不相关的情况下的版本问题,但交换与您链接的组件,以解决我的问题。谢啦! – tishon 2011-06-23 09:53:36