compile ksymoops
When you try to compile ksymoops tool, it may print the following message.
gcc -Dlinux -Wall -Wno-conversion -Waggregate-return -Wstrict-prototypes -Wmissing-prototypes -DINSTALL_PREFIX="\"/usr\"" -DCROSS="\"\"" -DDEF_KSYMS=\"/proc/ksyms\" -DDEF_LSMOD=\"/proc/modules\" -DDEF_OBJECTS=\"/lib/modules/*r/\" -DDEF_MAP=\"/usr/src/linux/System.map\" -c -o ksymoops.o ksymoops.c
In file included from ksymoops.c:14:0:
ksymoops.h:9:17: fatal error: bfd.h: No such file or directory
compilation terminated.
make: *** [ksymoops.o] Error 1
About this error, you can get the answer from the link http://lkml.indiana.edu/hypermail/linux/kernel/9902.1/0024.html. It tells you how to get bfd.h. If you work on Ubuntu. You can install binutils-dev to obtain it.
$ sudo apt-get install binutils-dev
But it still can't be compiled successfully. It needs libz and libdl library. So Maybe you still need to add -lz -ldl to the Makefile. They shuld be after -Wl,-Bdynamic.
Before use it, you should use "ksymoops -a '?'" and "ksymoops -t '?'' to check if it can support your arch and target or not!