On Sat, 1 Jun 2013, Ludo Brands wrote:

On 06/01/2013 10:34 AM, Michael Van Canneyt wrote:

Hello,

I am using the latest lazarus, and I start getting the error:

Cannot find new threads: generic error

Looking for this message on internet I find that I can specify to gdb
which threading library to use, using a command similar to

set env LD_PRELOAD /lib/x86_64-linux-gnu/libpthread.so.0

(the exact value depends on the system you use)

I put this in my .gdbinit, so it would be used always, but now I find that
this file is not being read because Lazarus specifies -nx to gdb.

How can I solve this ?

Quite a bummer if you can't debug during a FPC hackathon :(

Michael.


in tools/debugger/general enter

-ex "set env LD_PRELOAD /lib/x86_64-linux-gnu/libpthread.so.0 "

That does the trick!

I also found it works correctly if I add {$linklib pthread} to the program 
clause.


in Debugger_Startup_Options.

Happy hacking;)

Thanks. The hackathon is proving to be productive !
(The new TSQLStatement component for sqldb is now a fact, some more tests, and 
I wil commit)

Michael.

--
_______________________________________________
Lazarus mailing list
[email protected]
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus

Reply via email to