My system is Debian 64 bit
I have written a simple hello world program in c
2 #include <string.h>
3
4 int main() {
5 char str_a[20];
6
7 strcpy(str_a, "Hello, world!\n");
8 printf(str_a);
9 }
Compiled it with
gcc -g -o char_array2 char_array2.c
And fed into gdb via gdb -q ./char_array2
Now when i try to set up a breakpoint at strcpy like this
(gdb) break strcpy
Function "strcpy" not defined.
Make breakpoint pending on future shared library load? (y or [n]) y
Breakpoint 2 (strcpy) pending.
(gdb)
and try to run it, the breakpoint is not resolved, "Hello world" is printed out and the program terminates.
What SHOULD have happenend after pressing run
Breakpoint 4, 0xb7f076f4 in strcpy () from /lib/tls/i686/cmov/libc.so.6
Now i have read this in a book that teaches assembly on a 32bit system and also the path shows /i686/, so i suspect that there is some sort of funcitonality missing due to me using a 64bit processor. How can i fix this?