gfortran and fedeas code

For developers writing C++, Fortran, Java, code who have questions or comments to make.

Moderators: silvia, selimgunay, Moderators

Post Reply
aneeman
Posts: 90
Joined: Thu Jan 12, 2006 1:13 pm
Contact:

gfortran and fedeas code

Post by aneeman »

Hi,

I am trying to compile the fedeas & drain code and I have the gfortran compiler (g77 is no longer default). Is anyone having any luck with this? I got a bit further using

gforttran -ffree-form

but still have problems with some of the drain .f files.

peace,
alisa
fmk
Site Admin
Posts: 5884
Joined: Fri Jun 11, 2004 2:33 pm
Location: UC Berkeley
Contact:

Post by fmk »

i am downloading and building gcc4.1.1 now .. will post when i get it built and will post the Makefile.def I use in MAKES.
aneeman
Posts: 90
Joined: Thu Jan 12, 2006 1:13 pm
Contact:

Post by aneeman »

OK, good luck. I found it choking on:

a) 'c' comments (it will accept '!' )

b) lines that wrap - it can't seem to figure that out, even with a character in the 6th
column to give a hint.

alisa
aneeman
Posts: 90
Joined: Thu Jan 12, 2006 1:13 pm
Contact:

gfortran - not quite ready for primetime

Post by aneeman »

OK, I was able to workaround by running f2c on the fedeas and drain files.

Other things I had to do to make it go because of that:
I added some things to CFLAGS becuase of it:
-L$(HOME)/srcf2c/libf2c/libf2c.a \
-lf2c -I$(HOME)/srcf2c/libf2c

And I changed -lg2c to -lgfortran here:

MACHINE_NUMERICAL_LIBS = -lm -lgfortran \

which is needed to make the lapack stuff compile.
fmk
Site Admin
Posts: 5884
Joined: Fri Jun 11, 2004 2:33 pm
Location: UC Berkeley
Contact:

Post by fmk »

i can't find the problem with the original files.

i have downloaded gcc-4.1.1, both gcc and gfortran bzipped tarballs.

configured with

./configure --enable-languages=all --disable-shared

modified the Makefile.def

CC++ = /usr/local/bin/g++
CC = /usr/local/bin/gcc
FC = /usr/local/bin/gfortran

and added the -lgfortran to list of libs.

(the modified Makefile.def, I have placed in MAKES/Makefile.def.gcc4.1.1)

I have checked out a new version of OpenSees, compiled and linked and no problems
aneeman
Posts: 90
Joined: Thu Jan 12, 2006 1:13 pm
Contact:

gfortran

Post by aneeman »

Thanks, Frank. It must be my version (4.1.0)
Will try the upgrade.
Post Reply