GNU bug report logs - #12741
build: cross-compiling: any cross-compile fails due to new

Previous Next

Package: coreutils;

Reported by: Jim Meyering <jim <at> meyering.net>

Date: Fri, 26 Oct 2012 15:40:02 UTC

Severity: normal

Tags: fixed

Merged with 78377

Done: Assaf Gordon <assafgordon <at> gmail.com>

Bug is archived. No further changes may be made.

Full log


Message #8 received at 12741 <at> debbugs.gnu.org (full text, mbox):

From: Paul Eggert <eggert <at> cs.ucla.edu>
To: Jim Meyering <jim <at> meyering.net>
Cc: 12741 <at> debbugs.gnu.org, yegorslists <at> googlemail.com
Subject: Re: bug#12741: any cross-compile fails due to new make-prime-list
Date: Fri, 26 Oct 2012 10:07:18 -0700
On 10/26/2012 08:37 AM, Jim Meyering wrote:
> I would like to generate that table with a portable awk script (maybe
> even Perl).  If someone can provide such a script, I would be happy
> to dump the C program.  That would solve the problem.

It'd be a pain to do it in portable awk, as it requires
arithmetic modulo (UINTMAX_MAX + 1), which Awk is not
likely to support directly.

Since there are only two or three plausible values of UINTMAX_MAX
these days, one possibility is to precompute primes.h for these
two or three values, and ship the precomputed primes.h in the
tarball, and to use the precomputed primes.h on hosts with typical
UINTMAX_MAX values.  People who are on a weird platform where
UINTMAX_MAX is an unusual value wouldn't be able to cross-compile,
but that's unlikely to ever happen and even if it does, we simply
add the unusual case to the precomputed primes.h.




This bug report was last modified today.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.