0

I cloned LEDE repository from github and wanted to debug my simple program on router. To do this, I configured LEDE build (like here: https://wiki.openwrt.org/doc/devel/gdb) using menuconfig:

Advanced configuration options (for developers) → Toolchain Options → Build gdb
Development → gdbserver
Development → gdb

Then I compiled my simple program with -ggdb3 flag and wanted to start debugging. However, it is impossible because gdbserver binary seems to be missing on router after sysupgrade (it does not appear in /bin, /sbin, /usr/bin, /usr/sbin). Have I missed something in this configuration?

P. Pedrycz
  • 41
  • 1
  • 9
  • "Then I compiled my simple program" you also need to rebuild the system image. It wasn't clear to me from documentation whether `sysupgrade` does that or not. – Employed Russian Sep 18 '16 at 18:40
  • Yes, for me it was also not clear, but that was not the problem in this case. Look at my answer, maybe it will save your time some day... – P. Pedrycz Sep 18 '16 at 20:16

1 Answers1

1

OK, I figured it out. When you build the system image and total package size is bigger than your available ROM (in my case 4MB), your .bin in /bin/targets/ directory won't be updated and you will get your old image. Everything without any warning message!

P. Pedrycz
  • 41
  • 1
  • 9