This is a discussion on problem with gcc at Debian within the Linux Operating System forums, part of the Unix Operating Systems category; --> i've written a program in C that connects with a MySQL Database. When it compile : gcc mysql_ins_server.c -o ...
| |||||||
| Register | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| ||||
| i've written a program in C that connects with a MySQL Database. When it compile : gcc mysql_ins_server.c -o mysql_ins_server -I /usr/local/mysql/include/ -L /usr/local/mysql/lib/ -lmysqlclient -lz i take the follwoing errors: /usr/lib/libc_nonshared.a(elf-init.oS)(.gnu.linkonce.t.__i686.get_pc_thunk.bx+0x 0): In function `__i686.get_pc_thunk.bx': : multiple definition of `__i686.get_pc_thunk.bx' /usr/lib/gcc-lib/i486-linux/3.3.5/../../../libz.a(compress.o)(.text.__i686.get_pc_thunk.bx+0x 0): first defined here /usr/lib/gcc-lib/i486-linux/3.3.5/../../../libz.a(inflate.o)(.text+0x485): In function `inflateSync': : undefined reference to `__stack_chk_fail_local' /usr/lib/gcc-lib/i486-linux/3.3.5/../../../libz.a(inflate.o)(.text+0x1de1): In function `.L553': : undefined reference to `__stack_chk_fail_local' collect2: ld returned 1 exit status /usr/lib/libc_nonshared.a(elf-init.oS)(.gnu.linkonce.t.__i686.get_pc_thunk.bx+0x 0): In function `__i686.get_pc_thunk.bx': : multiple definition of `__i686.get_pc_thunk.bx' /usr/lib/gcc-lib/i486-linux/3.3.5/../../../libz.a(compress.o)(.text.__i686.get_pc_thunk.bx+0x 0): first defined here /usr/lib/gcc-lib/i486-linux/3.3.5/../../../libz.a(inflate.o)(.text+0x485): In function `inflateSync': : undefined reference to `__stack_chk_fail_local' /usr/lib/gcc-lib/i486-linux/3.3.5/../../../libz.a(inflate.o)(.text+0x1de1): In function `.L553': : undefined reference to `__stack_chk_fail_local' collect2: ld returned 1 exit status because im' new to Linux i haven''t find out anything yet. Any help appreciated. |
| ||||
| Make sure you have a recent version of GCC and binutils. I just ran into the same problem with python 2.4.3. It had nothing to do with the code base. The linker was broken and an update of my binutils fixed the issue. Kind regards, Chris |