title: Cannot open libmpc.so.3 while making gcc4.8.1
body: <p>I want to install gcc4.8.1 on ubuntu 10.04. </p>
  
  <p>Here are my installing steps:</p>
  
  <ol>
  <li><p>Install libgmp, libmpfr and libmpc.</p></li>
  <li><p>After switch to gcc4.8.1 source code dir, run "./configure --prefix=/usr/bin/gcc4.8.1 --with-gmp=/opt/pkg/gmp5.1.2 --with-mpfr=/opt/pkg/mpfr3.1.2 --with-mpc=/opt/pkg/mpc1.0.1"</p></li>
  <li><p>make</p></li>
  <li><p>export LD_LIBRARY_PATH=/opt/pkg/gmp5.1.2/lib:/opt/pkg/mpfr3.1.2/lib:/opt/pkg/mpc1.0.1/lib</p></li>
  <li><p>sudo make install.</p></li>
  </ol>
  
  <p>In the last step I get this error:</p>
  
  <pre><code>/usr/local/sbin/gcc-4.8.1/host-i686-pc-linux-gnu/gcc/cc1: error while loading shared   libraries: libmpc.so.3: cannot open shared object file: No such file or directory
  make[5]: *** [install-exec-hook] Error 1
  make[5]: Leaving directory `/usr/local/sbin/gcc-4.8.1/i686-pc-linux-gnu/libjava'
  make[4]: *** [install-exec-am] Error 2
  make[4]: Leaving directory `/usr/local/sbin/gcc-4.8.1/i686-pc-linux-gnu/libjava'
  make[3]: *** [install-am] Error 2
  make[3]: Leaving directory `/usr/local/sbin/gcc-4.8.1/i686-pc-linux-gnu/libjava'
  make[2]: *** [install-recursive] Error 1
  make[2]: Leaving directory `/usr/local/sbin/gcc-4.8.1/i686-pc-linux-gnu/libjava'
  make[1]: *** [install-target-libjava] Error 2
  make[1]: Leaving directory `/usr/local/sbin/gcc-4.8.1'
  make: *** [install] Error 2
  </code></pre>
  
  <p>I have switched to the libmpc library path and tested libmpc.so.3 with ldd. It has been installed successfully. Why does it say it cannot open shared object libmpc.so.3? How can I fix it? </p>