Thanks, for the clue which solved the problem on the C to Fortran
connection. Looking at the f2c output showed that f2c appends __
a double underscore after the fortran function name. Putting the
c program function call to fortran_function_name__ and:
gcc -c main_prog.c
f77 -c fortran_prog.f   ! g77 also works, and f77 is soft linked to 
                          the fort77 script which calls f2c
gcc -o main_prog.o fortran_prog.o -lf2c -lm

works.

extern "C" float fortran_function_name__(float *v);
int main()
{
}

and then that works too when linked with:
g++ -o prog_name -o main_prog.o fortran_prog.o -lf2c -lm

So thanks again,

Jack Kossler



-- 
  PLEASE read the Red Hat FAQ, Tips, Errata and the MAILING LIST ARCHIVES!
http://www.redhat.com/RedHat-FAQ /RedHat-Errata /RedHat-Tips /mailing-lists
         To unsubscribe: mail [EMAIL PROTECTED] with 
                       "unsubscribe" as the Subject.

Reply via email to