2012-06-03 71 views
6

我正在使用Mono运行预建的应用程序,它与同一目录中的DLL(mysql.data.dll)一起运行。当我运行和Mono应用程序,我得到这个错误:无法从Mono中的程序集加载类型

Could not load type 'Snowlight.Storage.SqlDatabaseClient' from assembly 'Snowlight, Version=0.1.0.35857, Culture=neutral, PublicKeyToken=null'. 
    at System.Collections.Generic.Dictionary`2[System.Int32,Snowlight.Storage.SqlDatabaseClient].Init (Int32 capacity, IEqualityComparer`1 hcp) [0x00000] in <filename unknown>:0 
    at System.Collections.Generic.Dictionary`2[System.Int32,Snowlight.Storage.SqlDatabaseClient]..ctor() [0x00000] in <filename unknown>:0 
    at Snowlight.Storage.SqlDatabaseManager.Initialize() [0x00000] in <filename unknown>:0 
    at Snowlight.Program.Main (System.String[] args) [0x00000] in <filename unknown>:0 

来看由<filename unknown>,我假定这是因为它需要的DLL没有找到,那么我将如何让应用程序识别它,并用它?

回答

16

尝试从终端上运行它像这样:

export MONO_LOG_LEVEL=debug 
export MONO_LOG_MASK=asm 
mono --debug yourapp.exe 

现在每个组件查找将被打印到终端,这样你就可以找出什么正在寻找地方。

+0

谢谢! – n00b

相关问题