From 3ef95f0ff99a4bd2f131186d60ad825931832345 Mon Sep 17 00:00:00 2001 From: sthen Date: Wed, 10 Sep 2008 16:47:43 +0000 Subject: [PATCH] Remove workaround for lack of complex number support in libm, bump package. ok martynas@ --- graphics/xfig/Makefile | 4 +- graphics/xfig/patches/patch-w_intersect_c | 68 ----------------------- 2 files changed, 2 insertions(+), 70 deletions(-) delete mode 100644 graphics/xfig/patches/patch-w_intersect_c diff --git a/graphics/xfig/Makefile b/graphics/xfig/Makefile index e868a690708..4d62e680977 100644 --- a/graphics/xfig/Makefile +++ b/graphics/xfig/Makefile @@ -1,10 +1,10 @@ -# $OpenBSD: Makefile,v 1.36 2008/08/26 14:32:20 sthen Exp $ +# $OpenBSD: Makefile,v 1.37 2008/09/10 16:47:43 sthen Exp $ COMMENT= CAD drawing program for X11 VERSION= 3.2.5 DISTNAME= xfig.${VERSION}.full -PKGNAME= xfig-${VERSION} +PKGNAME= xfig-${VERSION}p0 CATEGORIES= graphics x11 HOMEPAGE= http://www.xfig.org/ diff --git a/graphics/xfig/patches/patch-w_intersect_c b/graphics/xfig/patches/patch-w_intersect_c deleted file mode 100644 index edbbd89158e..00000000000 --- a/graphics/xfig/patches/patch-w_intersect_c +++ /dev/null @@ -1,68 +0,0 @@ -$OpenBSD: patch-w_intersect_c,v 1.1 2008/08/26 14:32:20 sthen Exp $ - -Avoid complex math, we don't have it yet. -from Angelo Graziosi on cygwin mailing list. - ---- w_intersect.c.pat.orig Wed Aug 20 11:59:45 2008 -+++ w_intersect.c Wed Aug 20 12:05:26 2008 -@@ -25,7 +25,6 @@ - #include "w_intersect.h" - #include "u_quartic.h" - #include --#include - #undef I - - #define ISET_P1 (1 << 0) -@@ -881,30 +880,34 @@ do_intersect_ellipse_polyline(ecx, ecy, ea, eb, theta, - /* due to roundoff errors, the intersection of tangents to ellipses and - * circles may be slightly complex. this code catches such near misses. - */ -- double complex ix1c; -- double complex iy1c; -- double complex ix2c; -- double complex iy2c; -+ double ix1c_x,ix1c_y; -+ double iy1c_x,iy1c_y; -+ double ix2c_x,ix2c_y; -+ double iy2c_x,iy2c_y; - double x1mag, y1mag; - double x2mag, y2mag; - -- iy1c = ((-X) + (sqrt(-rx) * _Complex_I))/(2.0 * W); -- ix1c = (K * iy1c) + L; -- -- iy2c = ((-X) - (sqrt(-rx) * _Complex_I))/(2.0 * W); -- ix2c = (K * iy2c) + L; -+ iy1c_x = (-X)/(2.0 * W); -+ iy1c_y = sqrt(-rx)/(2.0 * W); -+ ix1c_x = (K * iy1c_x) + L; -+ ix1c_y = (K * iy1c_y) + 0; - -- ix1 = creal(ix1c); -- iy1 = creal(iy1c); -- ix2 = creal(ix2c); -- iy2 = creal(iy2c); -+ iy2c_x = iy1c_x; -+ iy2c_y = -iy1c_y; -+ ix2c_x = (K * iy2c_x) + L; -+ ix2c_y = (K * iy2c_y) + 0; - -- x1mag = hypot(ix1, cimag(ix1c)); -- y1mag = hypot(iy1, cimag(iy1c)); -+ ix1 = ix1c_x; -+ iy1 = iy1c_x; -+ ix2 = ix2c_x; -+ iy2 = iy2c_x; - -- x2mag = hypot(ix2, cimag(ix2c)); -- y2mag = hypot(iy2, cimag(iy2c)); -- -+ x1mag = hypot(ix1, ix1c_y); -+ y1mag = hypot(iy1, iy1c_y); -+ -+ x2mag = hypot(ix2, ix2c_y); -+ y2mag = hypot(iy2, iy2c_y); -+ - if ((1.0 > fabs(ix1) - x1mag) && - (1.0 > fabs(iy1) - y1mag) && - (1.0 > fabs(ix2) - x2mag) &&