gdbcon.pas 2.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165
  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 SetDir(const s : string);
  35. procedure SetArgs(const s : string);
  36. procedure ClearSymbols;
  37. end;
  38. { gdb does not allow \ in dir or filenames }
  39. procedure UnixDir(var s : string);
  40. implementation
  41. procedure UnixDir(var s : string);
  42. var i : longint;
  43. begin
  44. for i:=1 to length(s) do
  45. if s[i]='\' then s[i]:='/';
  46. end;
  47. constructor TGDBController.Init;
  48. begin
  49. inherited Init;
  50. end;
  51. destructor TGDBController.Done;
  52. begin
  53. inherited Done;
  54. end;
  55. procedure TGDBController.Command(const s:string);
  56. begin
  57. end;
  58. procedure TGDBController.CommandBegin(const s:string);
  59. begin
  60. end;
  61. procedure TGDBController.CommandEnd(const s:string);
  62. begin
  63. end;
  64. procedure TGDBController.Reset;
  65. begin
  66. end;
  67. function TGDBController.LoadFile(const fn:string):boolean;
  68. begin
  69. LoadFile:=true;
  70. end;
  71. procedure TGDBController.SetArgs(const s : string);
  72. begin
  73. end;
  74. procedure TGDBController.SetDir(const s : string);
  75. begin
  76. end;
  77. procedure TGDBController.StartTrace;
  78. begin
  79. Run;
  80. end;
  81. procedure TGDBController.Run;
  82. begin
  83. end;
  84. procedure TGDBController.TraceStep;
  85. begin
  86. end;
  87. procedure TGDBController.TraceNext;
  88. begin
  89. end;
  90. procedure TGDBController.TraceStepI;
  91. begin
  92. end;
  93. procedure TGDBController.TraceNextI;
  94. begin
  95. end;
  96. procedure TGDBController.Continue;
  97. begin
  98. end;
  99. procedure TGDBController.ClearSymbols;
  100. begin
  101. end;
  102. procedure TGDBController.WriteErrorBuf;
  103. begin
  104. end;
  105. procedure TGDBController.WriteOutputBuf;
  106. begin
  107. end;
  108. function TGDBController.GetOutput : Pchar;
  109. begin
  110. GetOutput:=nil;
  111. end;
  112. function TGDBController.GetError : Pchar;
  113. begin
  114. GetError:=nil;
  115. end;
  116. end.