[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

rpms/gmp/FC-6 mpfr-2.2.0-cumulative.patch, NONE, 1.1 .cvsignore, 1.10, 1.11 gmp.spec, 1.30, 1.31 sources, 1.10, 1.11



Author: jakub

Update of /cvs/dist/rpms/gmp/FC-6
In directory cvs.devel.redhat.com:/tmp/cvs-serv12202/FC-6

Modified Files:
	.cvsignore gmp.spec sources 
Added Files:
	mpfr-2.2.0-cumulative.patch 
Log Message:
auto-import gmp-4.1.4-7.fc6 on branch FC-6 from gmp-4.1.4-7.fc6.src.rpm

mpfr-2.2.0-cumulative.patch:
 mpfr-2.2.0-p1/lngamma.c        |    4 
 mpfr-2.2.0-p1/tests/tlngamma.c |   10 +-
 mpfr-2.2.0-p10/asin.c          |    2 
 mpfr-2.2.0-p10/asinh.c         |    2 
 mpfr-2.2.0-p10/atan.c          |    2 
 mpfr-2.2.0-p10/atanh.c         |    2 
 mpfr-2.2.0-p10/expm1.c         |    2 
 mpfr-2.2.0-p10/log1p.c         |    2 
 mpfr-2.2.0-p10/sin.c           |    2 
 mpfr-2.2.0-p10/sinh.c          |    2 
 mpfr-2.2.0-p10/tan.c           |    2 
 mpfr-2.2.0-p10/tanh.c          |    2 
 mpfr-2.2.0-p10/zeta.c          |    2 
 mpfr-2.2.0-p11/configure       |  101 ---------------------
 mpfr-2.2.0-p11/configure.in    |    6 -
 mpfr-2.2.0-p11/div.c           |   54 ++++++-----
 mpfr-2.2.0-p11/mpfr-gmp.c      |   15 ---
 mpfr-2.2.0-p11/mpfr-impl.h     |    9 -
 mpfr-2.2.0-p12/get_f.c         |   42 ++++++---
 mpfr-2.2.0-p12/tests/tget_f.c  |   87 ++++++++++++++++++
 mpfr-2.2.0-p13/configure       |    8 -
 mpfr-2.2.0-p13/configure.in    |    8 -
 mpfr-2.2.0-p14/acinclude.m4    |   18 +++
 mpfr-2.2.0-p14/configure       |   75 ++++++++++++++++
 mpfr-2.2.0-p14/configure.in    |   14 +++
 mpfr-2.2.0-p15/add1.c          |    2 
 mpfr-2.2.0-p15/add1sp.c        |    2 
 mpfr-2.2.0-p15/exceptions.c    |    2 
 mpfr-2.2.0-p15/exp.c           |    2 
 mpfr-2.2.0-p15/exp2.c          |  104 ++++++++++++----------
 mpfr-2.2.0-p15/expm1.c         |   42 ++++++++-
 mpfr-2.2.0-p15/lngamma.c       |   13 +-
 mpfr-2.2.0-p15/log1p.c         |   13 ++
 mpfr-2.2.0-p15/mpfr-impl.h     |    3 
 mpfr-2.2.0-p15/mul.c           |    4 
 mpfr-2.2.0-p15/sub1.c          |    8 -
 mpfr-2.2.0-p15/sub1sp.c        |    4 
 mpfr-2.2.0-p15/tests/tests.c   |    9 +
 mpfr-2.2.0-p15/tests/texp2.c   |   96 ++++++++++++++++++++
 mpfr-2.2.0-p15/tests/tlog1p.c  |   28 ++++++
 mpfr-2.2.0-p16/tests/texp2.c   |   29 +++---
 mpfr-2.2.0-p2/mpfr.h           |   11 +-
 mpfr-2.2.0-p2/tests/tset_si.c  |   30 ++++++
 mpfr-2.2.0-p3/configure        |    2 
 mpfr-2.2.0-p4/tests/tpow.c     |    3 
 mpfr-2.2.0-p5/cache.c          |   86 +++++++++---------
 mpfr-2.2.0-p5/hypot.c          |   24 ++++-
 mpfr-2.2.0-p5/mpfr-impl.h      |  190 +++++++++++++++--------------------------
 mpfr-2.2.0-p5/mpfr.h           |   13 --
 mpfr-2.2.0-p5/round_near_x.c   |   31 +++---
 mpfr-2.2.0-p5/tests/thypot.c   |   21 ++++
 mpfr-2.2.0-p6/div.c            |    9 -
 mpfr-2.2.0-p7/sin.c            |   18 +--
 mpfr-2.2.0-p8/get_f.c          |   35 +++----
 mpfr-2.2.0-p8/set_f.c          |   21 +++-
 mpfr-2.2.0-p8/tests/tget_f.c   |   51 +++++++++--
 mpfr-2.2.0-p8/tests/tset_f.c   |   48 +++++++++-
 mpfr-2.2.0-p9/random2.c        |    5 -
 mpfr-2.2.0-p9/tests/trandom.c  |    7 +
 59 files changed, 914 insertions(+), 525 deletions(-)

--- NEW FILE mpfr-2.2.0-cumulative.patch ---
diff -Naurd mpfr-2.2.0/lngamma.c mpfr-2.2.0-p1/lngamma.c
--- mpfr-2.2.0/lngamma.c	2005-09-09 15:17:58.000000000 +0000
+++ mpfr-2.2.0-p1/lngamma.c	2005-09-29 11:27:04.000000000 +0000
@@ -167,8 +167,8 @@
   compared = mpfr_cmp_ui (z0, 1);
 
 #ifndef IS_GAMMA
-  if (compared == 0) /* lngamma(1) = +0 */
-    return mpfr_set_ui (y, 0, GMP_RNDN);
+  if (compared == 0 || (compared > 0 && mpfr_cmp_ui (z0, 2) == 0))
+    return mpfr_set_ui (y, 0, GMP_RNDN);  /* lngamma(1 or 2) = +0 */
 #endif
 
   mpfr_init2 (s, MPFR_PREC_MIN);
diff -Naurd mpfr-2.2.0/tests/tlngamma.c mpfr-2.2.0-p1/tests/tlngamma.c
--- mpfr-2.2.0/tests/tlngamma.c	2005-09-09 15:17:59.000000000 +0000
+++ mpfr-2.2.0-p1/tests/tlngamma.c	2005-09-29 11:20:34.000000000 +0000
@@ -79,7 +79,7 @@
 
   mpfr_set_ui (x, 1, GMP_RNDN);
   mpfr_lngamma (y, x, GMP_RNDN);
-  if (mpfr_cmp_ui (y, 0))
+  if (mpfr_cmp_ui (y, 0) || MPFR_IS_NEG (y))
     {
       printf ("Error for lngamma(1)\n");
       exit (1);
@@ -93,6 +93,14 @@
       exit (1);
     }
 
+  mpfr_set_ui (x, 2, GMP_RNDN);
+  mpfr_lngamma (y, x, GMP_RNDN);
+  if (mpfr_cmp_ui (y, 0) || MPFR_IS_NEG (y))
+    {
+      printf ("Error for lngamma(2)\n");
+      exit (1);
+    }
+
   mpfr_set_prec (x, 53);
   mpfr_set_prec (y, 53);
 
diff -Naurd mpfr-2.2.0-p1/mpfr.h mpfr-2.2.0-p2/mpfr.h
--- mpfr-2.2.0-p1/mpfr.h	2005-09-06 15:02:12.000000000 +0000
+++ mpfr-2.2.0-p2/mpfr.h	2005-09-29 11:36:36.000000000 +0000
@@ -630,12 +630,17 @@
  (__builtin_constant_p (_s) && (_s) >= 0 ? \
    mpfr_cmp_ui ((_f), (_s)) :              \
    mpfr_cmp_si_2exp ((_f), (_s), 0))
+#if __GNUC__ > 2 || __GNUC_MINOR__ >= 95
 #undef mpfr_set_ui
 #define mpfr_set_ui(_f,_u,_r)              \
  (__builtin_constant_p (_u) && (_u) == 0 ? \
-   ((_f)->_mpfr_sign = 1,                  \
-    (_f)->_mpfr_exp = __MPFR_EXP_ZERO, 0): \
-    mpfr_set_ui (_f,_u,_r))
+   __extension__ ({                        \
+     mpfr_ptr _p = (_f);                   \
+     _p->_mpfr_sign = 1;                   \
+     _p->_mpfr_exp = __MPFR_EXP_ZERO;      \
+     (void) (_r); 0; }) :                  \
+   mpfr_set_ui (_f,_u,_r))
+#endif
 #undef mpfr_set_si
 #define mpfr_set_si(_f,_s,_r)              \
  (__builtin_constant_p (_s) && (_s) >= 0 ? \
diff -Naurd mpfr-2.2.0-p1/tests/tset_si.c mpfr-2.2.0-p2/tests/tset_si.c
--- mpfr-2.2.0-p1/tests/tset_si.c	2005-08-18 17:03:17.000000000 +0000
+++ mpfr-2.2.0-p2/tests/tset_si.c	2005-09-29 09:19:39.000000000 +0000
@@ -72,6 +72,35 @@
   mpfr_clear (x);
 }
 
+static void
+test_macros (void)
+{
+  mpfr_t x[3];
+  mpfr_ptr p;
+  mpfr_rnd_t r;
+
+  mpfr_inits (x[0], x[1], x[2], NULL);
+  p = x[0];
+  r = 0;
+  mpfr_set_ui (p++, 0, r++);
+  if (p != x[1] || r != 1)
+    {
+      printf ("Error in mpfr_set_ui macro: p - x[0] = %d (expecting 1), "
+              "r = %d (expecting 1)\n", (int) (p - x[0]), r);
+      exit (1);
+    }
+  p = x[0];
+  r = 0;
+  mpfr_set_si (p++, 0, r++);
+  if (p != x[1] || r != 1)
+    {
+      printf ("Error in mpfr_set_si macro: p - x[0] = %d (expecting 1), "
+              "r = %d (expecting 1)\n", (int) (p - x[0]), r);
+      exit (1);
+    }
+  mpfr_clears (x[0], x[1], x[2], NULL);
+}
+
 /* FIXME: Comparing against mpfr_get_si/ui is not ideal, it'd be better to
    have all tests examine the bits in mpfr_t for what should come out.  */
 
@@ -324,6 +353,7 @@
   mpfr_clear (x);
 
   test_2exp ();
+  test_macros ();
   tests_end_mpfr ();
   return 0;
 }
diff -Naurd mpfr-2.2.0-p2/configure mpfr-2.2.0-p3/configure
--- mpfr-2.2.0-p2/configure	2005-09-19 13:31:58.000000000 +0000
+++ mpfr-2.2.0-p3/configure	2005-10-02 10:49:55.000000000 +0000
@@ -10519,7 +10519,7 @@
       ;;
 
     darwin* | rhapsody*)
-    if test "$GXX" = yes ; then
+    if test "$GCC" = yes ; then
       archive_cmds_need_lc=no
       case "$host_os" in
       rhapsody* | darwin1.[012])
diff -Naurd mpfr-2.2.0-p3/tests/tpow.c mpfr-2.2.0-p4/tests/tpow.c
--- mpfr-2.2.0-p3/tests/tpow.c	2005-06-02 16:12:05.000000000 +0000
+++ mpfr-2.2.0-p4/tests/tpow.c	2005-10-06 09:54:52.000000000 +0000
@@ -509,6 +509,7 @@
   for (i = 0; i < 11; i++)
     for (j = 0; j < 11; j++)
       {
+        double d;
         int p;
         static int q[11][11] = {
           /*          NaN +inf -inf  +0   -0   +1   -1   +2   -2  +0.5 -0.5 */
@@ -527,7 +528,7 @@
         test_pow (r, t[i], t[j], GMP_RNDN);
         p = mpfr_nan_p (r) ? 0 : mpfr_inf_p (r) ? 1 :
           mpfr_cmp_ui (r, 0) == 0 ? 2 :
-          (int) (fabs (mpfr_get_d (r, GMP_RNDN)) * 128.0);
+          (d = mpfr_get_d (r, GMP_RNDN), (int) (ABS(d) * 128.0));
         if (p != 0 && MPFR_SIGN(r) < 0)
           p = -p;
         if (p != q[i][j])
diff -Naurd mpfr-2.2.0-p4/cache.c mpfr-2.2.0-p5/cache.c
--- mpfr-2.2.0-p4/cache.c	2005-08-18 16:35:03.000000000 +0000
+++ mpfr-2.2.0-p5/cache.c	2005-11-23 09:04:29.000000000 +0000
@@ -32,9 +32,9 @@
 void
 mpfr_clear_cache (mpfr_cache_t cache)
 {
-  if (MPFR_PREC(cache->x) != 0)
+  if (MPFR_PREC (cache->x) != 0)
     mpfr_clear (cache->x);
-  MPFR_PREC(cache->x) = 0;
+  MPFR_PREC (cache->x) = 0;
 }
 
 int
@@ -47,45 +47,58 @@
 
   MPFR_SAVE_EXPO_MARK (expo);
 
-  /* Check if the cache has been already filled */
-  if (MPFR_UNLIKELY(pold == 0))
-    mpfr_init2 (cache->x, prec);
+  if (MPFR_UNLIKELY (prec > pold))
+    {
+      /* No previous result in the cache or the precision of the
+         previous result is not sufficient. */
 
-  /* Check if we can round with the previous result */
-  else if (MPFR_LIKELY(prec <= pold))
-    goto round;
+      if (MPFR_UNLIKELY (pold == 0))  /* No previous result. */
+        mpfr_init2 (cache->x, prec);
 
-  /* Update the cache */
-  pold = prec /*MPFR_PREC_MIN + prec + __gmpfr_ceil_exp2 (prec)*/;
-  MPFR_ASSERTD (pold >= prec);
-  mpfr_prec_round (cache->x, pold, GMP_RNDN);
-  cache->inexact = (*cache->func) (cache->x, GMP_RNDN);
+      /* Update the cache. */
+      pold = prec;
+      mpfr_prec_round (cache->x, pold, GMP_RNDN);
+      cache->inexact = (*cache->func) (cache->x, GMP_RNDN);
+    }
 
- round:
-  /* First check if the cache has the exact value (Unlikely)
-     Else the exact value is between (assuming x=cache->x > 0)
-     x and x+ulp(x) if cache->inexact < 0
-     x-ulp(x) and x if cache->inexact > 0
-     and abs(x-exact) <= ulp(x)/2 */
-  MPFR_ASSERTD (MPFR_IS_POS(cache->x)); /* TODO...*/
-  /* We must use nextbelow instead of sub_one_ulp, since we know
-     that the exact value is < 1/2ulp(x) (We want sub_demi_ulp(x)).
-     Can't use mpfr_set since we need the even flag. */
+  /* First, check if the cache has the exact value (unlikely).
[...2225 lines suppressed...]
+      mpfr_init2 (y, 8);
+      mpfr_set_si (x, mpfr_get_emax (), GMP_RNDN);
+
+      mpfr_clear_flags ();
+      inex = mpfr_exp2 (y, x, GMP_RNDN);
+      ov = mpfr_overflow_p ();
+      if (!ov || !mpfr_inf_p (y) || inex <= 0)
+        {
+          printf ("Overflow error for x = emax, GMP_RNDN.\n");
+          mpfr_dump (y);
+          printf ("inex = %d, %soverflow\n", inex, ov ? "" : "no ");
+          exit (1);
+        }
+
+      mpfr_nextbelow (x);
+
+      mpfr_clear_flags ();
+      inex = mpfr_exp2 (y, x, GMP_RNDN);
+      ov = mpfr_overflow_p ();
+      if (!ov || !mpfr_inf_p (y) || inex <= 0)
+        {
+          printf ("Overflow error for x = emax - eps, GMP_RNDN.\n");
+          mpfr_dump (y);
+          printf ("inex = %d, %soverflow\n", inex, ov ? "" : "no ");
+          exit (1);
+        }
+
+      mpfr_clear_flags ();
+      inex = mpfr_exp2 (y, x, GMP_RNDD);
+      ov = mpfr_overflow_p ();
+      if (ov || mpfr_inf_p (y) || inex >= 0 ||
+          (mpfr_nextabove (y), !mpfr_inf_p (y)))
+        {
+          printf ("Overflow error for x = emax - eps, GMP_RNDD.\n");
+          mpfr_dump (y);
+          printf ("inex = %d, %soverflow\n", inex, ov ? "" : "no ");
+          exit (1);
+        }
+
+      mpfr_clear (x);
+      mpfr_clear (y);
+    }
+}
+
+static void
+exp_range (void)
+{
+  mpfr_t x;
+
+  set_emin (3);
+  mpfr_init2 (x, 8);
+  mpfr_set_ui (x, 5, GMP_RNDN);
+  mpfr_exp2 (x, x, GMP_RNDN);
+  set_emin (MPFR_EMIN_MIN);
+  if (mpfr_nan_p (x) || mpfr_cmp_ui (x, 32) != 0)
+    {
+      printf ("Error in mpfr_exp2 for x = 5, with emin = 3\n");
+      printf ("Expected 32, got ");
+      mpfr_out_str (stdout, 2, 0, x, GMP_RNDN);
+      printf ("\n");
+      exit (1);
+    }
+  mpfr_clear (x);
+}
+
 int
 main (int argc, char *argv[])
 {
@@ -63,6 +140,8 @@
   tests_start_mpfr ();
 
   special_overflow ();
+  emax_m_eps ();
+  exp_range ();
 
   mpfr_init (x);
   mpfr_init (y);
@@ -154,6 +233,17 @@
       exit (1);
     }
 
+  mpfr_set_prec (x, 40);
+  mpfr_set_prec (y, 40);
+  mpfr_set_str (x, "10000000000.5", 10, GMP_RNDN);
+  mpfr_clear_flags ();
+  mpfr_exp2 (y, x, GMP_RNDN);
+  if (!(MPFR_IS_INF (y) && MPFR_IS_POS (y) && mpfr_overflow_p ()))
+    {
+      printf ("exp2(10000000000.5) should overflow.\n");
+      exit (1);
+    }
+
   test_generic (2, 100, 100);
 
   mpfr_clear (x);
diff -Naurd mpfr-2.2.0-p14/tests/tlog1p.c mpfr-2.2.0-p15/tests/tlog1p.c
--- mpfr-2.2.0-p14/tests/tlog1p.c	2005-08-18 17:03:16.000000000 +0000
+++ mpfr-2.2.0-p15/tests/tlog1p.c	2006-08-23 13:17:45.000000000 +0000
@@ -88,12 +88,40 @@
   mpfr_clear (x);
 }
 
+static void
+other (void)
+{
+  mpfr_t x, y;
+
+  /* Bug reported by Guillaume Melquiond on 2006-08-14. */
+  mpfr_init2 (x, 53);
+  mpfr_set_str (x, "-1 5e4f72873ed9a -100", 16, GMP_RNDN);
+  mpfr_init2 (y, 57);
+  mpfr_log1p (y, x, GMP_RNDU);
+  if (mpfr_cmp (x, y) != 0)
+    {
+      printf ("Error in tlog1p for x = ");
+      mpfr_out_str (stdout, 16, 0, x, GMP_RNDN);
+      printf (", rnd = GMP_RNDU\nExpected ");
+      mpfr_out_str (stdout, 16, 15, x, GMP_RNDN);
+      printf ("\nGot      ");
+      mpfr_out_str (stdout, 16, 15, y, GMP_RNDN);
+      printf ("\n");
+      exit (1);
+    }
+
+  mpfr_clear (y);
+  mpfr_clear (x);
+  return;
+}
+
 int
 main (int argc, char *argv[])
 {
   tests_start_mpfr ();
 
   special ();
+  other ();
 
   test_generic (2, 100, 50);
 
diff -Naurd mpfr-2.2.0-p15/tests/texp2.c mpfr-2.2.0-p16/tests/texp2.c
--- mpfr-2.2.0-p15/tests/texp2.c	2006-08-23 13:17:45.000000000 +0000
+++ mpfr-2.2.0-p16/tests/texp2.c	2006-08-28 12:11:36.000000000 +0000
@@ -34,6 +34,10 @@
 {
   mpfr_t x, y;
   int inex;
+  mp_exp_t emin, emax;
+
+  emin = mpfr_get_emin ();
+  emax = mpfr_get_emax ();
 
   set_emin (-125);
   set_emax (128);
@@ -53,8 +57,8 @@
 
   mpfr_clear (y);
   mpfr_clear (x);
-  set_emin (MPFR_EMIN_MIN);
-  set_emax (MPFR_EMAX_MAX);
+  set_emin (emin);
+  set_emax (emax);
 }
 
 static void
@@ -65,7 +69,7 @@
       mpfr_t x, y;
       int inex, ov;
 
-      mpfr_init2 (x, 64);
+      mpfr_init2 (x, sizeof(mp_exp_t) * CHAR_BIT * 4);
       mpfr_init2 (y, 8);
       mpfr_set_si (x, mpfr_get_emax (), GMP_RNDN);
 
@@ -233,15 +237,18 @@
       exit (1);
     }
 
-  mpfr_set_prec (x, 40);
-  mpfr_set_prec (y, 40);
-  mpfr_set_str (x, "10000000000.5", 10, GMP_RNDN);
-  mpfr_clear_flags ();
-  mpfr_exp2 (y, x, GMP_RNDN);
-  if (!(MPFR_IS_INF (y) && MPFR_IS_POS (y) && mpfr_overflow_p ()))
+  if (mpfr_get_emax () <= 10000000000)
     {
-      printf ("exp2(10000000000.5) should overflow.\n");
-      exit (1);
+      mpfr_set_prec (x, 40);
+      mpfr_set_prec (y, 40);
+      mpfr_set_str (x, "10000000000.5", 10, GMP_RNDN);
+      mpfr_clear_flags ();
+      mpfr_exp2 (y, x, GMP_RNDN);
+      if (!(MPFR_IS_INF (y) && MPFR_IS_POS (y) && mpfr_overflow_p ()))
+        {
+          printf ("exp2(10000000000.5) should overflow.\n");
+          exit (1);
+        }
     }
 
   test_generic (2, 100, 100);


Index: .cvsignore
===================================================================
RCS file: /cvs/dist/rpms/gmp/FC-6/.cvsignore,v
retrieving revision 1.10
retrieving revision 1.11
diff -u -r1.10 -r1.11
--- .cvsignore	14 Jul 2006 19:44:08 -0000	1.10
+++ .cvsignore	26 Oct 2006 16:16:54 -0000	1.11
@@ -1,2 +1,2 @@
-gmp-4.1.3.tar.bz2
 gmp-4.1.4.tar.bz2
+mpfr-2.2.0.tar.bz2


Index: gmp.spec
===================================================================
RCS file: /cvs/dist/rpms/gmp/FC-6/gmp.spec,v
retrieving revision 1.30
retrieving revision 1.31
diff -u -r1.30 -r1.31
--- gmp.spec	14 Jul 2006 19:45:15 -0000	1.30
+++ gmp.spec	26 Oct 2006 16:16:54 -0000	1.31
@@ -4,17 +4,21 @@
 #
 
 %define configure  CFLAGS="${CFLAGS:-%optflags}" ; export CFLAGS ; CXXFLAGS="${CXXFLAGS:-%optflags}" ; export CXXFLAGS ; FFLAGS="${FFLAGS:-%optflags}" ; export FFLAGS ; ./configure %{_target_platform}  --prefix=%{_prefix} --exec-prefix=%{_exec_prefix} --bindir=%{_bindir} --datadir=%{_datadir}  --libdir=%{_libdir} --mandir=%{_mandir}  --infodir=%{_infodir}
+%define mpfr_version 2.2.0
 
 Summary: A GNU arbitrary precision library.
 Name: gmp
 Version: 4.1.4
-Release: 7
+Release: 7%{dist}
 URL: http://www.swox.com/gmp/
-Source: ftp://ftp.gnu.org/pub/gnu/gmp/gmp-%{version}.tar.bz2
+Source0: ftp://ftp.gnu.org/pub/gnu/gmp/gmp-%{version}.tar.bz2
+Source1: http://www.mpfr.org/mpfr-%{mpfr_version}/mpfr-%{mpfr_version}.tar.bz2
 Patch0: gmp-4.0.1-s390.patch
 Patch1: gmp-4.1.2-ppc64.patch
 Patch2: gmp-4.1.2-autoconf.patch
 Patch3: gmp-4.1.4-fpu.patch
+# http://www.mpfr.org/mpfr-%{mpfr_version}/patches
+Patch4: mpfr-2.2.0-cumulative.patch
 License: LGPL 
 Group: System Environment/Libraries
 BuildRoot: %{_tmppath}/%{name}-%{version}-root
@@ -47,11 +51,14 @@
 install the gmp package.
 
 %prep
-%setup -q
+%setup -q -a1
 %patch0 -p1
 #patch1 -p1
 %patch2 -p1
 %patch3 -p1 -b .fpu
+cd mpfr-%{mpfr_version}
+%patch4 -p1
+cd ..
 
 libtoolize --force
 aclocal-1.6 -I mpn -I mpfr
@@ -66,7 +73,7 @@
 mkdir base
 cd base
 ln -s ../configure .
-%configure --enable-mpbsd --enable-mpfr --enable-cxx
+%configure --enable-mpbsd --disable-mpfr --enable-cxx
 perl -pi -e 's|hardcode_libdir_flag_spec=.*|hardcode_libdir_flag_spec=\"-L\\\$libdir\"|g;' libtool
 export LD_LIBRARY_PATH=`pwd`/.libs
 make %{?_smp_mflags}
@@ -82,6 +89,13 @@
 make %{?_smp_mflags}
 cd ..
 %endif
+cd mpfr-%{mpfr_version}
+# XXX Apparently mpfr doesn't support separate build dir
+ln -s ../gmp-impl.h ../base/
+ln -s ../longlong.h ../base/
+%configure --disable-assert --with-gmp-build=`cd ../base; pwd`
+make %{?_smp_mflags}
+cd ..
 
 %install
 [ "$RPM_BUILD_ROOT" != "/" ] && rm -rf $RPM_BUILD_ROOT
@@ -109,6 +123,12 @@
 chmod 644 $RPM_BUILD_ROOT%{_libdir}/sse2/libmp.so.3
 cd ..
 %endif
+cd mpfr-%{mpfr_version}
+%{makeinstall}
+rm -f $RPM_BUILD_ROOT%{_libdir}/libmpfr.la
+install -m 644 ../mpfrxx.h $RPM_BUILD_ROOT%{_includedir}
+rm -f $RPM_BUILD_ROOT%{_infodir}/dir
+cd ..
 
 %check
 %ifnarch ppc
@@ -123,6 +143,9 @@
 make %{?_smp_mflags} check
 cd ..
 %endif
+cd mpfr-%{mpfr_version}
+make %{?_smp_mflags} check
+cd ..
 
 %post -p /sbin/ldconfig
 
@@ -163,7 +186,11 @@
 %{_infodir}/mpfr.info*
 
 %changelog
-* Fri Jul 14 2006 Thomas Woerner <twoerner redhat com>- 4.1.4-7
+* Thu Oct 26 2006 Jakub Jelinek <jakub redhat com> - 4.1.4-7%{dist}
+- upgrade mpfr to 2.2.0 (#211971)
+- apply mpfr 2.2.0 cumulative patch
+
+* Fri Jul 14 2006 Thomas Woerner <twoerner redhat com> - 4.1.4-7
 - release bump
 
 * Fri Feb 10 2006 Jesse Keating <jkeating redhat com> - 4.1.4-6.2.1


Index: sources
===================================================================
RCS file: /cvs/dist/rpms/gmp/FC-6/sources,v
retrieving revision 1.10
retrieving revision 1.11
diff -u -r1.10 -r1.11
--- sources	14 Jul 2006 19:44:08 -0000	1.10
+++ sources	26 Oct 2006 16:16:54 -0000	1.11
@@ -1 +1,2 @@
 0aa7d3b3f5b5ec5951e7dddd6f65e891  gmp-4.1.4.tar.bz2
+1a81f721ee78cb027f6c41a243d3a33d  mpfr-2.2.0.tar.bz2


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]