if (m_comm.RemoteIsEFI ())
{
- m_dyld_plugin_name = DynamicLoaderStatic::GetPluginNameStatic();
+ // Select an invalid plugin name for the dynamic loader so one doesn't get used
+ // since EFI does its own manual loading via python scripting
+ static ConstString g_none_dynamic_loader("none");
+ m_dyld_plugin_name = g_none_dynamic_loader;
+
+ if (kernel_uuid.IsValid()) {
+ // If EFI passed in a UUID= try to lookup UUID
+ // The slide will not be provided. But the UUID
+ // lookup will be used to launch EFI debug scripts
+ // from the dSYM, that can load all of the symbols.
+ ModuleSpec module_spec;
+ module_spec.GetUUID() = kernel_uuid;
+ module_spec.GetArchitecture() = m_target.GetArchitecture();
+
+ // Lookup UUID locally, before attempting dsymForUUID like action
+ module_spec.GetSymbolFileSpec() = Symbols::LocateExecutableSymbolFile(module_spec);
+ if (module_spec.GetSymbolFileSpec())
+ module_spec.GetFileSpec() = Symbols::LocateExecutableObjectFile (module_spec);
+ if (!module_spec.GetSymbolFileSpec() || !module_spec.GetSymbolFileSpec())
+ Symbols::DownloadObjectAndSymbolFile (module_spec, true);
+
+ if (module_spec.GetFileSpec().Exists())
+ {
+ ModuleSP module_sp(new Module (module_spec.GetFileSpec(), m_target.GetArchitecture()));
+ if (module_sp.get() && module_sp->MatchesModuleSpec (module_spec))
+ {
+ // Get the current target executable
+ ModuleSP exe_module_sp (m_target.GetExecutableModule ());
+
+ // Make sure you don't already have the right module loaded and they will be uniqued
+ if (exe_module_sp.get() != module_sp.get())
+ m_target.SetExecutableModule (module_sp, false);
+ }
+ }
+ }
}
else if (m_comm.RemoteIsDarwinKernel ())
{