Fix loading C# assemblies from Mono AOT output
This commit is contained in:
@@ -761,6 +761,16 @@ MClass::MClass(const MAssembly* parentAssembly, void* handle, const char* name,
|
||||
classHandles.Add(handle, this);
|
||||
}
|
||||
|
||||
bool MAssembly::ResolveMissingFile(String& assemblyPath) const
|
||||
{
|
||||
#if DOTNET_HOST_MONO
|
||||
// Fallback to AOT-ed assembly location
|
||||
assemblyPath = Globals::BinariesFolder / TEXT("Dotnet") / StringUtils::GetFileName(assemblyPath);
|
||||
return !FileSystem::FileExists(assemblyPath);
|
||||
#endif
|
||||
return true;
|
||||
}
|
||||
|
||||
MClass::~MClass()
|
||||
{
|
||||
_methods.ClearDelete();
|
||||
|
||||
@@ -1170,6 +1170,11 @@ bool MAssembly::UnloadImage(bool isReloading)
|
||||
return false;
|
||||
}
|
||||
|
||||
bool MAssembly::ResolveMissingFile(String& assemblyPath) const
|
||||
{
|
||||
return true;
|
||||
}
|
||||
|
||||
MClass::MClass(const MAssembly* parentAssembly, MonoClass* monoClass, const StringAnsi& fullname)
|
||||
: _assembly(parentAssembly)
|
||||
, _fullname(fullname)
|
||||
|
||||
Reference in New Issue
Block a user