Re: [Lazarus] disable the debugger capturing the OutputDebugString() messages

2010-07-21 Thread Bernd
The following program will silently terminate as soon as the debugserver is terminated while the program is still running. There are no exceptions or any other messages, it just silently exits back to the command prompt. I haven't yet tried with GDB to see where exactly this happens. IIRC when I tr

Re: [Lazarus] disable the debugger capturing the OutputDebugString() messages

2010-07-21 Thread Michael Van Canneyt
On Wed, 21 Jul 2010, Michael Schnell wrote: On 07/21/2010 04:36 PM, Howard Page-Clark wrote: On 21/7/10 1:16, Michael Schnell wrote: On 07/20/2010 03:28 PM, Michael Van Canneyt wrote: I suggest you look at the debugserver tool and the dbugintf units in FPC. Where to find the "dbugsrv exe

Re: [Lazarus] disable the debugger capturing the OutputDebugString() messages

2010-07-21 Thread Michael Schnell
On 07/21/2010 04:36 PM, Howard Page-Clark wrote: On 21/7/10 1:16, Michael Schnell wrote: On 07/20/2010 03:28 PM, Michael Van Canneyt wrote: I suggest you look at the debugserver tool and the dbugintf units in FPC. Where to find the "dbugsrv executable" ? lazarus\tools\debugserver\debugs

Re: [Lazarus] disable the debugger capturing the OutputDebugString() messages

2010-07-21 Thread Howard Page-Clark
On 21/7/10 1:16, Michael Schnell wrote: On 07/20/2010 03:28 PM, Michael Van Canneyt wrote: I suggest you look at the debugserver tool and the dbugintf units in FPC. Where to find the "dbugsrv executable" ? lazarus\tools\debugserver\debugserver.lpi Howard -- ___

Re: [Lazarus] disable the debugger capturing the OutputDebugString() messages

2010-07-21 Thread Michael Schnell
On 07/20/2010 03:28 PM, Michael Van Canneyt wrote: I suggest you look at the debugserver tool and the dbugintf units in FPC. Where to find the "dbugsrv executable" ? Thanks -Michael -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org

Re: [Lazarus] disable the debugger capturing the OutputDebugString() messages

2010-07-21 Thread Michael Van Canneyt
On Wed, 21 Jul 2010, Bernd wrote: Michael, If I have a patch for the debugserver can I send it directly to you (your name is in the source) or does it have to go directly to the bug tracker? You can send it to me. Michael. -- ___ Lazarus mailing

Re: [Lazarus] disable the debugger capturing the OutputDebugString() messages

2010-07-21 Thread Bernd
Michael, If I have a patch for the debugserver can I send it directly to you (your name is in the source) or does it have to go directly to the bug tracker? -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.

Re: [Lazarus] disable the debugger capturing the OutputDebugString() messages

2010-07-20 Thread Michael Van Canneyt
On Tue, 20 Jul 2010, Bernd wrote: 2010/7/20 Michael Van Canneyt : I suggest you look at the debugserver tool and the dbugintf units in FPC. Lazarus still keeps surprising me :-) Are there more such useful things that are still hiding from me deep down in some subdirectories I that I have n

Re: [Lazarus] disable the debugger capturing the OutputDebugString() messages

2010-07-20 Thread Bernd
2010/7/20 Michael Van Canneyt : > I suggest you look at the debugserver tool and the dbugintf units in FPC. Lazarus still keeps surprising me :-) Are there more such useful things that are still hiding from me deep down in some subdirectories I that I have never visited? My first impression was:

Re: [Lazarus] disable the debugger capturing the OutputDebugString() messages

2010-07-20 Thread Reimar Grabowski
On Tue, 20 Jul 2010 15:17:32 +0200 Bernd wrote: Thanks for the lengthy explanation, but if you had read my mail carefully, you would have seen that I never doubted that windows needs something like this with its crappy cmdln. I was just looking at the Linux side as my qoute should have made cle

Re: [Lazarus] disable the debugger capturing the OutputDebugString() messages

2010-07-20 Thread Michael Van Canneyt
On Tue, 20 Jul 2010, Bernd wrote: 2010/7/20 Mattias Gaertner : So please enlighten me. What are the benefits of such a debug monitor? Perhaps I am missing something. It would just be nice to have this all somehow unified and more *comfortably* usable in Lazarus. On windows I almost exclu

Re: [Lazarus] disable the debugger capturing the OutputDebugString() messages

2010-07-20 Thread Bernd
2010/7/20 Mattias Gaertner : >> So please enlighten me. What are the benefits of such a debug monitor? >> Perhaps I am missing something. Sometimes you simply don't have a stdout to write to. I just have one such occasion where I'm working on a plugin dll for another application on windows and I

Re: [Lazarus] disable the debugger capturing the OutputDebugString() messages

2010-07-20 Thread Reimar Grabowski
On Tue, 20 Jul 2010 14:15:54 +0200 Michael Schnell wrote: > I do miss (something like) this badly !. > > With MSEIDE you can see the standard output of a program ( writeln() ) > in a window, With Lazarus this is not available. That is not the same and actually a really useful feature I miss mys

Re: [Lazarus] disable the debugger capturing the OutputDebugString() messages

2010-07-20 Thread Reimar Grabowski
On Tue, 20 Jul 2010 14:30:22 +0200 Mattias Gaertner wrote: > Yes, Linux has pretty good terminal tools, Agreed. > it just would be more comfortable if they are integrated in the IDE. Waiting nearly 10 years for this. :) Every other Linux IDE I know has at least a terminal tab/window where stdout

Re: [Lazarus] disable the debugger capturing the OutputDebugString() messages

2010-07-20 Thread Mattias Gaertner
On Tue, 20 Jul 2010 14:14:12 +0200 Reimar Grabowski wrote: > On Tue, 20 Jul 2010 13:42:39 +0200 > Mattias Gaertner wrote: > > > Searching, filtering, highlighting and comparing with former runs. > Sounds good, but ... > The first and last work with simple text files, only little gain there. > F

Re: [Lazarus] disable the debugger capturing the OutputDebugString() messages

2010-07-20 Thread Michael Schnell
On 07/20/2010 01:38 PM, Reimar Grabowski wrote: Most likely because noone ever missed it. I do miss (something like) this badly !. With MSEIDE you can see the standard output of a program ( writeln() ) in a window, With Lazarus this is not available. I did not know about "OutputDebugStrin

Re: [Lazarus] disable the debugger capturing the OutputDebugString() messages

2010-07-20 Thread Reimar Grabowski
On Tue, 20 Jul 2010 13:42:39 +0200 Mattias Gaertner wrote: > Searching, filtering, highlighting and comparing with former runs. Sounds good, but ... The first and last work with simple text files, only little gain there. Filtering is valid and highlighting I don't understand. Are you talking abou

Re: [Lazarus] disable the debugger capturing the OutputDebugString() messages

2010-07-20 Thread Mattias Gaertner
On Tue, 20 Jul 2010 13:38:46 +0200 Reimar Grabowski wrote: > On Tue, 20 Jul 2010 11:47:22 +0200 > Bernd wrote: > > > We could even establish an open standard for such debug monitoring on > > linux because there doesn't seem to be one already. > > Most likely because noone ever missed it. But t

Re: [Lazarus] disable the debugger capturing the OutputDebugString() messages

2010-07-20 Thread Reimar Grabowski
On Tue, 20 Jul 2010 11:47:22 +0200 Bernd wrote: > We could even establish an open standard for such debug monitoring on > linux because there doesn't seem to be one already. Most likely because noone ever missed it. But this is just my personal opinion and I prefer using gdb directly and seldom

Re: [Lazarus] disable the debugger capturing the OutputDebugString() messages

2010-07-20 Thread Bernd
2010/7/20 Marc Weustink : > I hoped on a bit more recognizable MI output. > & messages are stdoutput, so the "warning: ..." could have been a writeln > too. Hmm... I cannot get it to show writelns in the debugger window. either they show up in the black console window that opens when i have comp

Re: [Lazarus] disable the debugger capturing the OutputDebugString() messages

2010-07-20 Thread Marc Weustink
Bernd wrote: 2010/7/19 Marc Weustink: If gdb doesn't give them to me, they wont get displayed. They show up in the debug messages as warnings. Making the debug message window able to show/hide all the different types of messages would probably already be enough. Here is an example. Try to find

Re: [Lazarus] disable the debugger capturing the OutputDebugString() messages

2010-07-19 Thread Bernd
http://imagebin.org/105806 -- ___ Lazarus mailing list Lazarus@lists.lazarus.freepascal.org http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus

Re: [Lazarus] disable the debugger capturing the OutputDebugString() messages

2010-07-19 Thread Bernd
2010/7/19 Marc Weustink : > If gdb doesn't give them to me, they wont get displayed. They show up in the debug messages as warnings. Making the debug message window able to show/hide all the different types of messages would probably already be enough. Here is an example. Try to find the line with

Re: [Lazarus] disable the debugger capturing the OutputDebugString() messages

2010-07-19 Thread Marc Weustink
Sven Barth wrote: Hi! Am 19.07.2010 17:02, schrieb Marc Weustink: AFAIK Delphi also has the possibility to display these messages conveniently in an IDE window. That's because Delphi contains its own debugger which catches the exceptions that are raised by OutputDebugString. In theory Lazar

Re: [Lazarus] disable the debugger capturing the OutputDebugString() messages

2010-07-19 Thread Sven Barth
Hi! Am 19.07.2010 17:02, schrieb Marc Weustink: AFAIK Delphi also has the possibility to display these messages conveniently in an IDE window. That's because Delphi contains its own debugger which catches the exceptions that are raised by OutputDebugString. In theory Lazarus can display them

Re: [Lazarus] disable the debugger capturing the OutputDebugString() messages

2010-07-19 Thread Marc Weustink
Sven Barth wrote: Hi! On 18.07.2010 14:52, Bernd wrote: 2010/7/18 Sven Barth: It basically does the following: 1) Raise an exception containing the message. OK, this seems to be the missing piece of the puzzle for understanding whats going on. I was basing all my theories only on this: http:

Re: [Lazarus] disable the debugger capturing the OutputDebugString() messages

2010-07-18 Thread Sven Barth
Hi! On 18.07.2010 19:52, Bernd wrote: 2010/7/18 Sven Barth: Hi again! I took the time to implement a OutputToDebugMonitor myself. It prints the message directly to e.g. DebugView even if a debugger like GDB is attached to the process. Wow! That was fast! I didn't even consider implementing t

Re: [Lazarus] disable the debugger capturing the OutputDebugString() messages

2010-07-18 Thread Bernd
2010/7/18 Sven Barth : > Hi again! > > I took the time to implement a OutputToDebugMonitor myself. It prints the > message directly to e.g. DebugView even if a debugger like GDB is attached > to the process. Wow! That was fast! I didn't even consider implementing this myself after looking at the c

Re: [Lazarus] disable the debugger capturing the OutputDebugString() messages

2010-07-18 Thread Sven Barth
Hi again! I took the time to implement a OutputToDebugMonitor myself. It prints the message directly to e.g. DebugView even if a debugger like GDB is attached to the process. The only problem with that code is the license... it's based on the GPL code from ReactOS so I don't know whether it

Re: [Lazarus] disable the debugger capturing the OutputDebugString() messages

2010-07-18 Thread Sven Barth
Hi! On 18.07.2010 14:52, Bernd wrote: 2010/7/18 Sven Barth: It basically does the following: 1) Raise an exception containing the message. OK, this seems to be the missing piece of the puzzle for understanding whats going on. I was basing all my theories only on this: http://unixwiz.net/techt

Re: [Lazarus] disable the debugger capturing the OutputDebugString() messages

2010-07-18 Thread Bernd
2010/7/18 Sven Barth : > It basically does the following: > 1) Raise an exception containing the message. OK, this seems to be the missing piece of the puzzle for understanding whats going on. I was basing all my theories only on this: http://unixwiz.net/techtips/outputdebugstring.html and there t

Re: [Lazarus] disable the debugger capturing the OutputDebugString() messages

2010-07-18 Thread Sven Barth
Hi again! On 18.07.2010 13:16, Bernd wrote: 2010/7/18 Sven Barth: GDB registers itself as a debugger with Windows for that application and thus Windows itself is routing all messages that are sent with OutputDebugString to that registered debugger. From what I have read about this mechanism

Re: [Lazarus] disable the debugger capturing the OutputDebugString() messages

2010-07-18 Thread Bernd
2010/7/18 Sven Barth : > and attaching DebugView to GDB DebugView is not attached to a specific application, it is simply acquiring a global windows resource that exists system-wide and only once and can be held by only one application at a time. It will then receive messages from windows and rea

Re: [Lazarus] disable the debugger capturing the OutputDebugString() messages

2010-07-18 Thread Bernd
2010/7/18 Sven Barth : > GDB registers itself as a debugger with Windows for that application and > thus Windows itself is routing all messages that are sent with > OutputDebugString to that registered debugger. >From what I have read about this mechanism it is not possible to register for these m

Re: [Lazarus] disable the debugger capturing the OutputDebugString() messages

2010-07-18 Thread Sven Barth
Hi! On 18.07.2010 12:53, Bernd wrote: It is absolutely not understandable why GDB captures these messages while it is completely unable to display them in any meaningful manner. It will capture the messages (it will replace and eat the whole function call, not only the message!) and then declare

Re: [Lazarus] disable the debugger capturing the OutputDebugString() messages

2010-07-18 Thread Bernd
2010/7/18 Marc Weustink : > OutputDebugString is meant to be captured by a debugger. Unfortunately this > isn't shown anyware in Lazarus Normally I use DebugView for that, its a little application that is extremely useful, I use the OutputDebugString() / DebugView combination for all kinds of deve

Re: [Lazarus] disable the debugger capturing the OutputDebugString() messages

2010-07-17 Thread Marc Weustink
Bernd wrote: Whenever I run a program through the debugger it will no longer allow my debug messages that I send to the windows API function OutputDebugString() to go where they are normally supposed to go (an external application that logs them). Somehow the debugger seems to entirely catch thes

[Lazarus] disable the debugger capturing the OutputDebugString() messages

2010-07-17 Thread Bernd
Whenever I run a program through the debugger it will no longer allow my debug messages that I send to the windows API function OutputDebugString() to go where they are normally supposed to go (an external application that logs them). Somehow the debugger seems to entirely catch these debug message