-
Notifications
You must be signed in to change notification settings - Fork 15
/
DEBUG.TXT
42 lines (34 loc) · 1.53 KB
/
DEBUG.TXT
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
MSEide debugging
****************
Breakpoints don't work on win32 in units compiled with -CX
(create smartlinked units). It is recommended to use mingw gdb 6.8+ on win32.
String and dynamic array variables of units compiled with
-gv (Valgrind debug info) are displayed incorrect.
gdb 6.5 has bugs with threads and forking on linux. Please update to gdb 6.6+.
FPC 2.2+ projects must be compiled with -O- (no optimization) for debugging.
Tips from IvankoB:
------------------
In win-32, when debugging MSEide as a slave project run within master
MSEide, there're possible
uncontrollable breakpoints on pressing the F12 key (in MSEide, this key
toggles design/code view
for form, datamodules and reports). These breakpoints are caused by the
win-32 internal debug
facilities activated by the F12 key too. To release this key for MSEide,
there's a solution:
- run the REGEDIT.exe
- set
"HKLM\SOFTWARE\Microsoft\WindowsNT\CurrentVersion\AeDebug\UserDebuggerHotKey"
to 0x2F
(it's the scancode of VK_HELP which is not present on most PC keyboards )
- reboot
In win-32, WRITELN called from within a program won't be printed in the IDE
internal console (because of some STDIO flushing issues on pipes)
unless the below code is inserted at beginning of the startup file
of the program:
{$ifdef mswindows}
TextRec(Output).FlushFunc:= TextRec(Output).InOutFunc;
{$endif}
Also, You should place {$apptype console} compiler directive at beginning
of each unit calling WRITELN otherwise You may either encounter "File not
found" exception or to see silent nothing.