Subject: re: Bootstrapping pmax ...
To: None <port-pmax@sun-lamp.cs.berkeley.edu>
From: Terry R. Friedrichsen <terry@venus.sunquest.com>
List: port-pmax
Date: 08/04/1994 14:22:30
>> I've rebuilt libkern/qdivrem.o without the ld -x step, to get
>> around a bug in the ultrix ld.

> what bug...i'm using ultrix 4.0

Well, I dunno where the bug actually is, but gcc 2.5.7 + Ultrix v4.3 ld
were unhappy with qdivrem for me.

I fixed the problem by moving the shl() code to the *end* of qdivrem.c, and
adding a forward declaration of shl() before the __qdivrem() function:

   static void shl(register digit *p, register int len, register int sh);

That kept Ultrix ld from choking on qdivrem.o.

This is *entirely* an empirical fix; I have no idea why the problem occurs
or why this fixes it.  I just did random things to the code until it linked
properly.

Terry R. Friedrichsen

terry@venus.sunquest.com  (Internet)
uunet!sunquest!terry      (Usenet)
terry@sds.sdsc.edu        (alternate address; I live in Tucson)

------------------------------------------------------------------------------