patches/gmp/5.0.1/100-fix-tests-ABI-long-long.patch
changeset 1873 4477403726db
child 1879 b4ce08060b6f
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/patches/gmp/5.0.1/100-fix-tests-ABI-long-long.patch	Tue Mar 30 22:31:49 2010 +0200
     1.3 @@ -0,0 +1,43 @@
     1.4 +
     1.5 +# HG changeset patch
     1.6 +# User Torbjorn Granlund <tege@gmplib.org>
     1.7 +# Date 1267122532 -3600
     1.8 +# Node ID 794410151f5f966bcb5c3489b6441614990efe7c
     1.9 +# Parent  948660e2e56d9cfaae035082b8fd473985505fb6
    1.10 +Fix a test case to work for long long limbs.
    1.11 +
    1.12 +diff -r 948660e2e56d -r 794410151f5f ChangeLog
    1.13 +--- a/ChangeLog	Thu Feb 25 16:08:21 2010 +0100
    1.14 ++++ b/ChangeLog	Thu Feb 25 19:28:52 2010 +0100
    1.15 +@@ -1,5 +1,8 @@
    1.16 + 2010-02-25  Torbjorn Granlund  <tege@gmplib.org>
    1.17 + 
    1.18 ++	* tests/mpz/t-perfpow.c (check_random): Use mp_limb_t type for limb
    1.19 ++	variables.
    1.20 ++
    1.21 + 	* tests/mpn/t-div.c: Cast a switch index to placate HP's cc.
    1.22 + 	* tests/mpn/t-bdiv.c: Likewise.
    1.23 + 
    1.24 +diff -r 948660e2e56d -r 794410151f5f tests/mpz/t-perfpow.c
    1.25 +--- a/tests/mpz/t-perfpow.c	Thu Feb 25 16:08:21 2010 +0100
    1.26 ++++ b/tests/mpz/t-perfpow.c	Thu Feb 25 19:28:52 2010 +0100
    1.27 +@@ -2,7 +2,7 @@
    1.28 + 
    1.29 +    Contributed to the GNU project by Torbjorn Granlund and Martin Boij.
    1.30 + 
    1.31 +-Copyright 2008, 2009 Free Software Foundation, Inc.
    1.32 ++Copyright 2008, 2009, 2010 Free Software Foundation, Inc.
    1.33 + 
    1.34 + This file is part of the GNU MP Library.
    1.35 + 
    1.36 +@@ -109,7 +109,8 @@
    1.37 + {
    1.38 +   mpz_t n, np, temp, primes[NRP];
    1.39 +   int i, j, k, unique, destroy, res;
    1.40 +-  unsigned long int nrprimes, primebits, g, exp[NRP], e;
    1.41 ++  unsigned long int nrprimes, primebits;
    1.42 ++  mp_limb_t g, exp[NRP], e;
    1.43 +   gmp_randstate_ptr rands;
    1.44 + 
    1.45 +   rands = RANDS;
    1.46 +