|
qemu compile issues
I am trying to add some code to qemu source for my school work. I want to be able to read some area of guest memory into the host user land. I looked at functions copy_from_user which exists in ~/linux-user/uaccess.c I tried to call this function from ~/qemu-kvm.c. I get numerous compile errors even after including #include "linux-user/qemu.h". The compiler cannot find any of the header files that get included from qemu.h when the make command is issued one directory up.
I also tried to use 'g2h()' macro present in ~/cpu-all.h. I figured since they are in the same directory, if I just #include "cpu-all.h" in qemu-kvm.c it should work, but even that gives a compile error of undefined symbol 'g2h'.
After more experimentation I found that the make does not compile the files in the directory qemu_src/linux-user. i know this as I placed an obvious compile error in qemu_src/linux-user/qemu.h, the make clean; make does not spot any issue.
So what is the trick to compiling functions in linux-user directory? Are my config options wrong?
All I need is that at any point of time the host should be able to take a memory dump of the guest's memory. Which seems like a very logical functionality that I should be able to implement. Its all virtual memory of the host qemu process.
If there is a functionality which allows the host to obtain memory of the guest at any time without doing this, then I will appreciate pointers.
Thanks
Last edited by raghu2383; 01-25-11 at 03:11 AM. Reason: did more experimentation
I hope you don't mind, I am adding this by mod edit to keep the thread on the 0-reply list.
1st, unfortunately the is not an area of my expertise, so I have no on-point help to offer. -- Sorry.
2nd, Smart move editing in the new info. -- it kept this on the 0-reply list.
3rd, my actual question: What, however fruitless, searches have you done to see if someone else has already done this?
Last edited by archtoad6; 01-30-2011 at 09:03 AM.
Reason: add question w/o bumping from 0-reply
|