I have an issue on mac os x El Capitan with Xcode 7. I'm using fortran 6.1, downloaded from https://gcc.gnu.org/wiki/GFortranBinaries. I would like to know how I can run fortran77 codes using fortran.
I have tried
gfortran hello.f77 -o a.out
and got the following error:
ld: warning: ignoring file hello.f77, file was built for unsupported file format ( 0x20 0x70 0x72 0x6F 0x67 0x72 0x61 0x6D 0x20 0x6D 0x61 0x69 0x6E 0x0A 0x0A 0x63 ) which is not the architecture being linked (x86_64): hello.f77 Undefined symbols for architecture x86_64: "_main", referenced from: implicit entry/start for main executable ld: symbol(s) not found for architecture x86_64 collect2: error: ld returned 1 exit status
Please refer:
http://stackoverflow.com/questions/37954802/fortran77-fortran95-compilers
I have tried
gfortran hello.f77 -o a.out
and got the following error:
ld: warning: ignoring file hello.f77, file was built for unsupported file format ( 0x20 0x70 0x72 0x6F 0x67 0x72 0x61 0x6D 0x20 0x6D 0x61 0x69 0x6E 0x0A 0x0A 0x63 ) which is not the architecture being linked (x86_64): hello.f77 Undefined symbols for architecture x86_64: "_main", referenced from: implicit entry/start for main executable ld: symbol(s) not found for architecture x86_64 collect2: error: ld returned 1 exit status
Please refer:
http://stackoverflow.com/questions/37954802/fortran77-fortran95-compilers
Last edited: