home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: comp.lang.modula2
- Path: sparky!uunet!ukma!wupost!sdd.hp.com!ux1.cso.uiuc.edu!mp.cs.niu.edu!uxa.ecn.bgu.edu!mgmam
- From: mgmam@uxa.ecn.bgu.edu (Mark A. Morrell)
- Subject: Re: Linking JPI M2 to MicroSoft C .OBJ
- Message-ID: <BxtKF1.t0@uxa.ecn.bgu.edu>
- Organization: Educational Computing Network
- References: <18376.2B02109B@puddle.fidonet.org>
- Date: Mon, 16 Nov 1992 17:25:49 GMT
- Lines: 47
-
- In article <18376.2B02109B@puddle.fidonet.org> John.Mcmonagle@f590.n139.z1.fidonet.org (John Mcmonagle) writes:
- >
- > MAM> I'm trying to link JPI Modula-2 to an object file which was written with
- > MAM> Microsoft C. I don't have the source to the object file, or anything
- > MAM> useful except the names of the procedures included. I've tried wading
- > MAM> throught the JPI documentation to try to find which pragmas I need in
- > MAM> order to make the link work, but I haven't quite been able to do it. I
- > MAM> was hoping someone out on the nets would be able to help me out.
- >
- >The following is from a definition module that interfaces to a MSC
- >library in the large model.
- >
- >(*# module(implementation=>off, init_code=>off) *)
- >
- >DEFINITION MODULE MW;
- >
- >
- >(*# data(near_ptr => off),
- > call(o_a_copy => off, o_a_size => off, c_conv => on, near_call => off,
- > reg_saved => (si, di, ds, st1, st2), reg_param => ()),
- > name(prefix => c)
- > *)
- >
- >Hope this helps.
- >I'm not really that much of an expert at those pragmas.
- >One other thing that could cause problems is the TopSpeed linker may
- >not like some things in msc obj's, but at least Sean Wilson at the
- >Clarion US office has ways to fix most possible problems. Clarion US
-
- Thanks for the help on this, but I already got that stuff out of the
- developers guide.
-
- I found that the real problem was that even with this stuff, the linker
- wasn't linking in the object code. I had to add the line:
-
- #pragma link(clogin.obj)
-
- to the project file in order to make the linker use the object file. I
- would have thought that having the definition file with the
- implementation=>off (just like you have above) would have done it, but
- you have to TELL it to link the obj. BTW, all of what you have above
- is also correct. Thanks for the effort...
- --
- --------------------------------------------------------------------
- Mark A. Morrell Disclaimer: _I_ probably don't even believe it.
- Literary Reference: The introduction to Cervantes' Don Quixote.
-
-