Path: utzoo!utgpu!news-server.csri.toronto.edu!rpi!zaphod.mps.ohio-state.edu!sdd.hp.com!spool.mu.edu!snorkelwacker.mit.edu!thunder.mcrcim.mcgill.edu!mouse From: mouse@thunder.mcrcim.mcgill.edu (der Mouse) Newsgroups: comp.lang.c Subject: Re: How to call a fortran subroutine in a C program? Message-ID: <1991Mar27.101251.20053@thunder.mcrcim.mcgill.edu> Date: 27 Mar 91 10:12:51 GMT Article-I.D.: thunder.1991Mar27.101251.20053 References: <2774@pacific.mps.ohio-state.edu> Organization: McGill Research Centre for Intelligent Machines Lines: 24 In article <2774@pacific.mps.ohio-state.edu>, sun@pacific.mps.ohio-state.edu (Mingqiu Sun) writes: > This question is probably asked before. Yup :-) > Is there an easy way to call a subroutine written in fortran by a C > program? Maybe. This is entirely dependent on your compiler and system. Some make it trivial, some make it impossible, and I'm sure there are many variations in between. > I need only to know how to do it in a UNIX environment. Most UNIX environments with FORTRAN (an environment without C can hardly be called UNIX) provide some way to interface between C an FORTRAN. Check your FORTRAN manual; that's usually the place to find such information. der Mouse old: mcgill-vision!mouse new: mouse@larry.mcrcim.mcgill.edu