Thank you for reply! >You configure the compiler *before* you build it, not after. Yes, I configured GCC before I built it. Just as following: #!/bin/sh LD_LIBRARY_PATH=/lab/home/zuoqi/gcc32/gcc-gnu-ccs/lib export LD_LIBRARY_PATH cd /lab/home/zuoqi/gcc32/build-gcc-gnu-ccs rm -rf * ../gcc-4.6.0/configure ABI=32 --prefix=/lab/home/zuoqi/gcc32/gcc-gnu-ccs --with-gnu-as --with-as=/usr/local/bin/as --with-gnu-ld --with-ld=/usr/local/bin/ld - -enable-languages=c,c++,java --with-gmp-include=/lab/home/zuoqi/gcc32/gcc-gnu-ccs/include --with-gmp-lib=/lab/home/zuoqi/gcc32/gcc-gnu-ccs/lib --with-mpfr-inc lude=/lab/home/zuoqi/gcc32/gcc-gnu-ccs/include --with-mpfr-lib=/lab/home/zuoqi/gcc32/gcc-gnu-ccs/lib --with-mpc-include=/lab/home/zuoqi/gcc32/gcc-gnu-ccs/incl ude --with-mpc-lib=/lab/home/zuoqi/gcc32/gcc-gnu-ccs/lib --without-ppl --without-cloog --enable-plugin --enable-lto make -j 64 make check make install echo gcc DONE! > Yes, if you install gmp, mpfr and mpc without using --disable-shared > then gcc depends on the shared libraries at runtime. > > See http://advogato.org/person/redi/diary/240.html (and the pages it > links to) for a simple way to build gcc so you don't need to set > LD_LIBRARY_PATH to use it. I once built GCC as this web page suggested. However, it seems to generate static libraries for gmp, mpfr and mpc rather than dynamic ones. > -bash-3.00$ export LD_LIBRARY_PATH=/lab/home/zuoqi/gcc32/gcc-gnu-ccs/lib > -bash-3.00$ echo $LD_LIBRARY_PATH > /lab/home/zuoqi/gcc32/gcc-gnu-ccs/lib > > Then, when I compile the hello.cpp program, I got unreferenced > std::cout problem. > Those symbols should be defined in libstdc++, maybe there's a symbol > versioning problem. > I'm not sure about this problem. The version of libstdc++.so of GCC4.4.2 is libstdc++.so.6.0.13 The version of libstdc++.so of GCC4.6.0 is libstdc++.so.6.0.15 Is this the problem?? Thanks! -- Regards Qi Zuo School Of Computer Science and Technology Beijng Institute of Technology, China, 100081