我用Debian 8派生操作系统编写了一个运行在我的目标Linux BeagleBone Black上的应用程序。
如果我安装整个单运行时,它就会运行。这是太大的最终目标,我将运行它。
我想使用mkbundle创建一个包含所有内容的静态包。
我遇到的问题是,我在这个应用程序中使用MEF和依赖注入,当我运行mkbundle创建的最后一个包时,我得到了如下所示的错误。
我怀疑这是因为MEF和/或我的应用程序是通过加载DLL程序集来加载大多数导出的,它们都嵌入在包中。
有人能解释一下这件事吗?
以下是错误:
[ERROR] FATAL UNHANDLED EXCEPTION: System.ArgumentException: 'path' cannot be an empty string ("").
Parameter name: path
at Microsoft.Internal.Requires.NotNullOrEmpty (System.String value, System.String parameterName) [0x00022] in <0007e672dd7f4959adc6f8103d9c843f>:0
at System.ComponentModel.Composition.Hosting.DirectoryCatalog..ctor (System.String path, System.String searchPattern) [0x00011] in <0007e672dd7f4959adc6f8103d9c843f>:0
at NonWindowsCommon.MefDI.<DirectoryCatalogContainer>m__1 (System.String path) [0x00022] in <15e2f18d34444e41a666c99ead602eed>:0
at System.Linq.Enumerable+WhereSelectEnumerableIterator`2[TSource,TResult].MoveNext () [0x00064] in <63992662b765477a898ef49cdcc99ee2>:0
at System.Diagnostics.Contracts.Contract.ForAll[T] (System.Collections.Generic.IEnumerable`1[T] collection, System.Predicate`1[T] predicate) [0x00048] in <8f2c484307284b51944a1a13a14c0266>:0
at Microsoft.Internal.Requires.NotNullElements[T] (System.Collections.Generic.IEnumerable`1[T] values, System.String parameterName) [0x00013] in <0007e672dd7f4959adc6f8103d9c843f>:0
at Microsoft.Internal.Requires.NullOrNotNullElements[T] (System.Collections.Generic.IEnumerable`1[T] values, System.String parameterName) [0x00000] in <0007e672dd7f4959adc6f8103d9c843f>:0
at System.ComponentModel.Composition.Hosting.AggregateCatalog..ctor (System.Collections.Generic.IEnumerable`1[T] catalogs) [0x00006] in <0007e672dd7f4959adc6f8103d9c843f>:0
at NonWindowsCommon.MefDI.DirectoryCatalogContainer (System.String basepath) [0x0002c] in <15e2f18d34444e41a666c99ead602eed>:0
at Ignition.CommandLine.Program.Configure () [0x0006b] in <c9925f8b4dd141c2a6ea39dd7842d0d4>:0
at Ignition.CommandLine.Program..ctor () [0x00012] in <c9925f8b4dd141c2a6ea39dd7842d0d4>:0
at Ignition.CommandLine.Program.Main (System.String[] args) [0x00001] in <c9925f8b4dd141c2a6ea39dd7842d0d4>:0 发布于 2017-03-16 14:22:22
原来,我们的其他开发人员之一编写的代码是使用exe路径创建我们的组合容器。当从创建的EXE的mkbundle内部运行时,这个exe路径是主EXE的"“。
这导致开发人员编写的代码使用空路径。
我能够通过简单地跟踪真正的EXE路径并在用于创建容器的方法中传递它来解决这个问题。
https://stackoverflow.com/questions/42819286
复制相似问题