Recent

Author Topic: Debugger Error  (Read 198 times)

Jimmy Camel

  • Newbie
  • Posts: 3
Debugger Error
« on: November 21, 2020, 07:03:09 pm »
Whenever I try to run a GUI program using the Launching application option in Run Parameters I get this error message


Debugger error

Oooops, the debugger entered the error state
Save your work now !

etc



And when I click the more button for extra info this is what the text box contents

The GDB command:
"info address main"
returned the error:
",msg="No symbol \"main\" in current context.""


 PLEASE HELP!))))



Martin_fr

  • Administrator
  • Hero Member
  • *
  • Posts: 6707
  • Debugger - SynEdit - and more
    • wiki
Re: Debugger Error
« Reply #1 on: November 21, 2020, 07:24:15 pm »
Check your setup. https://wiki.lazarus.freepascal.org/Debugger_Setup

Have you enabled debug info?

Jimmy Camel

  • Newbie
  • Posts: 3
Re: Debugger Error
« Reply #2 on: November 21, 2020, 07:45:04 pm »
Already did it, i'm on linux OS , and did all cases which found on this forum

Martin_fr

  • Administrator
  • Hero Member
  • *
  • Posts: 6707
  • Debugger - SynEdit - and more
    • wiki
Re: Debugger Error
« Reply #3 on: November 21, 2020, 07:53:43 pm »
What kind of app are you running?

Graphical (with forms)?
Console?
library project?

Note: Using a "launching app" (e.g. a bash/shell/console) via "run parameters" may not work.
Linux, Console apps => menu: view > debug windows > console output

What version of Lazarus?

Jimmy Camel

  • Newbie
  • Posts: 3
Re: Debugger Error
« Reply #4 on: November 21, 2020, 09:01:42 pm »
Version Lazarus - 2.0.10 (latest on today)
Running Console App
Using green button for start App)
 I don't now what the problem real

https://forum.lazarus.freepascal.org/index.php?topic=34922.0
Did all what in this post, but keep this error

May be in linking need some instructions write ? But i don't know what is this and how do it)

The GDB command:
"info address main"
returned the error:
",msg="No symbol \"main\" in current context.""
« Last Edit: November 21, 2020, 09:05:00 pm by Jimmy Camel »

Martin_fr

  • Administrator
  • Hero Member
  • *
  • Posts: 6707
  • Debugger - SynEdit - and more
    • wiki
Re: Debugger Error
« Reply #5 on: November 21, 2020, 10:25:18 pm »
Does it work, if you switch off "use launching application"?

The problem is, that "launching app" does no longer work on any linux that I know. "gnome-terminal" (and any other terminal that I am aware off) have changed. 10 years ago, they could be used inside the debugger (as launcher). Nowadays, afaik not.

If you do normal readln/writeln then the you can switch it off, and use the "console output" window from menu "view > Debug windows" (this also allows input to the app).

If you use control sequences (clear screen, move cursor, color, ....) then it is a problem.
There are some work-arounds: https://wiki.lazarus.freepascal.org/Debugger_Console_App#Redirect_input_and_output_to_a_pty_.28terminal.29


 

TinyPortal © 2005-2018