mirror of
https://github.com/danbulant/Cosmos
synced 2026-05-19 20:39:01 +00:00
Limitations :
- Bochs must be installed on the system. This is not checked as a prerequisite by the Builder.
- You will find a GuessForBochs Cosmos project under BlueSkeye user project folder that can be used to launch the Guess project under Bochs.
- You may have to fix manually the path for the following properties in Cosmos.bxrc file copied to the CosmosForBochs\Bin\Debug folder
* romimage
* vgaromimage
- The Cosmos project UI is not yet Bochs aware. If you do not use the GuessForBochs project you must manually edit your Cosmos project file to modify the following property in both the Debug and Release property group from the project file :
<Launch>Bochs</Launch>
You must also add the following properties in both the Debug and Release property group from the project file :
<BochsConfig>Cosmos.bxrc</BochsConfig>
<Bochs_Deployment>ISO</Bochs_Deployment>
<Bochs_Launch>Bochs</Bochs_Launch>
<Bochs_DebugEnabled>True</Bochs_DebugEnabled>
<Bochs_DebugMode>Source</Bochs_DebugMode>
<Bochs_IgnoreDebugStubAttribute />
<Bochs_VMwareEdition>Player</Bochs_VMwareEdition>
<Bochs_OutputPath>bin\Debug\</Bochs_OutputPath>
<Bochs_Framework>MicrosoftNET</Bochs_Framework>
<Bochs_UseInternalAssembler>False</Bochs_UseInternalAssembler>
<Bochs_TraceAssemblies />
<Bochs_EnableGDB>False</Bochs_EnableGDB>
<Bochs_StartCosmosGDB>false</Bochs_StartCosmosGDB>
<Bochs_Name>GuessForBochs</Bochs_Name>
<Bochs_Description>Use Bochs emulator to deploy and debug.</Bochs_Description>
<Bochs_VisualStudioDebugPort>Pipe: Cosmos\Serial</Bochs_VisualStudioDebugPort>
<Bochs_PxeInterface>192.168.43.1</Bochs_PxeInterface>
<Bochs_SlavePort>Serial: COM3</Bochs_SlavePort>
<Bochs_ShowLaunchConsole>False</Bochs_ShowLaunchConsole>
82 lines
2.2 KiB
C#
82 lines
2.2 KiB
C#
using System;
|
|
using System.Collections.Generic;
|
|
using System.Linq;
|
|
using System.Text;
|
|
using System.Reflection;
|
|
|
|
namespace Cosmos.Build.Common {
|
|
|
|
public enum DeploymentType {
|
|
[Description("ISO Image")]
|
|
ISO,
|
|
[Description("USB Device")]
|
|
USB,
|
|
[Description("PXE Network Boot")]
|
|
PXE
|
|
}
|
|
|
|
public enum LaunchType {
|
|
[Description("None")]
|
|
None,
|
|
[Description("VMware")]
|
|
VMware,
|
|
[Description("Attached Slave (CanaKit)")]
|
|
Slave,
|
|
[Description("Bochs")]
|
|
Bochs
|
|
}
|
|
|
|
public enum VMwareEdition {
|
|
Workstation,
|
|
Player
|
|
}
|
|
|
|
public enum Architecture {
|
|
x86 //, x64
|
|
}
|
|
|
|
public enum Framework {
|
|
[Description("Microsoft .NET")]
|
|
MicrosoftNET,
|
|
Mono
|
|
}
|
|
|
|
public enum LogSeverityEnum : byte {
|
|
Warning = 0, Error = 1, Informational = 2, Performance = 3
|
|
}
|
|
public enum TraceAssemblies { All, Cosmos, User };
|
|
public enum DebugMode { IL, Source }
|
|
|
|
public sealed class DescriptionAttribute : Attribute {
|
|
public static String GetDescription(object value) {
|
|
Type valueType = value.GetType();
|
|
MemberInfo[] valueMemberInfo;
|
|
Object[] valueMemberAttribute;
|
|
|
|
if (valueType.IsEnum) {
|
|
valueMemberInfo = valueType.GetMember(value.ToString());
|
|
|
|
if ((valueMemberInfo != null) && (valueMemberInfo.Length > 0)) {
|
|
valueMemberAttribute = valueMemberInfo[0].GetCustomAttributes(typeof(DescriptionAttribute), false);
|
|
if ((valueMemberAttribute != null) && (valueMemberAttribute.Length > 0)) {
|
|
return ((DescriptionAttribute)valueMemberAttribute[0]).Description;
|
|
}
|
|
}
|
|
}
|
|
|
|
valueMemberAttribute = valueType.GetCustomAttributes(typeof(DescriptionAttribute), false);
|
|
if ((valueMemberAttribute != null) && (valueMemberAttribute.Length > 0)) {
|
|
return ((DescriptionAttribute)valueMemberAttribute[0]).Description;
|
|
}
|
|
|
|
return value.ToString();
|
|
}
|
|
|
|
private string emDescription;
|
|
public DescriptionAttribute(String description) {
|
|
emDescription = description;
|
|
}
|
|
|
|
public String Description { get { return emDescription; } }
|
|
}
|
|
}
|