home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: comp.sys.mac.programmer
- Path: sparky!uunet!spool.mu.edu!agate!apple!mumbo.apple.com!gallant.apple.com!wintermute.apple.com!user
- From: ksand@apple.com (Kent Sandvik )
- Subject: Re: MPW Linker help needed
- Sender: news@gallant.apple.com
- Message-ID: <ksand-211192234558@wintermute.apple.com>
- Date: Sun, 22 Nov 1992 07:49:22 GMT
- References: <1992Nov17.090523.376@unimur.um.es>
- Organization: Apple
- Followup-To: comp.sys.mac.programmer
- Lines: 39
-
- In article <1992Nov17.090523.376@unimur.um.es>, humberto@unimur.um.es
- (Humberto Martinez) wrote:
- >
- > Hello:
- > I'm trying to compile flex and bison, from GNU, in a Macintosh LC. I
- > can't generate an executable file from the objects ones. My linker gets out
- > of order, and says:
- >
- > Link: Error: Jump Table offset into code segment is greater
- > than 32K (Error 50) .......
-
- Sometimes I wonder how many times I have answered this question.
- It's even now documented in many places (MPW documentation, Tech
- Notes). I guess one problem is that the Segmentation TN is
- brand new, and that the MPW documentation is not out through
- the door yet.
-
- Anyway, you are seeing a typical case where some of your jump
- table entries are pointing beyond the magical 16-bit offset.
-
- The known tricks are to:
- a) Move object files around so that things called from main
- are quite near the Runtime.o file
- b) Even better, use the Link -srtseg, as in:
- -srtsg all|segName # place items referenced through Jump Table low
- in code resource.
-
- This will tell the Link too to place JT entries up to the top with
- branches <32k.
- c) Use the -br branch island Link flag that will create branch
- islands for >32k branches
- d) Use model far support that fixes all problems (32k segments
- including the jump tables and branches).
-
- Cheers,
- Kent
- -------------------
- Kent Sandvik (UUCP: ....!apple!ksand; INTERNET: ksand@apple.com)
- DISCLAIMER: Private activities on the Net.
-