🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: gnu.gcc.bug
Article #2879

gcc 1.37, sun3 version, and X11R4

#2879
From: Andy Fyfe
Date: Thu, 22 Feb 1990 00:12
25 lines
1365 bytes
It was previously reported that when the X server was compiled on a sun3
with gcc 1.37 it failed to correctly draw wide lines.  The posting pointed
out that if the file server/ddx/mi/miwideline.c was compiled with cc the
problem went away.  As it turns out, the problem is that the function
hypot() is not declared in the function math-68881.h which we include
here when __HAVE_68881__ is defined.  Gcc assumes hypot() returns an int
and bad things happen.  The following patch adds hypot() to math-68881.h.

Two files need to be recompiled, miwideline.c and miarc.c, as both call
hypot().

*** math-68881.h	Wed Feb 14 01:07:28 1990
--- /usr/local/lib/gcc-include/math-68881.h	Wed Feb 21 12:01:32 1990
***************
*** 250,253 ****
--- 250,258 ----
  }
  
+ __inline static const double hypot (const double x, const double y)
+ {
+     return sqrt(x*x + y*y);
+ }
+ 
  __inline static const double pow (const double x, const double y)
  {
Technical Details
Message-ID: <9002220012.AA05757@csvax.caltech.edu>
Path: arc1-ca.pugleaf.net!utzoo!utgpu!jarvis.csri.toronto.edu!cs.utexas.edu!tut.cis.ohio-state.edu!CSVAX.CALTECH.EDU!andy

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!jarvis.csri.toronto.edu!cs.utexas.edu!tut.cis.ohio-state.edu!CSVAX.CALTECH.EDU!andy
From: andy@CSVAX.CALTECH.EDU (Andy Fyfe)
Newsgroups: gnu.gcc.bug
Subject: gcc 1.37, sun3 version, and X11R4
Message-ID: <9002220012.AA05757@csvax.caltech.edu>
Date: 22 Feb 90 00:12:07 GMT
Sender: daemon@tut.cis.ohio-state.edu
Distribution: gnu
Organization: GNUs Not Usenet
Lines: 25