Xref: utzoo comp.sys.att:7205 unix-pc.general:3497 Path: utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!csd4.milw.wisc.edu!bionet!ames!topgun.dspo.gov!lll-winken!gryphon!denwa!srhqla!kosman!kevin From: kevin@kosman.UUCP (Kevin O'Gorman) Newsgroups: comp.sys.att,unix-pc.general Subject: Re: Nethack 3.00 on a Unix PC: assembler complains. Message-ID: <941@kosman.UUCP> Date: 4 Aug 89 14:41:30 GMT References: <1989Jul31.033853.23599@ntvax.uucp> <2151@hub.UUCP> Reply-To: kevin@kosman.UUCP (Root) Followup-To: comp.sys.att Organization: K.O.'s Manor - Vital Computer Systems, Oxnard, CA 93035 Lines: 30 In article <2151@hub.UUCP> todd@ivucsb.sba.ca.us (Todd Day) writes: >In article <1989Jul31.033853.23599@ntvax.uucp> canoaf@ntvax.uucp (Augustine Cano) writes: >~While trying to compile Nethack 3.00 on a 3b1 (67Mb HD/2Mb RAM, 3.51a OS) >~I got the following: >~ >~ cc -O -I../include -c apply.c >~Assembler: apply.c >~aline 359 : branch offset is too remote > >Evidentally, the optimizer is forgetting about how far away some things >are. I got the same problem. Compile as much as you can with the optimizer >(-O flag) and compile the ones that break by hand. In this case, > >cc -I../include -c apply.c > >Nethack is the only program I've ever had do this. Anyone know why this >happens? I think so. The same thing happened to me in compiling the last version of Nethack 2.0. I didn't think to fiddle with -O, but took a good look at what piece of code broke. Anyway, I decided to try undefining the thing that controls whether the compiler is supposed to use bitfields in the struct definitions. When bitfields were no longer being used, everything compiled with -O just fine. This does not explain just what it is that is broken, but it may help explain why the problem shows up so rarely: not many software packages use bitfields, so you won't see this too much.