From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 2856 invoked by alias); 17 Jan 2002 14:50:29 -0000 Mailing-List: contact gcc-help-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Archive: List-Post: List-Help: Sender: gcc-help-owner@gcc.gnu.org Received: (qmail 2777 invoked from network); 17 Jan 2002 14:50:28 -0000 Received: from unknown (HELO ftpbox.mot.com) (129.188.136.101) by sources.redhat.com with SMTP; 17 Jan 2002 14:50:28 -0000 Received: [from pobox3.mot.com (pobox3.mot.com [10.64.251.242]) by ftpbox.mot.com (ftpbox 2.1) with ESMTP id HAA17533 for ; Thu, 17 Jan 2002 07:50:27 -0700 (MST)] Received: [from il02exi02.comm.mot.com (il02exi02.comm.mot.com [145.1.204.41]) by pobox3.mot.com (MOT-pobox3 2.0) with ESMTP id HAA03503 for ; Thu, 17 Jan 2002 07:39:35 -0700 (MST)] Date: Thu, 17 Jan 2002 06:50:00 -0000 Received: by il02exi02.comm.mot.com with Internet Mail Service (5.5.2654.52) id <4XDFRAQA>; Thu, 17 Jan 2002 08:50:25 -0600 Message-ID: <1FA6C7249817D4119B9800D0B73E99A605118F72@il02exm27.comm.mot.com> From: Rocha Iran-QIR001 To: "'gcc-help@gcc.gnu.org'" Subject: GCC 2.95.3 Cross-Compiler for Linux-PPC - libiberty configure fai lure X-SW-Source: 2002-01/txt/msg00177.txt.bz2 Date: Thu, 17 Jan 2002 08:50:23 -0600 MIME-Version: 1.0 X-Mailer: Internet Mail Service (5.5.2654.52) Content-Type: text/plain; charset="iso-8859-1" Hi, I am trying to install GCC 2.95.3 as a cross-compiler with the following configuration: host: sparc-sun-solaris2.6 target: powerpc-unknown-linux-gnu --with-gnu-as and --with-gnu-ld: GNU Binutils 2.11 installation of cross-assm and cross-linker --enable-threads: I'm not defining the threads type during configuration Configure is called a few times during the build but the following call fails: Configuring in powerpc-unknown-linux-gnu/libiberty creating cache ./config.cache checking host system type... powerpc-unknown-linux-gnu checking build system type... sparc-sun-solaris2.6 checking for powerpc-unknown-linux-gnu-ar... powerpc-unknown-linux-gnu-ar checking for powerpc-unknown-linux-gnu-ranlib... powerpc-unknown-linux-gnu-ranlib checking for gcc... /export/usr1/srv/data/objdir/gcc/xgcc -B/export/usr1/srv/data/objdir/gcc/ -B/mot/proj/vendor/public_domain/gcc/2.95.3 /A11/powerpc-unknown-linux-gnu/bin/ checking whether we are using GNU C... yes checking whether /export/usr1/srv/data/objdir/gcc/xgcc -B/export/usr1/srv/data/objdir/gcc/ -B/mot/proj/vendor/public_domain/gcc/2.95.3/A1 1/powerpc-unknown-linux-gnu/bin/ accepts -g... yes checking for POSIXized ISC... no checking for a BSD compatible install... ../../../gcc-2.95.3/libiberty/../install-sh -c checking how to run the C preprocessor... /export/usr1/srv/data/objdir/gcc/xgcc -B/export/usr1/srv/data/objdir/gcc/ -B/mot/proj/vendor/pu blic_domain/gcc/2.95.3/A11/powerpc-unknown-linux-gnu/bin/ -E checking for sys/file.h... yes checking for sys/param.h... yes checking for stdlib.h... yes checking for string.h... yes checking for unistd.h... yes checking for strings.h... yes checking for sys/time.h... yes checking for sys/resource.h... yes checking for sys/wait.h that is POSIX.1 compatible... yes checking whether the C compiler (/export/usr1/srv/data/objdir/gcc/xgcc -B/export/usr1/srv/data/objdir/gcc/ -B/mot/proj/vendor/public_doma in/gcc/2.95.3/A11/powerpc-unknown-linux-gnu/bin/ -g -O2 ) works... no configure: error: installation or configuration problem: C compiler cannot create executables. Since no Makefile for libiberty was generated, the whole build fails as follows: make[2]: Entering directory `/export/usr1/srv/data/objdir/powerpc-unknown-linux-gnu/libiberty' make[2]: *** No targets specified and no makefile found. Stop. make[2]: Leaving directory `/export/usr1/srv/data/objdir/powerpc-unknown-linux-gnu/libiberty' make[1]: *** [../libiberty/libiberty.a] Error 2 make[1]: Leaving directory `/export/usr1/srv/data/objdir/powerpc-unknown-linux-gnu/libstdc++' make: *** [all-target-libstdc++] Error 2 When I tail /powerpc-unknown-linux-gnu/libiberty/config.log I see the following explanation for the failure: configure:1765: /export/usr1/srv/data/objdir/gcc/xgcc -B/export/usr1/srv/data/objdir/gcc/ -B/mot/proj/vendor/public_domain/gcc/2.95.3/A11/powerpc- unknown-linux-gnu/bin/ -o conftest -g -O2 conftest.c 1>&5 /usr/misc/GNU/binutils-2.11/bin/powerpc-unknown-linux-gnu-ld: cannot find -lc collect2: ld returned 1 exit status For some reason, the binary xgcc that was previously built is not able to compile because it cannot find libc. I have provided to the build a copy of libc from my target machine along with other libraries and include files using the --with-headers and --with-libs configure options. However, for some reason xgcc is still not able to find it. I was able to reproduce the problem by opening another shell and trying to compile a simple "Hello World" C program with xgcc as follows: > /export/usr1/srv/data/objdir/gcc/xgcc -B/export/usr1/srv/data/objdir/gcc/ -B/mot/proj/vendor/public_domain/gcc/2.95.3/A11 -g -O2 my.c /usr/misc/GNU/binutils-2.11/bin/powerpc-unknown-linux-gnu-ld: cannot find -lc collect2: ld returned 1 exit status Interesting enough, xgcc knows how to get to the libraries when I ask it to print the name of libgcc: srv(usr)[403]> /export/usr1/srv/data/objdir/gcc/xgcc -print-libgcc-file-name /mot/proj/vendor/public_domain/gcc/2.95.3/A11/powerpc-unknown-linux-gnu/lib/libgcc.a srv(usr)[404]> ls /mot/proj/vendor/public_domain/gcc/2.95.3/A11/powerpc-unknown-linux-gnu/lib COPIED crt1.o crtn.o libc-2.1.3.so* libgcc.a libm.a libstdc++.a.2.10.0 Mcrt1.o crti.o gcrt1.o libc.so.6@ libm-2.1.3.so* libm.so.6@ I tried also to specify the path to libc using -L w/o success. Am I missing something? I cannot identify the reason for the failure? Would anyone be able to help me? Thank you in advance, Rocha