[Lazarus] gdb debug server class

Martin Frb lazarus at mfriebe.de
Mon Jul 7 12:23:51 CEST 2014


On 07/07/2014 11:08, Justin Smyth wrote:
>
> Hi folks ,
>
> I'm trying to make a copy of GDBMiServerDebugger, to allow some extra 
> gdb commands to be saved and  parsed.
>
> In the list of properties I want to add a list of strings to save, ie 
> ( assuming i have changed the name of the class , I am just  copying 
> out of the original
>
> I want to store 3 or 4 extra commands I want gdb to run when It 
> executes my arm file via open ocd gdb.
>
> TGDBMIServerDebuggerProperties = class(TGDBMIDebuggerPropertiesBase)
>
>   private
>
>     FDebugger_Remote_Hostname: string;
>
>     FDebugger_Remote_Port: string;
>
> -à FDebugger_Custom_List:TStringList ß
>
>   public
>
> is this possible ? if I do this I need to add FDebugger_Custom_List = 
> TStringList.create; into the constructor listed below
>
> constructor TGDBMIServerDebuggerProperties.Create;
>

Yes, the object needs to be present, so it can be used in the OI.

You probably also need a setter for the propert

procedure SetDebugger_Custom_List( New:TStringList );
    FDebugger_Custom_List.assign(New);


and a destructor to free it.Do not forget to add all of your fields to 
the ASSIGN method too.

And last note, I have not looked at how this is stringified when saved. 
So I do not know if it works with TStrings (it should...)
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.lazarus-ide.org/pipermail/lazarus/attachments/20140707/d47b23fe/attachment-0003.html>


More information about the Lazarus mailing list