Skip to contentSkip to conversation

libxc printfs and debugging

DISCUSSION David Pilger 2 participants 2 messages Mar 7, 2007

lore
Share & tools
lore
#0 lore raw

Hi,

Where does all the IPRINTF output goes in libxc? I can't find it (the INFO constant is 1 of course)...

How do you debug libxc code btw?

Thanks,
David.

#1 lore raw
Quoted 4 lines · David Pilger

Hi,

Where does all the IPRINTF output goes in libxc? I can't find it (the INFO constant is 1 of course)...

I'm not sure about the IPRINTF, but if you build the tools with debug=y passed to the make command, the DPRINTFs go to

/var/lib/xen/xend-debug.log

Quoted 3 lines

How do you debug libxc code btw?

I found uncommenting the following in tools/libxc/Makefile , and rebuilding (cd tools; make debug=y ) very useful when debugging as it let me attach with gdb to the xend python process and define break points in the libxc code.

# Define this to make it possible to run valgrind on code linked with

# these
# libraries.
CFLAGS   += -DVALGRIND -O0 -ggdb3
Signature · 5 lines
Ryan Harper
Software Engineer; Linux Technology Center
IBM Corp., Austin, Tx
(512) 838-9253   T/L: 678-9253
[email protected]