This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Trouble installing gfortran


Recently I have been describing my troubles installing gfortran in the
comp.lang.fortran newsgroup, and FX has given useful help. But today
my system won't let me read anything in that newsgroup so I'm emailing
to you.

One thing that wasn't suggested but I find allowed me to configure GCC,
make and make install was  rm -f /tmp/gccobj/prev-* before starting.
(I used a bash shell script saying inter alia
srcdir=/tmp/gcc-4.6.2
objdir=/tmp/gccobj
prefix=/tmp/gf
gccopts=" --prefix=$prefix --enable-languages=c,c++,fortran"
gccopts=$gccopts" --disable-libada" # unlikely to need ADA!
gccopts=$gccopts" --with-gmp=$HOME --with-mpfr-include=$HOME/mpfr-3.0.0"
gccopts=$gccopts" --with-mpfr-lib=$HOME/mpfr-3.0.0/.libs"
gccopts=$gccopts" --with-mpc=$HOME/mpc-0.9"
$srcdir/configure $gccopts # http://gcc.gnu.org/install/configure.html

because my HOME disk space is too small for GCC and all the things it needs.)

My little test program then compiled but wouldn't run even though the
library said to be missing does exist. It was peresumably put somewhere
that gfortran couldn't find it. What should I do now? Evidence:

rimu[/tmp]$ ls -l */*/libquadmath.so*
lrwxrwxrwx 1 harperj1 harperj1 20 Jan 10 12:35 gf/lib/libquadmath.so -> libquadmath.so.0.0.0
lrwxrwxrwx 1 harperj1 harperj1 20 Jan 10 12:35 gf/lib/libquadmath.so.0 -> libquadmath.so.0.0.0
-rwxr-xr-x 1 harperj1 harperj1 966329 Jan 10 12:35 gf/lib/libquadmath.so.0.0.0
rimu[/tmp]$ cd
rimu[~]$ /tmp/gf/bin/gfortran -v hello.f
Driving: /tmp/gf/bin/gfortran -v hello.f -l gfortran -l m -shared-libgcc
Using built-in specs.
COLLECT_GCC=/tmp/gf/bin/gfortran
COLLECT_LTO_WRAPPER=/tmp/gf/libexec/gcc/i686-pc-linux-gnu/4.6.2/lto-wrapper
Target: i686-pc-linux-gnu
Configured with: /tmp/gcc-4.6.2/configure --prefix=/tmp/gf --enable-languages=c,c++,fortran --disable-libada --with-gmp=/home/harperj1 --with-mpfr-include=/home/harperj1/mpfr-3.0.0 --with-mpfr-lib=/home/harperj1/mpfr-3.0.0/.libs --with-mpc=/home/harperj1/mpc-0.9
Thread model: posix
gcc version 4.6.2 (GCC)
COLLECT_GCC_OPTIONS='-v' '-shared-libgcc' '-mtune=generic' '-march=pentiumpro'
/tmp/gf/libexec/gcc/i686-pc-linux-gnu/4.6.2/f951 hello.f -ffixed-form -quiet -dumpbase hello.f -mtune=generic -march=pentiumpro -auxbase hello -version -fintrinsic-modules-path /tmp/gf/lib/gcc/i686-pc-linux-gnu/4.6.2/finclude -o /tmp/ccDukrje.s
GNU Fortran (GCC) version 4.6.2 (i686-pc-linux-gnu)
compiled by GNU C version 4.6.2, GMP version 4.3.2, MPFR version 3.0.0, MPC version 0.9
GGC heuristics: --param ggc-min-expand=100 --param ggc-min-heapsize=131072
GNU Fortran (GCC) version 4.6.2 (i686-pc-linux-gnu)
compiled by GNU C version 4.6.2, GMP version 4.3.2, MPFR version 3.0.0, MPC version 0.9
GGC heuristics: --param ggc-min-expand=100 --param ggc-min-heapsize=131072
COLLECT_GCC_OPTIONS='-v' '-shared-libgcc' '-mtune=generic' '-march=pentiumpro'
as --32 -o /tmp/ccGzx8Uk.o /tmp/ccDukrje.s
Reading specs from /tmp/gf/lib/gcc/i686-pc-linux-gnu/4.6.2/../../../libgfortran.spec
rename spec lib to liborig
COLLECT_GCC_OPTIONS='-v' '-shared-libgcc' '-mtune=generic' '-march=pentiumpro'
COMPILER_PATH=/tmp/gf/libexec/gcc/i686-pc-linux-gnu/4.6.2/:/tmp/gf/libexec/gcc/i686-pc-linux-gnu/4.6.2/:/tmp/gf/libexec/gcc/i686-pc-linux-gnu/:/tmp/gf/lib/gcc/i686-pc-linux-gnu/4.6.2/:/tmp/gf/lib/gcc/i686-pc-linux-gnu/
LIBRARY_PATH=/tmp/gf/lib/gcc/i686-pc-linux-gnu/4.6.2/:/tmp/gf/lib/gcc/i686-pc-linux-gnu/4.6.2/../../../:/lib/:/usr/lib/
COLLECT_GCC_OPTIONS='-v' '-shared-libgcc' '-mtune=generic' '-march=pentiumpro'
/tmp/gf/libexec/gcc/i686-pc-linux-gnu/4.6.2/collect2 --eh-frame-hdr -m elf_i386 -dynamic-linker /lib/ld-linux.so.2 /usr/lib/crt1.o /usr/lib/crti.o /tmp/gf/lib/gcc/i686-pc-linux-gnu/4.6.2/crtbegin.o -L/tmp/gf/lib/gcc/i686-pc-linux-gnu/4.6.2 -L/tmp/gf/lib/gcc/i686-pc-linux-gnu/4.6.2/../../.. /tmp/ccGzx8Uk.o -lgfortran -lm -lgcc_s -lgcc -lquadmath -lm -lgcc_s -lgcc -lc -lgcc_s -lgcc /tmp/gf/lib/gcc/i686-pc-linux-gnu/4.6.2/crtend.o /usr/lib/crtn.o
rimu[~]$ ./a.out
./a.out: error while loading shared libraries: libquadmath.so.0: cannot open shared object file: No such file or directory
rimu[~]$


-- John Harper, School of Mathematics Statistics and Operations Research
Victoria University, PO Box 600, Wellington 6140, New Zealand
e-mail john.harper@vuw.ac.nz phone (+64)(4)463 5276 fax (+64)(4)463 5045


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]