Xref: utzoo comp.lang.pascal:5800 comp.lang.c:37384 Path: utzoo!utgpu!news-server.csri.toronto.edu!rpi!zaphod.mps.ohio-state.edu!uakari.primate.wisc.edu!eng.ufl.edu!gnv.ifas.ufl.edu!sjs From: sjs@gnv.ifas.ufl.edu Newsgroups: comp.lang.pascal,comp.lang.c Subject: Re: C PASCAL INTERFACE Message-ID: <1991Mar21.115923.88@gnv.ifas.ufl.edu> Date: 21 Mar 91 16:59:23 GMT References: <2941@cod.NOSC.MIL> Lines: 25 In article <2941@cod.NOSC.MIL>, vtran@cod.NOSC.MIL (Viet D. Tran) writes: > > I have programs that were written in two different languages, Pascal > and C. Now, I am having trouble combining them together, or linking > them in the compiling process (using either Pascal or C compiler) to > make only one executable file. If anyone knows how to do mixed language > programs with Pascal and C (such as C and In Line Assembly), or has any > other suggestions, please let me know. Thanks. I have no trouble doing this with Microsoft C and Pascal. Just make sure there is only one main program; all the other routine files must be sub- procedures or sub-functions. Also make sure that they are compiled to the same size (compact, small, large, etc.). You left out a lot of info (compilers, op systems, etc.). Try a small program (like MAIN.PAS and a called SUB_FUNC.C) and see what happens. +---------------------------------------------+------------------------------+ | ~~~ Sid Sachs | "Time to wake up! | | / \ ~~~ at the Mountains of Madness | Time to rise!" | | / / \ | | | / / \ Bitnet: sjs@ifasgnv | - Silver Lady, | | / \ Internet: sjs@gnv.ifas.ufl.edu | Intergalactic Touring Band | +---------------------------------------------+------------------------------+