Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP
Path: utzoo!dciem!nrcaer!cognos!brianc
From: brianc@cognos.uucp (Brian Campbell)
Newsgroups: comp.os.minix
Subject: Compiling under MSC
Message-ID: <1139@cognos.UUCP>
Date: Mon, 20-Jul-87 16:22:09 EDT
Article-I.D.: cognos.1139
Posted: Mon Jul 20 16:22:09 1987
Date-Received: Sat, 25-Jul-87 12:11:22 EDT
Organization: Cognos Incorporated, Ottawa, Canada
Lines: 33


     Has anyone gotten any further with using Microsoft C as a
cross-compiler for Minix?  [Are you there mmason?]  I've gotten as far
as converting all of the PCIX assembly files to a format MASM can
handle; everything else compiled without a hitch.  The problem occurs in
the linking.
     I'm working under 286 Xenix 2.1.3 with the DOS development package
(although I'm not using that -- it looks easier to convert a xenix x.out
format file to a minix a.out format than to convert from a dos
executable).
     While I can get each of fs, kernel and mm to compile and link,
there are problems.  One simple problem was the resolution of a global
variable 'M'.  There is a file 'message.c' that does nothing except
define and export this variable.  The linker I'm using doesn't resolve
references to data properly and doesn't pick up this file.  Is there any
reason why M can't be (or isn't) defined in call.c?  [In the interim I'm
specifically linking in the message.o object file].
     Another problem is with the way the linker combines segments.  I've
got all the segment names right (I think), but the linker always gets
the locations for endtext, enddata and endbss wrong -- they get stuck
somewhere near the end of their segments but not quite at the end.  The
long arithmetic routines seem to get pulled in after the _etext symbol.

     Oh ya, there was some talk about scrolling problems with Hercules
cards somewhere in the distant past.  The only fix I saw for this
problem was to change M_VID_MASK from 0FFF to 1FFF.  I tried this, and
it didn't do the trick (although it did help a little).  I'm using an
Everex Edge (HGA + CGA) that has 64k of RAM.  I tried using masks of
16k, 32k and 64k as well, but none made the problem go away.
-- 
Brian Campbell          uucp: decvax!utzoo!dciem!nrcaer!cognos!brianc
Cognos Incorporated     mail: 3755 Riverside Drive, Ottawa, Ontario, K1G 3N3
(613) 738-1440          fido: sysop@163/8