我想在未安装ssh的arm-linux(debian)目标上使用Eclipse Oxygen调试应用程序。
所以我使用了C/C++ Attach to Application
方法。
我当然用g3
选项编译了应用程序,并将应用程序复制到目标上。
我已在目标上启动gdbserver
。
当我开始调试时(当然使用交叉gdb),它通过TCP连接到gdbserver
,它在应用程序的起始地址停止,但它不会加载源文件。
当我点击继续时,应用程序正常启动。
如果我在本地调试它,当然一切都很好。
这里缺少什么来加载源文件?
我可以提供什么有用的信息来猜测错误?
修改
make all
Building file: ../src/main.c
Invoking: Cross GCC Compiler
arm-buildroot-linux-gnueabihf-gcc -std=c99 -I"/home/user/Documents/Dev/Xwidgets/inc" -I"/home/user/Documents/Dev/myApp/inc" -O0 -g3 -Wall -c -fmessage-length=0 -Wno-missing-braces --sysroot=/home/user/Documents/myProject/sysroot -D_REENTRANT -fsigned-char -v -MMD -MP -MF"src/main.d" -MT"src/main.o" -o "src/main.o" "../src/main.c"
Utilisation des specs internes.
COLLECT_GCC=/home/user/Documents/myProject/buildroot-2017.05.2/board/a20som_IM4/cross/usr/bin/arm-buildroot-linux-gnueabihf-gcc.br_real
Target: arm-buildroot-linux-gnueabihf
Configuré avec: ./configure --prefix=/home/user/Documents/myProject/buildroot-2017.05.2/buildroot-2017.05.2/../board/a20som_IM4/cross/usr --sysconfdir=/home/user/Documents/myProject/buildroot-2017.05.2/buildroot-2017.05.2/../board/a20som_IM4/cross/etc --enable-static --target=arm-buildroot-linux-gnueabihf --with-sysroot=/home/user/Documents/myProject/buildroot-2017.05.2/buildroot-2017.05.2/../board/a20som_IM4/cross/usr/arm-buildroot-linux-gnueabihf/sysroot --disable-__cxa_atexit --with-gnu-ld --disable-libssp --disable-multilib --with-gmp=/home/user/Documents/myProject/buildroot-2017.05.2/buildroot-2017.05.2/../board/a20som_IM4/cross/usr --with-mpc=/home/user/Documents/myProject/buildroot-2017.05.2/buildroot-2017.05.2/../board/a20som_IM4/cross/usr --with-mpfr=/home/user/Documents/myProject/buildroot-2017.05.2/buildroot-2017.05.2/../board/a20som_IM4/cross/usr --with-pkgversion='Buildroot 2017.05.2-g3bca02e-dirty' --with-bugurl=http://bugs.buildroot.net/ --disable-libquadmath --enable-tls --disable-libmudflap --enable-threads --without-isl --without-cloog --disable-decimal-float --with-abi=aapcs-linux --with-cpu=cortex-a7 --with-fpu=vfpv4-d16 --with-float=hard --with-mode=arm --enable-languages=c --with-build-time-tools=/home/user/Documents/myProject/buildroot-2017.05.2/buildroot-2017.05.2/../board/a20som_IM4/cross/usr/arm-buildroot-linux-gnueabihf/bin --enable-shared --disable-libgomp
Modèle de thread: posix
gcc version 4.9.4 (Buildroot 2017.05.2-g3bca02e-dirty)
COLLECT_GCC_OPTIONS='-std=c99' '-I' '/home/user/Documents/Dev/Xwidgets/inc' '-I' '/home/user/Documents/Dev/myApp/inc' '-O0' '-g3' '-Wall' '-c' '-fmessage-length=0' '-Wno-missing-braces' '-D' '_REENTRANT' '-fsigned-char' '-v' '-MMD' '-MP' '-MF' 'src/main.d' '-MT' 'src/main.o' '-o' 'src/main.o' '-mcpu=cortex-a7' '-mfloat-abi=hard' '-mfpu=vfpv4-d16' '-mabi=aapcs-linux' '-marm' '-mtls-dialect=gnu'
/home/user/Documents/myProject/buildroot-2017.05.2/board/a20som_IM4/cross/usr/bin/../libexec/gcc/arm-buildroot-linux-gnueabihf/4.9.4/cc1 -quiet -v -I /home/user/Documents/Dev/Xwidgets/inc -I /home/user/Documents/Dev/myApp/inc -iprefix /home/user/Documents/myProject/buildroot-2017.05.2/board/a20som_IM4/cross/usr/bin/../lib/gcc/arm-buildroot-linux-gnueabihf/4.9.4/ -isysroot /home/user/Documents/myProject/sysroot -MMD src/main.d -MF src/main.d -MP -MT src/main.o -dD -D _REENTRANT ../src/main.c -quiet -dumpbase main.c -mcpu=cortex-a7 -mfloat-abi=hard -mfpu=vfpv4-d16 -mabi=aapcs-linux -marm -mtls-dialect=gnu -auxbase-strip src/main.o -g3 -O0 -Wall -Wno-missing-braces -std=c99 -version -fmessage-length=0 -fsigned-char -o /tmp/ccdyGfCH.s
GNU C (Buildroot 2017.05.2-g3bca02e-dirty) version 4.9.4 (arm-buildroot-linux-gnueabihf)
compiled by GNU C version 6.3.0 20170516, GMP version 6.1.2, MPFR version 3.1.5, MPC version 1.0.3
heuristiques GGC: --param ggc-min-expand=100 --param ggc-min-heapsize=131072
directory « /home/user/Documents/myProject/buildroot-2017.05.2/board/a20som_IM4/cross/usr/bin/../lib/gcc/arm-buildroot-linux-gnueabihf/4.9.4/../../../../arm-buildroot-linux-gnueabihf/include » est ignoré car inexistant
directory « /home/user/Documents/myProject/buildroot-2017.05.2/board/a20som_IM4/cross/usr/bin/../lib/gcc/../../lib/gcc/arm-buildroot-linux-gnueabihf/4.9.4/include » est ignoré car présent deux fois
directory « /home/user/Documents/myProject/sysroot/usr/local/include » est ignoré car inexistant
directory « /home/user/Documents/myProject/buildroot-2017.05.2/board/a20som_IM4/cross/usr/bin/../lib/gcc/../../lib/gcc/arm-buildroot-linux-gnueabihf/4.9.4/include-fixed » est ignoré car présent deux fois
directory « /home/user/Documents/myProject/buildroot-2017.05.2/board/a20som_IM4/cross/usr/bin/../lib/gcc/../../lib/gcc/arm-buildroot-linux-gnueabihf/4.9.4/../../../../arm-buildroot-linux-gnueabihf/include » est ignoré car inexistant
la recherche pour #include "..." débute ici :
la recherche pour #include <...> débute ici:
/home/user/Documents/Dev/Xwidgets/inc
/home/user/Documents/Dev/myApp/inc
/home/user/Documents/myProject/buildroot-2017.05.2/board/a20som_IM4/cross/usr/bin/../lib/gcc/arm-buildroot-linux-gnueabihf/4.9.4/include
/home/user/Documents/myProject/buildroot-2017.05.2/board/a20som_IM4/cross/usr/bin/../lib/gcc/arm-buildroot-linux-gnueabihf/4.9.4/include-fixed
/home/user/Documents/myProject/sysroot/usr/include
Fin de la liste de recherche.
GNU C (Buildroot 2017.05.2-g3bca02e-dirty) version 4.9.4 (arm-buildroot-linux-gnueabihf)
compiled by GNU C version 6.3.0 20170516, GMP version 6.1.2, MPFR version 3.1.5, MPC version 1.0.3
heuristiques GGC: --param ggc-min-expand=100 --param ggc-min-heapsize=131072
Compiler executable checksum: 97c01351799a22899fe6b56e86741046
COLLECT_GCC_OPTIONS='-std=c99' '-I' '/home/user/Documents/Dev/Xwidgets/inc' '-I' '/home/user/Documents/Dev/myApp/inc' '-O0' '-g3' '-Wall' '-c' '-fmessage-length=0' '-Wno-missing-braces' '-D' '_REENTRANT' '-fsigned-char' '-v' '-MMD' '-MP' '-MF' 'src/main.d' '-MT' 'src/main.o' '-o' 'src/main.o' '-mcpu=cortex-a7' '-mfloat-abi=hard' '-mfpu=vfpv4-d16' '-mabi=aapcs-linux' '-marm' '-mtls-dialect=gnu'
/home/user/Documents/myProject/buildroot-2017.05.2/board/a20som_IM4/cross/usr/bin/../lib/gcc/arm-buildroot-linux-gnueabihf/4.9.4/../../../../arm-buildroot-linux-gnueabihf/bin/as -v -I /home/user/Documents/Dev/Xwidgets/inc -I /home/user/Documents/Dev/myApp/inc -mcpu=cortex-a7 -mfloat-abi=hard -mfpu=vfpv4-d16 -meabi=5 -o src/main.o /tmp/ccdyGfCH.s
Version de l'assembleur GNU 2.27 (arm-buildroot-linux-gnueabihf) utilisant la version BFD (GNU Binutils) 2.27
COMPILER_PATH=/home/user/Documents/myProject/buildroot-2017.05.2/board/a20som_IM4/cross/usr/bin/../libexec/gcc/arm-buildroot-linux-gnueabihf/4.9.4/:/home/user/Documents/myProject/buildroot-2017.05.2/board/a20som_IM4/cross/usr/bin/../libexec/gcc/:/home/user/Documents/myProject/buildroot-2017.05.2/board/a20som_IM4/cross/usr/bin/../lib/gcc/arm-buildroot-linux-gnueabihf/4.9.4/../../../../arm-buildroot-linux-gnueabihf/bin/
LIBRARY_PATH=/home/user/Documents/myProject/buildroot-2017.05.2/board/a20som_IM4/cross/usr/bin/../lib/gcc/arm-buildroot-linux-gnueabihf/4.9.4/:/home/user/Documents/myProject/buildroot-2017.05.2/board/a20som_IM4/cross/usr/bin/../lib/gcc/:/home/user/Documents/myProject/buildroot-2017.05.2/board/a20som_IM4/cross/usr/bin/../lib/gcc/arm-buildroot-linux-gnueabihf/4.9.4/../../../../arm-buildroot-linux-gnueabihf/lib/:/home/user/Documents/myProject/sysroot/lib/:/home/user/Documents/myProject/sysroot/usr/lib/
COLLECT_GCC_OPTIONS='-std=c99' '-I' '/home/user/Documents/Dev/Xwidgets/inc' '-I' '/home/user/Documents/Dev/myApp/inc' '-O0' '-g3' '-Wall' '-c' '-fmessage-length=0' '-Wno-missing-braces' '-D' '_REENTRANT' '-fsigned-char' '-v' '-MMD' '-MP' '-MF' 'src/main.d' '-MT' 'src/main.o' '-o' 'src/main.o' '-mcpu=cortex-a7' '-mfloat-abi=hard' '-mfpu=vfpv4-d16' '-mabi=aapcs-linux' '-marm' '-mtls-dialect=gnu'
Finished building: ../src/main.c
Building target: myApp
Invoking: Cross GCC Linker
arm-buildroot-linux-gnueabihf-gcc -L"/home/user/Documents/Dev/Xwidgets/a20som_IM4" -v --sysroot=/home/user/Documents/myProject/sysroot -o "myApp" ./src/IMV_asymmetry.o ./src/IMV_power.o ./src/IMV_precision.o ./src/IMV_random.o ./src/IMV_sensibility.o ./src/IMV_speed.o ./src/IMV_timer.o ./src/free_session_screen.o ./src/fs_big_toolbar.o ./src/fs_page_1.o ./src/fs_page_2.o ./src/fs_page_3.o ./src/fs_page_4.o ./src/fs_right_sidebar.o ./src/fs_small_toolbar.o ./src/main.o ./src/patient_screen.o ./src/programs_screen.o ./src/run_timeline.o ./src/running_screen.o ./src/welcome_screen.o -lXwidgets -lpthread -lm -ljpeg -lpng16 -lSDL2 -lSDL2_image -lSDL2_ttf -ljson-c
Utilisation des specs internes.
COLLECT_GCC=/home/user/Documents/myProject/buildroot-2017.05.2/board/a20som_IM4/cross/usr/bin/arm-buildroot-linux-gnueabihf-gcc.br_real
COLLECT_LTO_WRAPPER=/home/user/Documents/myProject/buildroot-2017.05.2/board/a20som_IM4/cross/usr/bin/../libexec/gcc/arm-buildroot-linux-gnueabihf/4.9.4/lto-wrapper
Target: arm-buildroot-linux-gnueabihf
Configuré avec: ./configure --prefix=/home/user/Documents/myProject/buildroot-2017.05.2/buildroot-2017.05.2/../board/a20som_IM4/cross/usr --sysconfdir=/home/user/Documents/myProject/buildroot-2017.05.2/buildroot-2017.05.2/../board/a20som_IM4/cross/etc --enable-static --target=arm-buildroot-linux-gnueabihf --with-sysroot=/home/user/Documents/myProject/buildroot-2017.05.2/buildroot-2017.05.2/../board/a20som_IM4/cross/usr/arm-buildroot-linux-gnueabihf/sysroot --disable-__cxa_atexit --with-gnu-ld --disable-libssp --disable-multilib --with-gmp=/home/user/Documents/myProject/buildroot-2017.05.2/buildroot-2017.05.2/../board/a20som_IM4/cross/usr --with-mpc=/home/user/Documents/myProject/buildroot-2017.05.2/buildroot-2017.05.2/../board/a20som_IM4/cross/usr --with-mpfr=/home/user/Documents/myProject/buildroot-2017.05.2/buildroot-2017.05.2/../board/a20som_IM4/cross/usr --with-pkgversion='Buildroot 2017.05.2-g3bca02e-dirty' --with-bugurl=http://bugs.buildroot.net/ --disable-libquadmath --enable-tls --disable-libmudflap --enable-threads --without-isl --without-cloog --disable-decimal-float --with-abi=aapcs-linux --with-cpu=cortex-a7 --with-fpu=vfpv4-d16 --with-float=hard --with-mode=arm --enable-languages=c --with-build-time-tools=/home/user/Documents/myProject/buildroot-2017.05.2/buildroot-2017.05.2/../board/a20som_IM4/cross/usr/arm-buildroot-linux-gnueabihf/bin --enable-shared --disable-libgomp
Modèle de thread: posix
gcc version 4.9.4 (Buildroot 2017.05.2-g3bca02e-dirty)
COMPILER_PATH=/home/user/Documents/myProject/buildroot-2017.05.2/board/a20som_IM4/cross/usr/bin/../libexec/gcc/arm-buildroot-linux-gnueabihf/4.9.4/:/home/user/Documents/myProject/buildroot-2017.05.2/board/a20som_IM4/cross/usr/bin/../libexec/gcc/:/home/user/Documents/myProject/buildroot-2017.05.2/board/a20som_IM4/cross/usr/bin/../lib/gcc/arm-buildroot-linux-gnueabihf/4.9.4/../../../../arm-buildroot-linux-gnueabihf/bin/
LIBRARY_PATH=/home/user/Documents/myProject/buildroot-2017.05.2/board/a20som_IM4/cross/usr/bin/../lib/gcc/arm-buildroot-linux-gnueabihf/4.9.4/:/home/user/Documents/myProject/buildroot-2017.05.2/board/a20som_IM4/cross/usr/bin/../lib/gcc/:/home/user/Documents/myProject/buildroot-2017.05.2/board/a20som_IM4/cross/usr/bin/../lib/gcc/arm-buildroot-linux-gnueabihf/4.9.4/../../../../arm-buildroot-linux-gnueabihf/lib/:/home/user/Documents/myProject/sysroot/lib/:/home/user/Documents/myProject/sysroot/usr/lib/
COLLECT_GCC_OPTIONS='-L/home/user/Documents/Dev/Xwidgets/a20som_IM4' '-v' '-o' 'myApp' '-mcpu=cortex-a7' '-mfloat-abi=hard' '-mfpu=vfpv4-d16' '-mabi=aapcs-linux' '-marm' '-mtls-dialect=gnu'
/home/user/Documents/myProject/buildroot-2017.05.2/board/a20som_IM4/cross/usr/bin/../libexec/gcc/arm-buildroot-linux-gnueabihf/4.9.4/collect2 -plugin /home/user/Documents/myProject/buildroot-2017.05.2/board/a20som_IM4/cross/usr/bin/../libexec/gcc/arm-buildroot-linux-gnueabihf/4.9.4/liblto_plugin.so -plugin-opt=/home/user/Documents/myProject/buildroot-2017.05.2/board/a20som_IM4/cross/usr/bin/../libexec/gcc/arm-buildroot-linux-gnueabihf/4.9.4/lto-wrapper -plugin-opt=-fresolution=/tmp/cc9MsoIV.res -plugin-opt=-pass-through=-lgcc -plugin-opt=-pass-through=-lgcc_s -plugin-opt=-pass-through=-lc -plugin-opt=-pass-through=-lgcc -plugin-opt=-pass-through=-lgcc_s --sysroot=/home/user/Documents/myProject/sysroot --eh-frame-hdr -dynamic-linker /lib/ld-linux-armhf.so.3 -X -m armelf_linux_eabi -o myApp /home/user/Documents/myProject/sysroot/usr/lib/crt1.o /home/user/Documents/myProject/sysroot/usr/lib/crti.o /home/user/Documents/myProject/buildroot-2017.05.2/board/a20som_IM4/cross/usr/bin/../lib/gcc/arm-buildroot-linux-gnueabihf/4.9.4/crtbegin.o -L/home/user/Documents/Dev/Xwidgets/a20som_IM4 -L/home/user/Documents/myProject/buildroot-2017.05.2/board/a20som_IM4/cross/usr/bin/../lib/gcc/arm-buildroot-linux-gnueabihf/4.9.4 -L/home/user/Documents/myProject/buildroot-2017.05.2/board/a20som_IM4/cross/usr/bin/../lib/gcc -L/home/user/Documents/myProject/buildroot-2017.05.2/board/a20som_IM4/cross/usr/bin/../lib/gcc/arm-buildroot-linux-gnueabihf/4.9.4/../../../../arm-buildroot-linux-gnueabihf/lib -L/home/user/Documents/myProject/sysroot/lib -L/home/user/Documents/myProject/sysroot/usr/lib ./src/IMV_asymmetry.o ./src/IMV_power.o ./src/IMV_precision.o ./src/IMV_random.o ./src/IMV_sensibility.o ./src/IMV_speed.o ./src/IMV_timer.o ./src/free_session_screen.o ./src/fs_big_toolbar.o ./src/fs_page_1.o ./src/fs_page_2.o ./src/fs_page_3.o ./src/fs_page_4.o ./src/fs_right_sidebar.o ./src/fs_small_toolbar.o ./src/main.o ./src/patient_screen.o ./src/programs_screen.o ./src/run_timeline.o ./src/running_screen.o ./src/welcome_screen.o -lXwidgets -lpthread -lm -ljpeg -lpng16 -lSDL2 -lSDL2_image -lSDL2_ttf -ljson-c -lgcc --as-needed -lgcc_s --no-as-needed -lc -lgcc --as-needed -lgcc_s --no-as-needed /home/user/Documents/myProject/buildroot-2017.05.2/board/a20som_IM4/cross/usr/bin/../lib/gcc/arm-buildroot-linux-gnueabihf/4.9.4/crtend.o /home/user/Documents/myProject/sysroot/usr/lib/crtn.o
Finished building target: myApp