Re: [Lazarus] Lazarus ignores my breakpoints

2009-05-05 Thread Graeme Geldenhuys
On Tue, May 5, 2009 at 1:06 PM, Graeme Geldenhuys
graemeg.li...@gmail.com wrote:
 Hi,

 Why is Lazarus ignoring my breakpoint?  If I put a writeln() statement
 before line 1466, it is executed and I see console output. So that

I place the following writeln() statement before line 1466 and below
is some sample output, showing the writeln() is being run.


   writeln('**');


==[ console output ]
/home/graemeg/programming/tiOPF2/UnitTests/Text/textrunner -p
--suite=TtiObjectTestCase

TtiObjectTestCase:
Owner: ...  DONE
Parent_InheritsFromVsIs: ...  DONE
Parent_TtiObject: ...  DONE
Parent_TtiObjectList: ...  DONE
OIDGenerator: ...  DONE
GetOID: ...  DONE
PropType: ...  DONE
IsReadWriteProp: ...  DONE
PropCount: ...  DONE
SetPropValue: ...  DONE
SetBooleanPropValue: ...**
  ERROR
GetPropValue: ...  DONE
SetPropValueNested: ...  DONE
GetPropValueNested: ...  DONE
Deleted_TtiObject: ...  DONE
..
===


Regards,
  - Graeme -


___
fpGUI - a cross-platform Free Pascal GUI toolkit
http://opensoft.homeip.net/fpgui/

___
Lazarus mailing list
Lazarus@lazarus.freepascal.org
http://www.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] Lazarus ignores my breakpoints

2009-05-05 Thread Vincent Snijders
Graeme Geldenhuys schreef:
 Hi,
 
 Why is Lazarus ignoring my breakpoint?  If I put a writeln() statement
 before line 1466, it is executed and I see console output. So that
 code is definitely being run. Yet Lazarus think it isn't and simply
 ignores the breakpoint - for no reason.  See attached screenshot.
 

The color of the breakpoint seems to indicate there is no line info for 
that unit. Can you attach the debug output (maybe zipped) (View - Debug 
Windows - Debug Output).

Vincent
___
Lazarus mailing list
Lazarus@lazarus.freepascal.org
http://www.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] Lazarus ignores my breakpoints

2009-05-05 Thread Martin Friebe
Graeme Geldenhuys wrote:
 On Tue, May 5, 2009 at 1:06 PM, Graeme Geldenhuys
 graemeg.li...@gmail.com wrote:
   
 Hi,

 Why is Lazarus ignoring my breakpoint?  If I put a writeln() statement
 before line 1466, it is executed and I see console output. So that
 

 I place the following writeln() statement before line 1466 and below
 is some sample output, showing the writeln() is being run.
   
While it is not the answer to your question, I had a similar issue and 
found, that breakpoints only worked, if they here set *before* I started 
the application to debug. (This was on FreeBSD)

Maybe worth trying until the issue is fixed?

Martin


writeln('**');


 ==[ console output ]
 /home/graemeg/programming/tiOPF2/UnitTests/Text/textrunner -p
 --suite=TtiObjectTestCase

 TtiObjectTestCase:
 Owner: ...  DONE
 Parent_InheritsFromVsIs: ...  DONE
 Parent_TtiObject: ...  DONE
 Parent_TtiObjectList: ...  DONE
 OIDGenerator: ...  DONE
 GetOID: ...  DONE
 PropType: ...  DONE
 IsReadWriteProp: ...  DONE
 PropCount: ...  DONE
 SetPropValue: ...  DONE
 SetBooleanPropValue: ...**
   ERROR
 GetPropValue: ...  DONE
 SetPropValueNested: ...  DONE
 GetPropValueNested: ...  DONE
 Deleted_TtiObject: ...  DONE
 ..
 ===


 Regards,
   - Graeme -


 ___
 fpGUI - a cross-platform Free Pascal GUI toolkit
 http://opensoft.homeip.net/fpgui/

 ___
 Lazarus mailing list
 Lazarus@lazarus.freepascal.org
 http://www.lazarus.freepascal.org/mailman/listinfo/lazarus
   
___
Lazarus mailing list
Lazarus@lazarus.freepascal.org
http://www.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] Lazarus ignores my breakpoints

2009-05-05 Thread Graeme Geldenhuys
On Tue, May 5, 2009 at 1:33 PM, Martin Friebe laza...@mfriebe.de wrote:

 While it is not the answer to your question, I had a similar issue and
 found, that breakpoints only worked, if they here set *before* I started
 the application to debug. (This was on FreeBSD)

This is what I have done. Set the breakpoints, then run the
application through the IDE. The IDE then outputs to the debug xterm
console.


Regards,
  - Graeme -


___
fpGUI - a cross-platform Free Pascal GUI toolkit
http://opensoft.homeip.net/fpgui/
___
Lazarus mailing list
Lazarus@lazarus.freepascal.org
http://www.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] Lazarus ignores my breakpoints

2009-05-05 Thread Graeme Geldenhuys
On Tue, May 5, 2009 at 1:31 PM, Vincent Snijders
vincent.snijd...@gmail.com wrote:

 The color of the breakpoint seems to indicate there is no line info for

With my color scheme in says:  invalid breakpoint

 that unit. Can you attach the debug output (maybe zipped) (View - Debug
 Windows - Debug Output).

Umm, another new window I didn't know about. :-)

The output has been attached as an archive.  The most interesting bit
is probably the last few lines which looks like this. I guess that is
the problem - though I have no clue how to fix it.


===
(gdb)

-symbol-list-lines
/home/graemeg/programming/3rdParty/tiOPF2/Source/UnitTests/Tests/tiObject_TST.pas
mi_cmd_symbol_list_lines: Unknown source file name.\n

^error,msg=mi_cmd_symbol_list_lines: Unknown source file name.

(gdb)

-symbol-list-lines tiObject_TST.pas
mi_cmd_symbol_list_lines: Unknown source file name.\n

^error,msg=mi_cmd_symbol_list_lines: Unknown source file name.

(gdb)

===


And for completeness, below is when FPC compiler parameters that
Lazarus IDE generates:

===
 -MObjFPC -O1 -gl -vewnhi -l -Fi../../Core/ -Fu../Common/ -Fu../Tests/
-Fu../../Compilers/FPC/lib/i386-linux/
-Fu../../../../../../../../opt/lazarus/packager/units/i386-linux/ -Fu.
-vm5024 -otextrunner -FU_Dcu

or without relative paths

 -MObjFPC -O1 -gl -vewnhi -l
-Fi/home/graemeg/programming/3rdParty/tiOPF2/Source/Core/
-Fi/home/graemeg/programming/3rdParty/tiOPF2/Source/UnitTests/Text/
-Fu/home/graemeg/programming/3rdParty/tiOPF2/Source/UnitTests/Common/
-Fu/home/graemeg/programming/3rdParty/tiOPF2/Source/UnitTests/Tests/
-Fu/home/graemeg/programming/3rdParty/tiOPF2/Source/Compilers/FPC/lib/i386-linux/
-Fu/opt/lazarus/packager/units/i386-linux/
-Fu/home/graemeg/programming/3rdParty/tiOPF2/Source/UnitTests/Text/
-Fu. -vm5024 -FE/home/graemeg/programming/3rdParty/tiOPF2/Source/UnitTests/Text/
-otextrunner -FU_Dcu
===


And here is the directory layout as it is on my system.
===
$ tree.sh

/home/graemeg/programming/3rdParty/tiOPF2/Source
   .
   |-Compilers
   |---FPC
   |-lib
   |---i386-linux
   |-Core
   |-GUI
   |---LCL
   |---VCL
   |-Options
   |-UnitTests
   |---Common
   |---_Data
   |---GUI
   |-_Dcu
   |-Log
   |---Tests = unit tests and unit I want to set breakpoint in
   |---Text   = Program executable and source code
   |-_Dcu   = compiled units go here

===


Hope this helps!


Regards,
  - Graeme -


___
fpGUI - a cross-platform Free Pascal GUI toolkit
http://opensoft.homeip.net/fpgui/


debug_output.txt.tar.gz
Description: GNU Zip compressed data
___
Lazarus mailing list
Lazarus@lazarus.freepascal.org
http://www.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] Lazarus ignores my breakpoints

2009-05-05 Thread Marc Weustink
Graeme Geldenhuys wrote:
 On Tue, May 5, 2009 at 1:33 PM, Martin Friebe laza...@mfriebe.de wrote:
 While it is not the answer to your question, I had a similar issue and
 found, that breakpoints only worked, if they here set *before* I started
 the application to debug. (This was on FreeBSD)
 
 This is what I have done. Set the breakpoints, then run the
 application through the IDE. The IDE then outputs to the debug xterm
 console.

You cannot debug console apps with lazarus. If you use an xterm as 
launching to see your console output, then gdb will debug the xterm and 
not your app. There is some patch to have a separate console, but I 
haven't reseached it yet.

Marc

___
Lazarus mailing list
Lazarus@lazarus.freepascal.org
http://www.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] Lazarus ignores my breakpoints

2009-05-05 Thread Graeme Geldenhuys
On Tue, May 5, 2009 at 2:28 PM, Marc Weustink wrote:

 You cannot debug console apps with lazarus. If you use an xterm as
 launching to see your console output, then gdb will debug the xterm and
 not your app.

Ah, that was it!!  I switched to using the LCL based GUI version of
the test suite and my breakpoint was working.  Thanks for spotting the
problem.  :-)


Regards,
  - Graeme -


___
fpGUI - a cross-platform Free Pascal GUI toolkit
http://opensoft.homeip.net/fpgui/
___
Lazarus mailing list
Lazarus@lazarus.freepascal.org
http://www.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] Lazarus ignores my breakpoints

2009-05-05 Thread Leonardo M. Ramé
Don't tested but, what about adding an Sleep at the start of the console 
app, then attach lazarus to your console process?.

Leonardo M. Ramé
Griensu S.A. - Medical IT Córdoba
Tel.: 0351 - 4247979




Graeme Geldenhuys escribió:
 On Tue, May 5, 2009 at 2:28 PM, Marc Weustink wrote:
   
 You cannot debug console apps with lazarus. If you use an xterm as
 launching to see your console output, then gdb will debug the xterm and
 not your app.
 

 Ah, that was it!!  I switched to using the LCL based GUI version of
 the test suite and my breakpoint was working.  Thanks for spotting the
 problem.  :-)


 Regards,
   - Graeme -


 ___
 fpGUI - a cross-platform Free Pascal GUI toolkit
 http://opensoft.homeip.net/fpgui/
 ___
 Lazarus mailing list
 Lazarus@lazarus.freepascal.org
 http://www.lazarus.freepascal.org/mailman/listinfo/lazarus

   
___
Lazarus mailing list
Lazarus@lazarus.freepascal.org
http://www.lazarus.freepascal.org/mailman/listinfo/lazarus


Re: [Lazarus] Lazarus ignores my breakpoints

2009-05-05 Thread Vincent Snijders
Graeme Geldenhuys schreef:
 On Tue, May 5, 2009 at 2:28 PM, Marc Weustink wrote:
 You cannot debug console apps with lazarus. If you use an xterm as
 launching to see your console output, then gdb will debug the xterm and
 not your app.
 
 Ah, that was it!!  I switched to using the LCL based GUI version of
 the test suite and my breakpoint was working.  Thanks for spotting the
 problem.  :-)

FWIW, on windows there is no such problem, but I doubt that it incentive 
enough for you to reboot into windows.

Vincent
___
Lazarus mailing list
Lazarus@lazarus.freepascal.org
http://www.lazarus.freepascal.org/mailman/listinfo/lazarus