ports/92658: [PATCH] sysutils/heirloom: [Unbreak AMD64 build]

Jeffrey H. Johnson CPE1704TKS at bellsouth.net
Wed Feb 1 14:44:58 PST 2006


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 at bellsouth.net


More information about the freebsd-ports mailing list