[英]how to combine 3rd party dll with own dll
我在C#中創建了一個庫TRSetup.dll。 該項目包括一些第三方DLL。 (例如:GalaSoft.MvvmLight.Extras.WPF4.dll,GalaSoft.MvvmLight.WPF4.dll,RemObjects.Hydra.dll)
我需要結合所有的DLL並創建一個單獨的DLL。
我正在使用ilMerge來組合dll。 我正在使用以下命令,
ilMerge /out:MergedSetup.dll /targetplatform:v4,"C:\Program Files\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.0\Profile\Client"
/lib: TRSetup.dll Galasoft.MvvmLight.Extras.WPF4.dll Galasoft.MvvmLight.WPF4.dll RemObject.Hydra.dll
我可以創建一個名為MergedSetup.dll的DLL,但在運行時它崩潰了。 我該如何合並這些dll。
先感謝您。
WPF(以及NHibernate,以及許多其他引用按名稱匯編的程序)和ILMerge的問題。 在ILMerge之后很長一段時間沒有這樣的裝配,它們都被注入主裝配。
嘗試嵌入而不是合並:LibZ( http://libz.codeplex.com/ )或Costura.Fody( https://github.com/Fody/Costura/ )
免責聲明:我是LibZ的作者。
干杯,
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.