ports/176653: Add a fix to math/spooles

Pedro Giffuni giffunip at tutopia.com
Tue Mar 5 03:10:01 UTC 2013


>Number:         176653
>Category:       ports
>Synopsis:       Add a fix to math/spooles
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-ports-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          change-request
>Submitter-Id:   current-users
>Arrival-Date:   Tue Mar 05 03:10:00 UTC 2013
>Closed-Date:
>Last-Modified:
>Originator:     Pedro Giffuni
>Release:        9.1-PRERELEASE
>Organization:
>Environment:
FreeBSD pcbsd-8555 9.1-PRERELEASE FreeBSD 9.1-PRERELEASE #7: Sun Oct  7 00:05:03 COT 2012     Pedro at pcbsd-8555:/usr/src/sys/amd64/compile/GENERIC  amd64

>Description:
The CalculiX package includes a correction to SPOOLES.2.2 for large input decks:

http://www.dhondt.de/ccx_2.5.SPOOLEScorrection.tar.bz2

I added a patch to our spooles and while here updated the WWW URL to one that works.
>How-To-Repeat:

>Fix:


Patch attached with submission follows:

Index: spooles/files/patch-I2Ohash-large-input
===================================================================
--- spooles/files/patch-I2Ohash-large-input	(revision 0)
+++ spooles/files/patch-I2Ohash-large-input	(working copy)
@@ -0,0 +1,49 @@
+--- I2Ohash/src/util.c.orig	2013-03-04 21:21:54.000000000 -0500
++++ I2Ohash/src/util.c	2012-10-06 08:28:37.000000000 -0500
+@@ -39,8 +39,9 @@
+ */
+ loc1 = (key1 + 1) % hashtable->nlist ;
+ loc2 = (key2 + 1) % hashtable->nlist ;
+-long int loc3 = (long int)loc1*(long int)loc2 % hashtable->nlist ;
+-loc =(int) loc3;
++/*loc  = (loc1*loc2) % hashtable->nlist ;*/
++long int loc3  = (long int)loc1*(long int)loc2 % hashtable->nlist ;
++loc=(int)loc3;
+ #if MYDEBUG > 0
+ fprintf(stdout, "\n loc1 = %d, loc2 = %d, loc3 = %d", loc1, loc2, loc) ;
+ fflush(stdout) ;
+@@ -51,7 +52,7 @@
+    --------------------------------------------------------
+ */
+ #if MYDEBUG > 0
+-fprintf(stdout, "\n loc1 = %d, loc2 = %d, loc3 = %ld, loc = %d", loc1, loc2, loc3, loc) ;
++fprintf(stdout, "\n hashtable->freeI2OP = %p", hashtable->freeI2OP) ;
+ fflush(stdout) ;
+ #endif
+ if ( (i2op = hashtable->freeI2OP) == NULL ) {
+@@ -159,10 +160,11 @@
+ #endif
+ loc1 = (key1 + 1) % hashtable->nlist ;
+ loc2 = (key2 + 1) % hashtable->nlist ;
+-long int loc3 = (long int)loc1*(long int)loc2 % hashtable->nlist ;
+-loc =(int) loc3;
++/*loc  = (loc1*loc2) % hashtable->nlist ;*/
++long int loc3  = (long int)loc1*(long int)loc2 % hashtable->nlist ;
++loc=(int)loc3;
+ #if MYDEBUG > 0
+-fprintf(stdout, "\n loc1 = %d, loc2 = %d, loc3 = %ld, loc = %d", loc1, loc2, loc3, loc) ;
++fprintf(stdout, "\n loc1 = %d, loc2 = %d, loc3 = %d", loc1, loc2, loc) ;
+ fflush(stdout) ;
+ #endif
+ /*
+@@ -231,7 +233,9 @@
+ }
+ loc1 = (key1 + 1) % hashtable->nlist ;
+ loc2 = (key2 + 1) % hashtable->nlist ;
+-loc  = (loc1*loc2) % hashtable->nlist ;
++/*loc  = (loc1*loc2) % hashtable->nlist ;*/
++long int loc3  = (long int)loc1*(long int)loc2 % hashtable->nlist ;
++loc=(int)loc3;
+ /*
+    ---------------------------------------------------
+    find the location of the first (key1,key2,*) triple
Index: spooles/pkg-descr
===================================================================
--- spooles/pkg-descr	(revision 313418)
+++ spooles/pkg-descr	(working copy)
@@ -17,4 +17,4 @@
        methods. The preconditioner is a drop tolerance factorization,
        with or without pivoting for stability.
 
-WWW:	http://www.spooles.org/
+WWW:	http://www.netlib.org/linalg/spooles/spooles.2.2.html


>Release-Note:
>Audit-Trail:
>Unformatted:


More information about the freebsd-ports-bugs mailing list