[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: ports/92658: [PATCH] sysutils/heirloom: [Unbreak AMD64 build]
The following reply was made to PR ports/92658; it has been noted by GNATS.
From: "Jeffrey H. Johnson" <CPE1704TKS@xxxxxxxxxxxxx>
To: Larry Rosenman <ler@xxxxxxxxxx>, FreeBSD-gnats-submit@xxxxxxxxxxx
Cc: kris@xxxxxxxxxxxxxx, mnag@xxxxxxxxxxx, ports@xxxxxxxxxxx,
ports-amd64@xxxxxxxxxxx, CPE1704TKS@xxxxxxxxxxxxx
Subject: Re: ports/92658: [PATCH] sysutils/heirloom: [Unbreak AMD64 build]
Date: Wed, 01 Feb 2006 17:41:58 -0500
OK, I have an update here:
-----------------------------------
--- spell/spellin.c.orig Wed Feb 1 23:34:58 2006
+++ spell/spellin.c Wed Feb 1 23:27:02 2006
@@ -103,7 +103,7 @@
z = huff((1L<<HASHWIDTH)/atof(argv[1]));
fprintf(stderr, "%s: expected code widths = %f\n",
argv[0], z);
- for (count = 0; scanf("%lo", (long *)&h) == 1; ++count) {
+ for (count = 0; scanf("%o", (long *)&h) == 1; ++count) {
if ((t = h >> (HASHWIDTH - INDEXWIDTH)) != u) {
if (bp != B)
wp++;
-----------------------------------
This should work on all architectures where int32_t is the same size
as int, which I *believe* should cover all current FreeBSD platforms.
If someone has a better solution, I'd be glad to hear it. I'm also
puzzled as to why this seems to work on pointyhat without the
modifications but I don't have access to AMD64 running 5 to examine.
If someone who knows what they are doing can apply a more proper fix,
please do. :p
--
Jeffrey H. Johnson
CPE1704TKS@xxxxxxxxxxxxx