This is the mail archive of the
mailing list for the GCC project.
FORTRAN -- LINKING PROGRAMS
- To: gcc at gcc dot gnu dot org
- Subject: FORTRAN -- LINKING PROGRAMS
- From: Bob Kuhn <rmkuhn at yahoo dot com>
- Date: Mon, 25 Sep 2000 10:00:40 -0700 (PDT)
I just obtained G77 and got my first (4 line)
program to work. I have the following higher
1. I tried
g77 fortfile > printfile
I wanted to get my compiler error messages to go
to "printfile". It did not work (i.e. the error
messages continued to go to the screen). Is there
an easy way to get my compiler error messages to
go to a file?
2. Typically when I have used for FORTRAN in the
past and have had large programs with many
subroutines, I have precompiled some of the
programs and link edited combining precompiled
subroutines with the source code of uncompiled
subroutines. My guess is that this is easy to do
with G77 but was unable to find an example in the
documentation. Basically I need two steps:
A. How do I compile source code of a subroutine
to some kind of object code (rather than
creating an executable file)?
B. How to I link edit, combining object code from
multiple subroutines (possibly with the source
code of another subroutine) ?
If would be great if I could get a sketch of a
simple example for doing these two steps.
I have the following lower priority questions:
1. Is it easy to have a subroutine library using
procedures similar to the ones described above?
2. I have combined C and FORTRAN routines in the
past using the ABSOFT PC compiler. Do you have a
simple example showing the link edit steps for
doing this with the GNU compilers? I may which
to go either way (FORTRAN calling C or C calling
Any help on the above matters would be greatly
I would appreciate a brief note acknowledging
receipt of this email.
Do You Yahoo!?
Send instant messages & get email alerts with Yahoo! Messenger.