gdbcon.pas 2.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160
  1. {
  2. Fake GDBCon unit (including base from GDBInt)
  3. **********************************************************************}
  4. unit GDBCon;
  5. interface
  6. uses
  7. GdbInt;
  8. type
  9. PGDBController=^TGDBController;
  10. TGDBController=object(TGDBInterface)
  11. progname : pchar;
  12. progargs : pchar;
  13. in_command,
  14. init_count : longint;
  15. constructor Init;
  16. destructor Done;
  17. procedure CommandBegin(const s:string);virtual;
  18. procedure Command(const s:string);
  19. procedure CommandEnd(const s:string);virtual;
  20. procedure Reset;virtual;
  21. procedure StartTrace;
  22. procedure Run;virtual;
  23. procedure TraceStep;virtual;
  24. procedure TraceNext;virtual;
  25. procedure TraceStepI;virtual;
  26. procedure TraceNextI;virtual;
  27. procedure Continue;virtual;
  28. { needed for dos because newlines are only #10 (PM) }
  29. procedure WriteErrorBuf;
  30. procedure WriteOutputBuf;
  31. function GetOutput : Pchar;
  32. function GetError : Pchar;
  33. function LoadFile(const fn:string):boolean;
  34. procedure SetArgs(const s : string);
  35. procedure ClearSymbols;
  36. end;
  37. { gdb does not allow \ in dir or filenames }
  38. procedure UnixDir(var s : string);
  39. implementation
  40. procedure UnixDir(var s : string);
  41. var i : longint;
  42. begin
  43. for i:=1 to length(s) do
  44. if s[i]='\' then s[i]:='/';
  45. end;
  46. constructor TGDBController.Init;
  47. begin
  48. inherited Init;
  49. end;
  50. destructor TGDBController.Done;
  51. begin
  52. inherited Done;
  53. end;
  54. procedure TGDBController.Command(const s:string);
  55. begin
  56. end;
  57. procedure TGDBController.CommandBegin(const s:string);
  58. begin
  59. end;
  60. procedure TGDBController.CommandEnd(const s:string);
  61. begin
  62. end;
  63. procedure TGDBController.Reset;
  64. begin
  65. end;
  66. function TGDBController.LoadFile(const fn:string):boolean;
  67. begin
  68. LoadFile:=true;
  69. end;
  70. procedure TGDBController.SetArgs(const s : string);
  71. begin
  72. end;
  73. procedure TGDBController.StartTrace;
  74. begin
  75. Run;
  76. end;
  77. procedure TGDBController.Run;
  78. begin
  79. end;
  80. procedure TGDBController.TraceStep;
  81. begin
  82. end;
  83. procedure TGDBController.TraceNext;
  84. begin
  85. end;
  86. procedure TGDBController.TraceStepI;
  87. begin
  88. end;
  89. procedure TGDBController.TraceNextI;
  90. begin
  91. end;
  92. procedure TGDBController.Continue;
  93. begin
  94. end;
  95. procedure TGDBController.ClearSymbols;
  96. begin
  97. end;
  98. procedure TGDBController.WriteErrorBuf;
  99. begin
  100. end;
  101. procedure TGDBController.WriteOutputBuf;
  102. begin
  103. end;
  104. function TGDBController.GetOutput : Pchar;
  105. begin
  106. GetOutput:=nil;
  107. end;
  108. function TGDBController.GetError : Pchar;
  109. begin
  110. GetError:=nil;
  111. end;
  112. end.