Hello
Have someone tried debugging C program for voCore2 and succeed?
I followed this tutorial to setup eclipse:
https://docs.labs.mediatek.com/resource ... clipse-ide
Everything goes fine, untill i stuck with error which goes "remote 'g' packet reply is too long" (see attachment 1)
None of set main() breakpoints working, something only stucks at program start(see attachment 2), but i don`t now why debugger set program counter there, when i try to resume program i get mentioned error
Greetings
C program debugging with eclipse
- kermit
- Posts: 6
- Joined: Sat Sep 23, 2017 10:54 pm
C program debugging with eclipse
- Attachments
-
- eclipse_error2.png (116.2 KiB) Viewed 6211 times
-
- eclipse_error.png (148.62 KiB) Viewed 6211 times
- Vonger
- Posts: 896
- Joined: Sun Oct 19, 2014 6:00 am
Re: C program debugging with eclipse
As I know it is a GDB issue, you need to recompile your GDB with a special flag...(can not remember but can be find at google), then replace the default GDB of eillesp currently using, everything will work.
I have tried this before and get same result when using command line, solved by recompile GDB, later I will update my blog, good luck.
I have tried this before and get same result when using command line, solved by recompile GDB, later I will update my blog, good luck.
- kermit
- Posts: 6
- Joined: Sat Sep 23, 2017 10:54 pm
Re: C program debugging with eclipse
Wow, finally after three days i resolved this issue, thanks for hint Vonger.
So, problem was with missing expat library, if someone will have similar problem this is what You have to do:
1. Install expat library on your host machine
on ubuntu 15.04:
probably only one of these are needed, but don`t really sure which one of these
2. Edit gdb makefile( [openWrt_dir]/toolchain/gdb/Makefile ), we need to add line " --with-expat" to "define Host/Configure" procedure
so it looks like this
3. Rebuild gdb with command
So, problem was with missing expat library, if someone will have similar problem this is what You have to do:
1. Install expat library on your host machine
on ubuntu 15.04:
- Code: Select all
sudo apt-get install expat libexpat1-dev
probably only one of these are needed, but don`t really sure which one of these
2. Edit gdb makefile( [openWrt_dir]/toolchain/gdb/Makefile ), we need to add line " --with-expat" to "define Host/Configure" procedure
so it looks like this
- Code: Select all
define Host/Configure
(cd $(HOST_BUILD_DIR); \
gdb_cv_func_sigsetjmp=yes \
CFLAGS="-O2" \
$(HOST_BUILD_DIR)/configure \
--prefix=$(TOOLCHAIN_DIR) \
--build=$(GNU_HOST_NAME) \
--host=$(GNU_HOST_NAME) \
--target=$(REAL_GNU_TARGET_NAME) \
--disable-werror \
--without-uiout \
--disable-tui --disable-gdbtk --without-x \
--without-included-gettext \
--enable-threads \
--with-expat \
);
endef
3. Rebuild gdb with command
- Code: Select all
make toolchain/gdb/{clean,compile,install}
- noblepepper
- Posts: 240
- Joined: Sat Nov 29, 2014 3:22 pm
4 posts
Page 1 of 1
Who is online
Users browsing this forum: No registered users and 77 guests