On Fri, 27 Jul 2007 10:42:11 +0300 Daniel Feiglin <[EMAIL PROTECTED]> wrote:
> Hello folks! > > During the course of trying to build an app from the tgz sources, I > received an odd looking message that gcc could not create an executable. > > After a little research, I tried to compile the canonical "Hello, world" > program with this: > > gcc -o hello hello.c > > and I got this: > > [EMAIL PROTECTED]:~> gcc -o hello hello.c > /usr/lib/gcc/i586-suse-linux/4.1.2/../../../crt1.o: In function `_start': > (.text+0xc): undefined reference to `__libc_csu_fini' > /usr/lib/gcc/i586-suse-linux/4.1.2/../../../crt1.o: In function `_start': > (.text+0x11): undefined reference to `__libc_csu_init' > collect2: ld returned 1 exit status > > I've never seen anything like that before (since SuSE 6.1). Can anyone > tell me what's going on here & how to fix it? > > Environment: openSUSE 10.2, kernel 2.6.18.8-0.3-default. > I'm using gcc as provided. > gcc -v gives: > Using built-in specs. > Target: i586-suse-linux > Configured with: ../configure --enable-threads=posix --prefix=/usr > --with-local-prefix=/usr/local --infodir=/usr/share/info > --mandir=/usr/share/man --libdir=/usr/lib --libexecdir=/usr/lib > --enable-languages=c,c++,objc,fortran,obj-c++,java,ada > --enable-checking=release --with-gxx-include-dir=/usr/include/c++/4.1.2 > --enable-ssp --disable-libssp --disable-libgcj --with-slibdir=/lib > --with-system-zlib --enable-shared --enable-__cxa_atexit > --enable-libstdcxx-allocator=new --program-suffix=-4.1 > --enable-version-specific-runtime-libs --without-system-libunwind > --with-cpu=generic --host=i586-suse-linux > Thread model: posix > gcc version 4.1.2 20061115 (prerelease) (SUSE Linux) > > ld -v gives: > GNU ld version 2.17.50.0.5 20060927 (SUSE Linux) I would suggest that you may be missing some packages. Check YaST to make sure that GCC is installed properly. I saw this a few weeks ago when I was trying to run an old version of gcc (3.3.3). If everything looks ok, then reinstall gcc and glibc. After reinstalling, just try recompiling hello.c. -- Jerry Feldman <[EMAIL PROTECTED]> Boston Linux and Unix user group http://www.blu.org PGP key id:C5061EA9 PGP Key fingerprint:053C 73EC 3AC1 5C44 3E14 9245 FB00 3ED5 C506 1EA9
signature.asc
Description: PGP signature
