[fpc-pascal] SQLdb: problem using GDB, but do not have memleak

Sven Barth pascaldragon at googlemail.com
Wed Mar 21 09:32:58 CET 2012

Am 20.03.2012 18:03, schrieb Marcos Douglas:
> On Tue, Mar 20, 2012 at 12:35 PM, Jonas Maebe<jonas.maebe at elis.ugent.be>  wrote:
>> On 20 Mar 2012, at 14:06, Marcos Douglas wrote:
>> I compile FPC using these options: UPXPROG=echo COPYTREE=echo OPT="-gl"
>> You should use OPT="-O- -gl" if you want to debug standard FPC units. The
>> default for building the entire FPC source tree is -O2. Optimizations
>> generally have little effect on the line number information though.
> Before I used OPT="-gl" and I already debug FPC units.
> I recompiled using OPT="-gl -gw2 -godwarfsets"  after read this link:
> wiki.lazarus.freepascal.org/GDB_Debugger_Tips
> The OPT="-O- -gl" options are better?

You should at least add the "-O-" to your OPT argument, because this way 
the optimizations are switched off which might(!) cause your debug problems.


More information about the fpc-pascal mailing list