Browse Source

* force gdb/mi on windows to always run the debuggee in another console, since I
couldn't get same console debugging to work with gdb/mi on windows (and I
doubt it's even possible with the current gdb, without patching it)

git-svn-id: trunk@30100 -

nickysn 10 năm trước cách đây
mục cha
commit
e76b416b04
4 tập tin đã thay đổi với 12 bổ sung0 xóa
  1. 4 0
      ide/fpini.pas
  2. 3 0
      ide/fpmopts.inc
  3. 4 0
      ide/fpvars.pas
  4. 1 0
      ide/globdir.inc

+ 4 - 0
ide/fpini.pas

@@ -431,7 +431,9 @@ begin
   { First read the primary file, which can also set the parameters which can
     be overruled with the parameter loading }
   SetPrimaryFile(INIFile^.GetEntry(secCompile,iePrimaryFile,PrimaryFile));
+{$ifndef GDB_WINDOWS_ALWAYS_USE_ANOTHER_CONSOLE}
   DebuggeeTTY := INIFile^.GetEntry(secRun,ieDebuggeeRedir,DebuggeeTTY);
+{$endif not GDB_WINDOWS_ALWAYS_USE_ANOTHER_CONSOLE}
 {$ifdef SUPPORT_REMOTE}
   RemoteMachine :=INIFile^.GetEntry(secRun,ieRemoteMachine,RemoteMachine);
   RemotePort :=INIFile^.GetEntry(secRun,ieRemotePort,RemotePort);
@@ -653,8 +655,10 @@ begin
   INIFile^.SetEntry(secRun,ieRunDir,GetRunDir);
   INIFile^.SetEntry(secRun,ieRunParameters,GetRunParameters);
   INIFile^.SetEntry(secFiles,iePrinterDevice,GetPrinterDevice);
+{$ifndef GDB_WINDOWS_ALWAYS_USE_ANOTHER_CONSOLE}
   { If DebuggeeTTY<>'' then }
     INIFile^.SetEntry(secRun,ieDebuggeeRedir,DebuggeeTTY);
+{$endif not GDB_WINDOWS_ALWAYS_USE_ANOTHER_CONSOLE}
 {$ifdef SUPPORT_REMOTE}
     INIFile^.SetEntry(secRun,ieRemoteMachine,RemoteMachine);
     INIFile^.SetEntry(secRun,ieRemotePort,RemotePort);

+ 3 - 0
ide/fpmopts.inc

@@ -547,6 +547,9 @@ begin
     else
       L:=0;
     CB2^.SetData(L);
+{$ifdef GDB_WINDOWS_ALWAYS_USE_ANOTHER_CONSOLE}
+    CB2^.EnableMask := CB2^.EnableMask and $fffffffe;
+{$endif GDB_WINDOWS_ALWAYS_USE_ANOTHER_CONSOLE}
     R2.Move(0,-1);
     Insert(New(PLabel, Init(R2,label_debugger_redirection, CB2)));
 {$endif Windows}

+ 4 - 0
ide/fpvars.pas

@@ -145,7 +145,11 @@ const ClipboardWindow  : PClipboardWindow = nil;
        '"$REMOTEEXECCOMMAND" $DOITINBACKGROUND';
 {$endif SUPPORT_REMOTE}
 
+{$ifdef GDB_WINDOWS_ALWAYS_USE_ANOTHER_CONSOLE}
+     DebuggeeTTY : string = 'on';
+{$else GDB_WINDOWS_ALWAYS_USE_ANOTHER_CONSOLE}
      DebuggeeTTY : string = '';
+{$endif GDB_WINDOWS_ALWAYS_USE_ANOTHER_CONSOLE}
 
       ActionCommands   : array[acFirstAction..acLastAction] of word =
         (cmHelpTopicSearch,cmGotoCursor,cmToggleBreakpoint,

+ 1 - 0
ide/globdir.inc

@@ -217,4 +217,5 @@
   {$ifdef DEBUG}
     {$define GDB_RAW_OUTPUT}
   {$endif DEBUG}
+  {$define GDB_WINDOWS_ALWAYS_USE_ANOTHER_CONSOLE}
 {$endif GDBMI}