version `GFORTRAN_1.4' not found

Axel Freyn axel-freyn@gmx.de
Mon Feb 28 12:40:00 GMT 2011


Hi Janus,
On Mon, Feb 28, 2011 at 12:59:43PM +0100, Janus Weil wrote:
> Hi all,
> 
> I am currently seeing a curious problem when running any trivial
> hello-world program compiled with gfortran trunk:
> 
> jweil@manzanita:~> cat hello.f90
> 
> print *,"hello world!"
> end
> 
> jweil@manzanita:~> gfortran-4.6 hello.f90
> jweil@manzanita:~> ./a.out
> ./a.out: /usr/lib64/libgfortran.so.3: version `GFORTRAN_1.4' not found
> (required by ./a.out)
> 
> 
> 
> My machine runs openSUSE 11.3 (x86_64) with the default system compiler:
> 
> jweil@manzanita:~> gfortran -v
> Using built-in specs.
> COLLECT_GCC=gfortran
> COLLECT_LTO_WRAPPER=/usr/lib64/gcc/x86_64-suse-linux/4.5/lto-wrapper
> Target: x86_64-suse-linux
> Configured with: ../configure --prefix=/usr --infodir=/usr/share/info
> --mandir=/usr/share/man --libdir=/usr/lib64 --libexecdir=/usr/lib64
> --enable-languages=c,c++,objc,fortran,obj-c++,java,ada
> --enable-checking=release --with-gxx-include-dir=/usr/include/c++/4.5
> --enable-ssp --disable-libssp --disable-plugin
> --with-bugurl=http://bugs.opensuse.org/ --with-pkgversion='SUSE Linux'
> --disable-libgcj --disable-libmudflap --with-slibdir=/lib64
> --with-system-zlib --enable-__cxa_atexit
> --enable-libstdcxx-allocator=new --disable-libstdcxx-pch
> --enable-version-specific-runtime-libs --program-suffix=-4.5
> --enable-linux-futex --without-system-libunwind --enable-gold
> --with-plugin-ld=/usr/bin/gold --with-arch-32=i586 --with-tune=generic
> --build=x86_64-suse-linux
> Thread model: posix
> gcc version 4.5.0 20100604 [gcc-4_5-branch revision 160292] (SUSE Linux)
> 
> 
> and a homegrown GCC trunk:
> 
> jweil@manzanita:~> gfortran-4.6 -v
> Using built-in specs.
> COLLECT_GCC=gfortran-4.6
> COLLECT_LTO_WRAPPER=/usr/lib64/gcc/x86_64-unknown-linux-gnu/4.6.0/lto-wrapper
> Target: x86_64-unknown-linux-gnu
> Configured with: /home/jweil/gcc46/trunk/configure
> --program-suffix=-4.6 --prefix=/usr --libdir=/usr/lib64
> --libexecdir=/usr/lib64 --enable-languages=c,fortran --enable-checking
> --enable-lto --disable-bootstrap --disable-multilib
> --enable-version-specific-runtime-libs
> Thread model: posix
> gcc version 4.6.0 20110228 (experimental) [trunk revision 170558] (GCC)
> 
> 
> I have been running in this configuration for quite some time without
> any problems. Can anyone give me a clue what's wrong? I was asuming
> '--enable-version-specific-runtime-libs' would take care of handling
> several GCC versions on one system?!?

Did you run a suse update lately? My understanding of the error: the
runtime finds a libgfortran.so - library (/usr/lib64/libgfortran.so.3)
-- however, this one is "too old" and does not contain GFORTRAN_1.4.

And you did something "dangerous": by using "--prefix=/usr" to the
configure-script, you told gcc-4.6 to install his self-compiled
libraries into the directory /usr/lib64 -- where also the package
manager from Open-SuSE acts:
 - by your manual "make install" of gcc-4.6,
   "/usr/lib64/libgfortran.so.3" was overwritten by the gcc-4.6 -
   version of the file
 - by a later YaST-update, which includes an update of the
   gfortran-libraries, /usr/lib64/libgfortran.so.3 will again be
   overwritten -- by the "official" OpenSuse-version, which is 4.5 at
   the moment.

So I would assume, that the file "/usr/lib64/libgfortran.so.3" is no
longer the one from gcc-4.6, but the version from gcc-4.5, which has
been installed by YaST. Is that possible?

The "save" way would be to install your private gcc-4.6-version
somewhere where YaST does nothing (like /usr/local) -- that way you can be
quite sure that "your" files will never be overwritten by YaST.

Axel



More information about the Fortran mailing list