mirror of
https://github.com/danbulant/Cosmos
synced 2026-05-24 12:35:31 +00:00
This commit is contained in:
parent
99c7f96792
commit
f19e133ef6
6 changed files with 91 additions and 78 deletions
|
|
@ -6,6 +6,8 @@ using Microsoft.VisualStudio;
|
|||
using Microsoft.VisualStudio.Debugger.Interop;
|
||||
using System.Diagnostics;
|
||||
using System.Threading;
|
||||
using System.Collections.Specialized;
|
||||
using Cosmos.Debug.Common;
|
||||
|
||||
namespace Cosmos.Debug.VSDebugEngine
|
||||
{
|
||||
|
|
@ -355,6 +357,9 @@ namespace Cosmos.Debug.VSDebugEngine
|
|||
{
|
||||
m_engineCallback = new EngineCallback(this, aAD7Callback);
|
||||
|
||||
var xDebugInfo = new NameValueCollection();
|
||||
NameValueCollectionHelper.LoadFromString(xDebugInfo, aDebugInfo);
|
||||
|
||||
//string commandLine = EngineUtils.BuildCommandLine(exe, args);
|
||||
//ProcessLaunchInfo processLaunchInfo = new ProcessLaunchInfo(exe, commandLine, dir, env, options, launchFlags, hStdInput, hStdOutput, hStdError);
|
||||
// We are being asked to debug a process when we currently aren't debugging anything
|
||||
|
|
@ -365,9 +370,8 @@ namespace Cosmos.Debug.VSDebugEngine
|
|||
// var m_debuggedProcess = Worker.LaunchProcess(m_engineCallback, processLaunchInfo);
|
||||
//}));
|
||||
|
||||
|
||||
AD7EngineCreateEvent.Send(this);
|
||||
var xProcess = new AD7Process(aDebugInfo, m_engineCallback, this, aPort);
|
||||
var xProcess = new AD7Process(xDebugInfo, m_engineCallback, this, aPort);
|
||||
aProcess = xProcess;
|
||||
mProcess = xProcess;
|
||||
m_ad7ProgramId = xProcess.mID;
|
||||
|
|
|
|||
|
|
@ -123,12 +123,13 @@ namespace Cosmos.Debug.VSDebugEngine {
|
|||
|
||||
public string mISO;
|
||||
public string mProjectFile;
|
||||
internal AD7Process(string aDebugInfo, EngineCallback aCallback, AD7Engine aEngine, IDebugPort2 aPort) {
|
||||
internal AD7Process(NameValueCollection aDebugInfo, EngineCallback aCallback, AD7Engine aEngine, IDebugPort2 aPort)
|
||||
{
|
||||
mCallback = aCallback;
|
||||
|
||||
// Load passed in values
|
||||
mDebugInfo = new NameValueCollection();
|
||||
NameValueCollectionHelper.LoadFromString(mDebugInfo, aDebugInfo);
|
||||
mDebugInfo = aDebugInfo;
|
||||
|
||||
//
|
||||
mISO = mDebugInfo["ISOFile"];
|
||||
mProjectFile = mDebugInfo["ProjectFile"];
|
||||
|
|
|
|||
|
|
@ -14,7 +14,7 @@
|
|||
<PropertyGroup Condition=" '$(Configuration)' == 'Debug' ">
|
||||
<DebugSymbols>true</DebugSymbols>
|
||||
<OutputPath>bin\Debug\</OutputPath>
|
||||
<BuildTarget>VMWare</BuildTarget>
|
||||
<BuildTarget>ISO</BuildTarget>
|
||||
<Framework>MicrosoftNET</Framework>
|
||||
<UseInternalAssembler>False</UseInternalAssembler>
|
||||
<DebugMode>Source</DebugMode>
|
||||
|
|
@ -47,7 +47,7 @@
|
|||
</None>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ProjectReference Include="..\BreakpointsKernel\BreakpointsKernel.csproj">
|
||||
<ProjectReference Include="..\Breakpoints\BreakpointsKernel.csproj">
|
||||
<Name>BreakpointsKernel</Name>
|
||||
<Project>{91cbd640-c07d-4556-b4cb-6f8cd88c67c9}</Project>
|
||||
<Private>True</Private>
|
||||
|
|
|
|||
|
|
@ -143,7 +143,7 @@ namespace Cosmos.VS.Package {
|
|||
private void comboTarget_SelectedIndexChanged(object sender, EventArgs e) {
|
||||
var xEnumValue = (EnumValue)comboTarget.SelectedItem;
|
||||
var xValue = (TargetHost)xEnumValue.Value;
|
||||
if (xValue != TargetHost.VMWare) {
|
||||
if (xValue != TargetHost.VMWare && xValue != TargetHost.ISO) {
|
||||
MessageBox.Show("This type is temporarily unsupported.");
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -18,6 +18,7 @@ namespace Cosmos.VS.Package.Templates.Wizards
|
|||
|
||||
public void ProjectItemFinishedGenerating(EnvDTE.ProjectItem projectItem)
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
public void RunFinished()
|
||||
|
|
|
|||
|
|
@ -28,6 +28,12 @@ namespace Cosmos.VS.Package
|
|||
{
|
||||
LogUtility.LogString("Entering Cosmos.VS.Package.VsProjectConfig.DebugLaunch({0})", aLaunch);
|
||||
try
|
||||
{
|
||||
if (String.Equals(this.GetConfigurationProperty("BuildTarget", true), "ISO", StringComparison.InvariantCultureIgnoreCase))
|
||||
{
|
||||
return VSConstants.S_OK;
|
||||
}
|
||||
else
|
||||
{
|
||||
// http://msdn.microsoft.com/en-us/library/microsoft.visualstudio.shell.interop.vsdebugtargetinfo_members.aspx
|
||||
var xInfo = new VsDebugTargetInfo();
|
||||
|
|
@ -70,6 +76,7 @@ namespace Cosmos.VS.Package
|
|||
LogUtility.LogString("Returning VSConstants.S_OK");
|
||||
return VSConstants.S_OK;
|
||||
}
|
||||
}
|
||||
catch (Exception e)
|
||||
{
|
||||
LogUtility.LogString("Error: " + e.ToString());
|
||||
|
|
|
|||
Loading…
Reference in a new issue