On Wed, Oct 30, 2013 at 2:43 AM, Antony Pavlov <antonynpav...@gmail.com> wrote: > On Tue, 29 Oct 2013 21:09:30 +0800 > Nancy <nancydream...@gmail.com> wrote: > > Some years ago I have made a set of scripts for building MIPS linux kernel and > rootfs from scratch and running it under qemu. > See https://github.com/frantony/clab for details, > especialy see start-qemu.sh script and files in the > qemu-configs/malta-linux-gnu > subdirectory. > > Also see a versatile 'buildroot' software for easy rootfs creation > (www.buildroot.org).
Wow, what a good Idea to create this tool! That will save people's time! I have ran: $./mk_src_dir.sh $./build-all.sh MKDIR config.gen IN config.gen/arch.in IN config.gen/kernel.in IN config.gen/cc.in IN config.gen/libc.in IN config.gen/debug.in CONF config/config.in run_with_check: ./ct-ng build.24 [INFO ] Performing some trivial sanity checks [INFO ] Build started 20131030.171948 [INFO ] Building environment variables [EXTRA] Preparing working directories [ERROR] [ERROR] >> [ERROR] >> Error happened in: CT_DoExecLog[scripts/functions] [ERROR] >> called from: main[scripts/crosstool-NG.sh@235] [ERROR] >> [ERROR] >> For more info on this error, look at the file: 'build.log' [ERROR] >> There is a list of known issues, some with workarounds, in: [ERROR] >> 'docs/B - Known issues.txt' [ERROR] [ERROR] Build failed in step 'Dumping user-supplied crosstool-NG configuration' [ERROR] [ERROR] (elapsed: 0:00.18) [00:00] / make[1]: *** [build] Error 1 make: *** [build.24] Error 2 fail: ./ct-ng build.24 >> 1. When QEMU for MIPS support watchpoint debug facility? Any hint or guide >> to implement that function? > > Run qemu with -S and -s options. Next start your cross gdb (e.g. > mips-linux-gdb), > next in the gdb cmdline use command "target remote :1234" to connect to qemu. Thank you very much! I did not use cross gdb so I got wrong, then I saw the QEMU internal paper, it says current MIPS limitation do not implement watchpoint debug facility, I though it was QEMU bug. So give up QEMU internal gdb try. Now it work with cross gdb, Thank you very much Sir :-) By the way, do you know how to compile linux kernel with -O0 option to forbid gdb pointer jump back and forth... >> 2. qemu-system-mipsel -M malta -kernel vmlinux-2.6.26-1-4kc-malta -hda >> debian_lenny_mipsel_small.qcow2 -append "root=/dev/hda1 console=ttyS0 >> kgdboc=ttyS0,115200 kgdbwait" -nographic -serial tcp::1234,server -net >> nic,model=pcnet -net user >> >> Did I miss something? I cannot see the bootup message in the current client >> unless I remove "-serial tcp::1234,server" away. But I need that for kgdb >> debug. What is the right way to configure it? > > Do you really need this "in-kernel" gdb support? As I have already write, > qemu itself has gdb server functionality support. Though maybe I do not use kgdb, I still want to know the right way to configure it ;-) -- Best Regards, Yu Rong Tan