Date: Sun, 23 Mar 2008 16:15:23 GMT From: Hiroki Sato <hrs@FreeBSD.org> To: FreeBSD-gnats-submit@FreeBSD.org Cc: ade@FreeBSD.org Subject: ports/122018: Update port: fix devel/m4 division of negative numbers bug Message-ID: <200803231615.m2NGFNdE071870@freefall.freebsd.org> Resent-Message-ID: <200803231620.m2NGK0sh071910@freefall.freebsd.org>
next in thread | raw e-mail | index | archive | help
>Number: 122018 >Category: ports >Synopsis: Update port: fix devel/m4 division of negative numbers bug >Confidential: no >Severity: serious >Priority: high >Responsible: freebsd-ports-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: change-request >Submitter-Id: current-users >Arrival-Date: Sun Mar 23 16:20:00 UTC 2008 >Closed-Date: >Last-Modified: >Originator: Hiroki Sato >Release: FreeBSD 6.3-PRERELEASE i386 >Organization: Tokyo University of Science >Environment: System: FreeBSD alph.allbsd.org 6.3-PRERELEASE FreeBSD 6.3-PRERELEASE #0: Wed Jan 9 01:39:40 JST 2008 hrs@alph.allbsd.org:/usr/obj/usr/src/sys/ALPH i386 >Description: GNU m4 1.4.9 has a known bug involving division of negative numbers so needs to be updated. This breaks some software which depends on GNU m4 like cad/pcb. 1.4.10 is not the latest version and still has the same bug, but the attached patch should fix it and it works. Although upgrading m4 would be problematic since many software depends on it, the effect from upgrading to 1.4.10 is small enough. This patch to fix the bug has already been submitted to the upstream and accepted. >How-To-Repeat: % echo "eval(-2/2)" | gm4 - 2147483647 >Fix: Index: Makefile =================================================================== RCS file: /home/ncvs/ports/devel/m4/Makefile,v retrieving revision 1.35 diff -d -u -I\$FreeBSD:.*\$ -I\$NetBSD:.*\$ -I\$OpenBSD:.*\$ -I\$DragonFly:.*\$ -I\$Id:.*\$ -I\$Translation:.*\$ -I\$hrs:.*\$ -r1.35 Makefile --- Makefile 30 Sep 2007 20:39:13 -0000 1.35 +++ Makefile 6 Jan 2008 05:28:09 -0000 @@ -6,7 +6,8 @@ # PORTNAME= m4 -PORTVERSION= 1.4.9 +PORTVERSION= 1.4.10 +PORTREVISION= 1 PORTEPOCH= 1 CATEGORIES= devel MASTER_SITES= ${MASTER_SITE_GNU} Index: distinfo =================================================================== RCS file: /home/ncvs/ports/devel/m4/distinfo,v retrieving revision 1.10 diff -d -u -I\$FreeBSD:.*\$ -I\$NetBSD:.*\$ -I\$OpenBSD:.*\$ -I\$DragonFly:.*\$ -I\$Id:.*\$ -I\$Translation:.*\$ -I\$hrs:.*\$ -r1.10 distinfo --- distinfo 30 Sep 2007 20:39:13 -0000 1.10 +++ distinfo 6 Jan 2008 05:28:14 -0000 @@ -1,3 +1,3 @@ -MD5 (m4-1.4.9.tar.bz2) = bcfaf47194491a7a8b8d3c2811570b93 -SHA256 (m4-1.4.9.tar.bz2) = a8e29386374ba0eacbd7b339b97f169603d63a736bd87eee85ed2771ed7c3d29 -SIZE (m4-1.4.9.tar.bz2) = 609666 +MD5 (m4-1.4.10.tar.bz2) = 0a35bab2f5d605e08083d7e3cbd4b8b0 +SHA256 (m4-1.4.10.tar.bz2) = b2b66e645cd566a95d9714848a5d084427f3130ace5c5a0c6cb5544f11b7cbd7 +SIZE (m4-1.4.10.tar.bz2) = 739154 Index: files/patch-src-eval.c =================================================================== RCS file: files/patch-src-eval.c diff -N files/patch-src-eval.c --- /dev/null 1 Jan 1970 00:00:00 -0000 +++ files/patch-src-eval.c 5 Jan 2008 20:08:25 -0000 @@ -0,0 +1,11 @@ +--- src/eval.c.orig 2007-01-09 16:12:43.000000000 +0000 ++++ src/eval.c +@@ -721,7 +721,7 @@ mult_term (eval_token et, int32_t *v1) + /* Avoid the x86 SIGFPE on INT_MIN / -1. */ + *v1 = (int32_t) -(uint32_t) *v1; + else +- *v1 = (int32_t) ((uint32_t) *v1 / (uint32_t) v2); ++ *v1 = *v1 / v2; + break; + + case MODULO: >Release-Note: >Audit-Trail: >Unformatted:
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200803231615.m2NGFNdE071870>