Please, I need some help to compile the version 0.4.8a for Kubuntu Gutsy. Everything seems ok when I launch the ./configure command. But with the make command, the process stop with the following lines :
/usr/bin/ld: cannot find -lgfortran
collect2: ld returned 1 exit status
How can I solve the problem please ?
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
> /usr/bin/ld: cannot find -lgfortran
> collect2: ld returned 1 exit status
This is the classic issue with gcc and g++. Try 'gcc -v'. This should show 4.1.3 as the version. If so, then we can fix it easily. Install gcc 4.2 by 'aptitude install gcc-4.2'.
Then before configuring do the following..
$ export CC=/usr/bin/gcc-4.2; export C++=/usr/bin/g++-4.2
$ ./configure # add your usual options, if any
HTH,
Regards
PK
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Please, I need some help to compile the version 0.4.8a for Kubuntu Gutsy. Everything seems ok when I launch the ./configure command. But with the make command, the process stop with the following lines :
/usr/bin/ld: cannot find -lgfortran
collect2: ld returned 1 exit status
How can I solve the problem please ?
Hi f_bresson,
> /usr/bin/ld: cannot find -lgfortran
> collect2: ld returned 1 exit status
This is the classic issue with gcc and g++. Try 'gcc -v'. This should show 4.1.3 as the version. If so, then we can fix it easily. Install gcc 4.2 by 'aptitude install gcc-4.2'.
Then before configuring do the following..
$ export CC=/usr/bin/gcc-4.2; export C++=/usr/bin/g++-4.2
$ ./configure # add your usual options, if any
HTH,
Regards
PK
You need to add:
export LDFLAGS="-L/usr/lib/gcc/i486-linux-gnu/4.2/"
before configuring. The gfortran lib is not in the standard /usr/lib location, which causes the mentioned problem.
I solved the problem. The package gfortran-4.2 was already installed, but gfortran-4.1 was required. Thanks for your advices.