我有一個應用程序,我在嵌入式Debian BeagleBone黑色系統上運行。.NET配置系統與MKBundle單聲道的依賴關係
我有我的設備之一,我已經安裝了整個mono-complete和mono-devel軟件包來開發一切。
我有另一個設備,就是我們的股票嵌入式debian安裝映像在另一個BeagleBone黑色設備上。這將是我們的目標系統。
在開發設備上,應用程序在正常運行時運行良好。
我使用此命令行創建的應用程序的束:
mkbundle -o MYEXE.EXE --static --deps SourceExe.exe dll1.dll dll2.dll
此創建捆綁在dev設備上運行就好了。
當我嘗試在我的目標dev設備上運行相同的軟件包MyExe.exe開始運行並輸出一些嵌入到其中的調試消息。
問題是當它到達需要讀取MyExe.exe.config文件的部分。這個配置文件中有一個appSettings部分。
請記住,它在dev設備上運行良好,因此它或配置文件中沒有固有的錯誤。
這裏是所有獲得包括組件(注意System.Configuration.dll):
embedding: /usr/lib/mono/4.5/mscorlib.dll
embedding: /usr/lib/mono/gac/System/4.0.0.0__b77a5c561934e089/System.dll
embedding: /usr/lib/mono/gac/Mono.Security/4.0.0.0__0738eb9f132ed756/Mono.Security.dll
embedding: /usr/lib/mono/gac/System.Configuration/4.0.0.0__b03f5f7f11d50a3a/System.Configuration.dll
embedding: /usr/lib/mono/gac/System.Xml/4.0.0.0__b77a5c561934e089/System.Xml.dll
embedding: /usr/lib/mono/gac/System.Security/4.0.0.0__b03f5f7f11d50a3a/System.Security.dll
embedding: /usr/lib/mono/gac/System.Core/4.0.0.0__b77a5c561934e089/System.Core.dll
embedding: /usr/lib/mono/gac/Mono.Posix/4.0.0.0__0738eb9f132ed756/Mono.Posix.dll
embedding: /usr/lib/mono/gac/System.Xml.Linq/4.0.0.0__b77a5c561934e089/System.Xml.Linq.dll
embedding: /usr/lib/mono/gac/System.Runtime.Serialization/4.0.0.0__b77a5c561934e089/System.Runtime.Serialization.dll
embedding: /usr/lib/mono/gac/System.ServiceModel.Internals/0.0.0.0__b77a5c561934e089/System.ServiceModel.Internals.dll
embedding: /usr/lib/mono/gac/Microsoft.CSharp/4.0.0.0__b03f5f7f11d50a3a/Microsoft.CSharp.dll
embedding: /usr/lib/mono/gac/Mono.CSharp/4.0.0.0__0738eb9f132ed756/Mono.CSharp.dll
embedding: /usr/lib/mono/gac/System.ComponentModel.Composition/4.0.0.0__b77a5c561934e089/System.ComponentModel.Composition.dll
embedding: /home/diablosp/ign/PowerteqDeviceUpdate.dll
embedding: /usr/lib/mono/gac/System.ServiceModel/4.0.0.0__b77a5c561934e089/System.ServiceModel.dll
embedding: /usr/lib/mono/gac/System.Messaging/4.0.0.0__b03f5f7f11d50a3a/System.Messaging.dll
embedding: /usr/lib/mono/gac/Mono.Messaging/4.0.0.0__0738eb9f132ed756/Mono.Messaging.dll
embedding: /usr/lib/mono/gac/System.Configuration.Install/4.0.0.0__b03f5f7f11d50a3a/System.Configuration.Install.dll
embedding: /usr/lib/mono/gac/System.Windows.Forms/4.0.0.0__b77a5c561934e089/System.Windows.Forms.dll
config from: /usr/lib/mono/gac/System.Windows.Forms/4.0.0.0__b77a5c561934e089/System.Windows.Forms.dll.config
embedding: /usr/lib/mono/gac/System.Drawing/4.0.0.0__b03f5f7f11d50a3a/System.Drawing.dll
config from: /usr/lib/mono/gac/System.Drawing/4.0.0.0__b03f5f7f11d50a3a/System.Drawing.dll.config
embedding: /usr/lib/mono/gac/Mono.WebBrowser/4.0.0.0__0738eb9f132ed756/Mono.WebBrowser.dll
config from: /usr/lib/mono/gac/Mono.WebBrowser/4.0.0.0__0738eb9f132ed756/Mono.WebBrowser.dll.config
embedding: /usr/lib/mono/gac/System.Runtime.Serialization.Formatters.Soap/4.0.0.0__b03f5f7f11d50a3a/System.Runtime.Serialization.Formatters.Soap.dll
embedding: /usr/lib/mono/gac/Accessibility/4.0.0.0__b03f5f7f11d50a3a/Accessibility.dll
embedding: /usr/lib/mono/gac/System.Data/4.0.0.0__b77a5c561934e089/System.Data.dll
config from: /usr/lib/mono/gac/System.Data/4.0.0.0__b77a5c561934e089/System.Data.dll.config
embedding: /usr/lib/mono/gac/System.Numerics/4.0.0.0__b77a5c561934e089/System.Numerics.dll
embedding: /usr/lib/mono/gac/System.Transactions/4.0.0.0__b77a5c561934e089/System.Transactions.dll
embedding: /usr/lib/mono/gac/Mono.Data.Tds/4.0.0.0__0738eb9f132ed756/Mono.Data.Tds.dll
embedding: /usr/lib/mono/gac/System.EnterpriseServices/4.0.0.0__b03f5f7f11d50a3a/System.EnterpriseServices.dll
embedding: /usr/lib/mono/gac/System.Web/4.0.0.0__b03f5f7f11d50a3a/System.Web.dll
embedding: /usr/lib/mono/gac/System.Web.ApplicationServices/4.0.0.0__31bf3856ad364e35/System.Web.ApplicationServices.dll
embedding: /usr/lib/mono/gac/System.Web.Services/4.0.0.0__b03f5f7f11d50a3a/System.Web.Services.dll
embedding: /usr/lib/mono/gac/System.Design/4.0.0.0__b03f5f7f11d50a3a/System.Design.dll
embedding: /usr/lib/mono/gac/System.DirectoryServices/4.0.0.0__b03f5f7f11d50a3a/System.DirectoryServices.dll
embedding: /usr/lib/mono/gac/Novell.Directory.Ldap/4.0.0.0__0738eb9f132ed756/Novell.Directory.Ldap.dll
embedding: /usr/lib/mono/gac/Mono.Data.Sqlite/4.0.0.0__0738eb9f132ed756/Mono.Data.Sqlite.dll
embedding: /usr/lib/mono/gac/System.ComponentModel.DataAnnotations/4.0.0.0__31bf3856ad364e35/System.ComponentModel.DataAnnotations.dll
embedding: /usr/lib/mono/gac/System.IdentityModel/4.0.0.0__b77a5c561934e089/System.IdentityModel.dll
embedding: /usr/lib/mono/gac/System.ServiceModel.Activation/4.0.0.0__31bf3856ad364e35/System.ServiceModel.Activation.dll
embedding: /usr/lib/mono/gac/System.IdentityModel.Selectors/4.0.0.0__b77a5c561934e089/System.IdentityModel.Selectors.dll
我得到的例外是(你大概可以忽略關於部件組成是的只是結果。錯誤,主要問題是它在配置文件的appSettings部分有問題,請記住它在開發設備上工作,唯一的區別是dev設備具有完整的單聲道單聲道和單聲道開發):
[ERROR] FATAL UNHANDLED EXCEPTION: System.ComponentModel.Composition.CompositionException: The composition produced a single composition error. The root cause is provided below. Review the CompositionException.Errors property for more detailed information.
1) Unrecognized configuration section <appSettings> (/home/diablosp/ign/Ignition.CommandLine.exe.config line 3)
Resulting in: Error Initializing the configuration system.
Resulting in: An exception occurred while trying to create an instance of type 'NonWindowsCommon.BasicLog'.
Resulting in: Cannot activate part 'NonWindowsCommon.BasicLog'.
Element: NonWindowsCommon.BasicLog --> NonWindowsCommon.BasicLog --> DirectoryCatalog (Path="/home/diablosp/ign/")
Resulting in: Cannot get export 'NonWindowsCommon.BasicLog (ContractName="Common.Interfaces.ILog")' from part 'NonWindowsCommon.BasicLog'.
Element: NonWindowsCommon.BasicLog (ContractName="Common.Interfaces.ILog") --> NonWindowsCommon.BasicLog --> DirectoryCatalog (Path="/home/diablosp/ign/")
at System.ComponentModel.Composition.Hosting.CompositionServices.GetExportedValueFromComposedPart (System.ComponentModel.Composition.Hosting.ImportEngine engine, System.ComponentModel.Composition.Primitives.ComposablePart part, System.ComponentModel.Composition.Primitives.ExportDefinition definition) [0x0001b] in <0007e672dd7f4959adc6f8103d9c843f>:0
at System.ComponentModel.Composition.Hosting.CatalogExportProvider.GetExportedValue (System.ComponentModel.Composition.Hosting.CatalogExportProvider+CatalogPart part, System.ComponentModel.Composition.Primitives.ExportDefinition export, System.Boolean isSharedPart) [0x00034] in <0007e672dd7f4959adc6f8103d9c843f>:0
at System.ComponentModel.Composition.Hosting.CatalogExportProvider+CatalogExport.GetExportedValueCore() [0x00018] in <0007e672dd7f4959adc6f8103d9c843f>:0
at System.ComponentModel.Composition.Primitives.Export.get_Value() [0x00012] in <0007e672dd7f4959adc6f8103d9c843f>:0
at NonWindowsCommon.MefDI.One (System.Type t) [0x00029] in <c227ad8f1c41442389e89c655163f0ce>:0
at NonWindowsCommon.MefDI.One[T]() [0x0002a] in <c227ad8f1c41442389e89c655163f0ce>:0
at Ignition.CommandLine.Program.Configure() [0x000b1] in <6b59edb08c7748fd97fda94a23fc9e1c>:0
at Ignition.CommandLine.Program..ctor() [0x00012] in <6b59edb08c7748fd97fda94a23fc9e1c>:0
at Ignition.CommandLine.Program.Main (System.String[] args) [0x00001] in <6b59edb08c7748fd97fda94a23fc9e1c>:0