Debugging console project lazarus / 12-Debugger ---------------------------------------------------------------------- Anonymous · 2004-06-11 19:34 I need to debug a simple pascal (not delphi) project. I've configured the debugging option on my linux machine, but i don't know how add breakpoints, how add watches and how i can see output (function write) and how i can do input (function read). It's urgent, please. ---------------------------------------------------------------------- Marc · 2004-06-14 09:56 Breakpoints: 1) Configure a dbugger in debugger options 2) goto the line you want a breakpoint on, press F5 or klick the left margin of the editor. There is no console output window yet (it isn't fully implemented in the gdb-MI interface yet) Getting passing imput is not possible. Before this will happen, the debugger interface has to become more stable. The reason for this is that there is no separate stream to pass usr input to. Both your app as gdb receive the chars you type. So it might be a gdb command, or just user input. ---------------------------------------------------------------------- Anonymous · 2005-03-09 09:41 acutally, even I have set gdb & breakpoint, but why program will run not debug? Do i need more configuration, I remember I can do this on windows without any configuration. THANKS. ---------------------------------------------------------------------- Marc · 2005-03-09 10:10 enable debug info and don't use strip/upx/etc ---------------------------------------------------------------------- Anonymous · 2006-01-05 22:32 //Getting passing imput is not possible. Before this will happen, the debugger //interface has to become more stable. The reason for this is that there is no //separate stream to pass usr input to. Both your app as gdb receive the chars //you type. So it might be a gdb command, or just user input. Hi Marc I am also trying to debug a simple console application in Lazarus and Linux. I can do that successfully with everything but readln, readkey and other commands that read input from console. Did you say that It can't be done right now in Linux? I tried debugging with readln in Windows and it worked. If this is the case please tell me because I am searching everywhere to find the proper configurations! Thanks in advance! ---------------------------------------------------------------------- Marc · 2006-01-30 17:40 Console handling on windows and linux differ. On windows, the os creates a console window for you if the app is a console type. This means that even if you run a debugger you will get a console. On Linux you need to "create" your own console. for a console app, gdb is the console of this app. So on Linux there is only one stdin to write to (both your input and the input I send to gdb) At this moment I've no way of splitting them. Imaging you pass several chars and the app breaks after reading the first char, the other chars will get send to gdb.