RE: gfortan requires old directory in LD_LIBRARY_PATH or else gmp error

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



>  From: Rupert Wood <me@xxxxxxxxx>
>  
>  Poor Yorick wrote:
>  
>  > Why does the newly-compiled gfortran need this old path in
>  > LD_LIBRARY_PATH to function?
>  
>  It looks like it's because you built shared-library-only versions of GMP and MPFR with the old compiler which now depend on the old compiler's runtime libraries. gfortran depends on GMP and MPFR and so you must have the old compiler's runtime libraries in your path to run gfortran.
>  
>  One solution might be to replace your GMP and MPFR .sos with new versions built with your new compiler. Alternatively you could make sure you have static versions of them and rebuild GCC 4.2, checking it picks up the static versions not the shared libraries which should not have the dependence.
>  

I have gmp and mpfr built as both static and dynamic libraries, and those libraries reside in the same directory.  So far, the only way I can get a clean (no LD_LIBRARY_PATH dependency on preexisting gcc) build of gcc is if I remove the dynamic libraries of gmp and mpfr.  Short of not building the shared objects, is there some other way to tell gcc to pull in gmp.a and mpfr.a?  Otherwise, it sounds like the following is the way to go:

1.  build gmp and mpfr static only
2.  build gcc
3.  remove gmp and mpfr
4.  build gmp and mpfr this time with new gcc, shared and static

-- 
Poor Yorick

[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux