By Avi Rozen on November 28, 2007
In theory, GDB, the GNU debugger, can ease the chore of debugging applications running on a Linux-based embedded system. In practice, setting up GDB for this task is a bit of a challenge; it takes some work, and there are some technical hurdles to overcome. However, the benefits of having a way to methodically debug a program instead of guessing what's wrong with it far outweigh the effort involved. Here are some tips for easing the difficulties.
#include <stdio.h> int main(int argc, char **argv) { printf ("Hello\n"); return (0); }
gcc -c hello.c
Компиляция hello.o из hello.c:
gcc -o hello hello.o
Создание исполняемого файла hello.exe из hello.o.
gcc -o hello hello.c
Автор: Владимир Игнатов
Оглавление