I downloaded the latest release of gfortran from: gcc-11.1.0.tar.xz to a VMware Centos 7 32 bit Virtual Machine.
I was able to build gfortran and run a Fortran hello world program.
When I run my company’s Makefile to build a “complex” Fortran proprietary program, I get the following errors. (Note: xyz, abc.o and rst.o are not the actual identifiers in the output.)
Making xyz
Making xyz1.Linux
Loading xyz1 ...
gfortran -w -u -g -m32 -static xyz.o abc.o rst.o ../../libs/lib1/1.a -lpthread ../../libs/lib1/1.a -lpthread -o xyz
/bin/ld: cannot find -lpthread
/bin/ld: cannot find -lpthread
/bin/ld: cannot find -lgfortran
/bin/ld: cannot find -lm
/bin/ld: cannot find -lquadmath
/bin/ld: cannot find -lm
/bin/ld: cannot find -lc
collect2: error: ld returned 1 exit status
make: *** [PROGRAM] Error 1
I found this in the gfortran directory that I downloaded gfortran to : gcc-11.1.0-32bit/lib/libquadmath.so.0
And, I found these two symbolic links:
cd /bin;ls -laF ld
/bin/ld -> /etc/alternatives/ld*
cd /etc/alternatives;ls -laF ld
/etc/alternatives/ld -> /usr/bin/ld.bfd*
cd ld.bfd
-bash: cd: ld.bfd: No such file or directory
Question: What do I do to compile everything with this Makefile (Fortran program)?
In order to get past a previous Makefile error: I executed the following command because the Makefile couldn’t find the csh:
sudo yum install csh