From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 11590 invoked by alias); 16 Dec 2001 07:57:39 -0000 Mailing-List: contact gcc-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Archive: List-Post: List-Help: Sender: gcc-owner@gcc.gnu.org Received: (qmail 11335 invoked from network); 16 Dec 2001 07:56:22 -0000 Received: from unknown (HELO relay01.roc.frontiernet.net) (66.133.130.232) by sources.redhat.com with SMTP; 16 Dec 2001 07:56:22 -0000 Received: (qmail 6507 invoked from network); 16 Dec 2001 07:56:21 -0000 Received: from unknown (HELO elrond.bard.edu) ([170.215.193.56]) (envelope-sender ) by 0 (qmail-ldap-1.03) with SMTP for ; 16 Dec 2001 07:56:21 -0000 Message-Id: <4.3.2-J.20011216023652.00beea60@smtp.citlink.net> X-Sender: sc843@mail.bard.edu X-Mailer: QUALCOMM Windows Eudora Version 4.3.2-J Date: Sun, 16 Dec 2001 00:42:00 -0000 To: gcc@gcc.gnu.org From: Sean Callanan Subject: sparc g++ fails "Hello world!" Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii"; format=flowed X-SW-Source: 2001-12/txt/msg00862.txt.bz2 Dear mailing list: The short version of this story is that a carefully bootstrapped g++ on a new LFS partition (g++ 3.0.2, glibc 2.2.4) creates binaries that have bus errors. If you are interested, here's the legend that goes along with it. - In the reign of GNU C Library stable release version 2.1.3 Compiled by GNU CC version 2.95.2.19991024 (release) Compiled on a Linux 2.2.16 system on 2000-08-08 there was created by Root (through his prophet RPM) the righteous GNU binutils version 2.9.5 (sparc-suse-linux) using BFD version 2.9.5.0.24 and there was also Root's misbegotten offspring by a mistaken "make install" pass: gcc version 3.0.2 Configured with ../gcc-3.0.2/configure --prefix=/usr --exec-prefix=/usr --enable-languages=c,c++ --disable-nls --disable-shared --host=sparc-linux --target=sparc-linux --program-prefix=sparc-linux- which was a static binary. They begat GNU binutils 2.11 which was a most righteous static binary, and gcc version 3.0.2 Configured with ../gcc-3.0.2/configure --prefix=/usr --enable-languages=c,c++ --disable-nls --disable-shared --enable-threads=posix --program-prefix=sparc-linux- which was also static, having at birth been "make bootstrap"ped most carefully. This binary was perfect save that the ruler (glibc 2.1.3) forbade inclusions of stdio-limits.h and therefore libstdc++ could not be built. These two were "make install"ed by Root into a new Partition, and Root said, "Grow, multiply, may your compiled offspring cover the new Partition" for this was a Linux-from-Scratch partition. Now they begat a new ruler: GNU C Library stable release version 2.2.4 Compiled by GNU CC version 3.0.2 Compiled on a Linux 2.4.16 system on 2001-12-13 and under his reign there was born a "bootstrap"ping baby, gcc version 3.0.2 Configured width ../gcc-3.0.2/configure --prefix=/usr --enable-languages=c,c++,objc,java --enable-threads=posix --program-prefix=sparc-linux- --host=sparc-linux But all was not well in the new Partition, for Root came and issued the following Commands: # cat test.cc #include int main() { cout << "Hello world!" << endl; return(0); } # sparc-linux-g++ -o test-c++ test.cc # ./test-c++ Bus error # And there was much suffering among the people, for g++ was a necessity. And one rose up from the mass and cried, "Lord Root, if thou canst not help us, then call upon the gods of far gcc@gcc.gnu.org for among them are sages of wisdom who may be of help!" - And that's the legend. Does GCC make any modifications to the libstdc++ header files during compilation? I think I installed the header files for the static binary that wouldn't compile the library properly, and perhaps that inhibited the installation of proper headers when the good dynamic binary was built. Any ideas? Sincerely, Sean Callanan Sincerely, Sean Callanan