gdb: “No symbol table is loaded”

前端 未结 5 884
耶瑟儿~
耶瑟儿~ 2020-12-02 10:26

I keep getting this error mesage when trying to add a breakpoint in gdb.

I\'ve used these commands to compile:

gcc -g main.c utmpib2.c -o main.o
and:         


        
5条回答
  •  心在旅途
    2020-12-02 10:43

    I met this issue this morning because I used the same executable in DIFFERENT OSes: after compiling my program with gcc -ggdb -Wall test.c -o test in my Mac(10.15.2), I ran gdb with the executable in Ubuntu(16.04) in my VirtualBox.

    Fix: recompile with the same command under Ubuntu, then you should be good.

提交回复
热议问题