Beefy Boxes and Bandwidth Generously Provided by pair Networks
go ahead... be a heretic

Perl XS and gdb via C++

by artist (Parson)
on Jul 24, 2008 at 20:20 UTC ( #699955=perlquestion: print w/ replies, xml ) Need Help??
artist has asked for the wisdom of the Perl Monks concerning the following question:

Dear Monks
I have C++ programs which calls for C routine as well. I can use gdb with C++ and it works fine. C++ programs also works fine with make file etc.. and runs nicely. Now I have Perl Interface to this program via XS Mechanism and I found out that there is a bug in a C routine ( called via extern from C++). I like to debug (using gdb) it without rebuilding the XS every now and then. How I can achieve the same? My platform is linux. I use Emacs M-x gdb.I appreciate your help.



Comment on Perl XS and gdb via C++
Download Code
Replies are listed 'Best First'.
Re: Perl XS and gdb via C++
by diotalevi (Canon) on Jul 25, 2008 at 07:11 UTC

    Ok, in that case make sure your XS is always compiled with symbols.

    WriteMakefile( ... OPTIMIZE => '-g', )

    ⠤⠤ ⠙⠊⠕⠞⠁⠇⠑⠧⠊

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: perlquestion [id://699955]
Approved by ikegami
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others scrutinizing the Monastery: (5)
As of 2015-11-26 00:20 GMT
Find Nodes?
    Voting Booth?

    What would be the most significant thing to happen if a rope (or wire) tied the Earth and the Moon together?

    Results (693 votes), past polls