Ticket #9860: pari.p5.patch

File pari.p5.patch, 5.5 KB (added by jdemeyer, 10 years ago)

Additional spkg patches by me

  • SPKG.txt

    diff -r d4c104308548 SPKG.txt
    a b  
    8383
    8484== Changelog ==
    8585
    86 === pari-2.4.3.svn-12577.p5 (Leif Leonhardy, September 5th, 2010) ===
     86=== pari-2.4.3.svn-12577.p5 (Leif Leonhardy, Jeroen Demeyer, September 5th, 2010) ===
    8787 * Added patches to:
    8888   - config/get_config_options:
    8989     * Make invalid arguments to "--graphic" a "Configure" error
     
    123123   - Some clean-up.
    124124 * Slight corrections to SPKG.txt.
    125125 * Updated patches/README.txt, some cosmetic changes.
     126 * Remove patch for config/Makefile.SH and add upstream fix instead
     127   in spkg-make.
     128 * Add upstream fix for src/test/tune.c which should fix tuning.
     129 * Add -O0 to CFLAGS in spkg-make to speed up compiling (the output of
     130   the compiling is not used anyway).
    126131
    127132=== pari-2.4.3.svn-12577.p4 (Jeroen Demeyer, August 22, 2010) ===
    128133 * Change "test -e" to "test -f" for Solaris.
  • deleted file patches/Makefile.SH.patch

    diff -r d4c104308548 patches/Makefile.SH.patch
    + -  
    1 Index: config/Makefile.SH
    2 ===================================================================
    3 --- config/Makefile.SH  (revision 12583)
    4 +++ config/Makefile.SH  (working copy)
    5 @@ -599,9 +599,9 @@
    6  EOT
    7  fi
    8  
    9 -if test -e $TOP/.svn/entries; then
    10 +if test -f "$TOP/.svn/entries"; then
    11    vcfile="../.svn/entries"
    12 -else if test -e $TOP/.git/index; then
    13 +else if test -f "$TOP/.git/index"; then
    14    vcfile="../.git/index"
    15    fi
    16  fi
  • patches/README.txt

    diff -r d4c104308548 patches/README.txt
    a b  
    77======================================================================
    88
    99Configuration files:
    10 * Configure: Use "#!/usr/bin/env bash" instead of "#!/bin/sh".
     10* Configure: Use "#!/usr/bin/env bash" instead of "#!/bin/sh".  Note
     11  that this is not strictly necessary, but it hopefully makes the
     12  script less system-dependent. Since Sage assumes the existence of
     13  bash anyway, it doesn't hurt either. -- Jeroen Demeyer
    1114* config/get_ld: cwitty: Disable -rpath.
    1215* config/get_tests: John Cremona: Disable testing of ellglobalred in
    1316                    "make test-all" in spkg-check, since it requires
    1417                    the elldata database which we do not include.
    1518* config/get_dlcflags: Add -fno-common to DLCFLAGS on Darwin.
    16 * config/Makefile.SH: Change "test -e" to "test -f" for Solaris.
    1719* config/get_config_options: Catch invalid arguments tp "--graphic".
    1820* config/get_fltk; Add libstdc++; check presence of FLTK headers, too.
    1921* config/get_X11: Search X11 library in */lib64/*, too (not just */lib/*).
     
    6365* src/headers/paripriv.h: Used to need a dummy variable changed from B0
    6466  to N; now fixed upstream.  NB: There's another patch on this file still
    6567  in place!
    66 
     68* config/Makefile.SH: Change "test -e" to "test -f" for Solaris.  Fixed
     69  upstream
  • patches/mp.c.patch

    diff -r d4c104308548 patches/mp.c.patch
    a b  
    1515 /* EXACT INTEGER DIVISION */
    1616 
    1717-#if 1 /* use undocumented GMP interface */
    18 +#ifndef PARI_DONT_USE_GMP_INTERNALS /* use "undocumented" GMP interface: */
     18+#ifndef PARI_DONT_USE_GMP_INTERNALS /* Use GMP/MPIR internals */
    1919+/*
    20 + * Note: "Undocumented" refers to directly accessing ("private") members
    21 + *       of GMP's mpz_t / __mpz_struct types, which are defined in gmp.h.
     20+ * Note: This refers to directly accessing ("private") members of
     21+ *       GMP's mpz_t / __mpz_struct types, which are defined in gmp.h.
    2222+ *       This is in fact (at least) compatible with both
    2323+ *        - GMP (<= 5.0.1) *and*
    2424+ *        - MPIR (<= 2.1.2),
     
    3333   }
    3434 }
    3535-#else
    36 +#else /* don't use "undocumented" GMP interface: */
     36+#else /* Don't use GMP/MPIR internals */
    3737 /* assume y != 0 and the division is exact */
    3838 GEN
    3939 diviuexact(GEN x, ulong y)
  • spkg-install

    diff -r d4c104308548 spkg-install
    a b  
    4545# Add -fno-common to DLCFLAGS on Darwin (for Mac OS X 10.4, "Tiger"):
    4646cp "$PATCHED/get_dlcflags" config/
    4747
    48 # Two configure patches for Solaris:
     48# Use bash for Configure instead of /bin/sh
    4949cp "$PATCHED/Configure" .
    50 cp "$PATCHED/Makefile.SH" config/
    5150
    5251# leif: Catch invalid arguments to "--graphic" (and treat such as an error)
    5352# since otherwise strange compilation errors might occur (cf. #9722, too).
     
    150149
    151150    # Allow the user to enable PARI self-tuning.
    152151    # This is time-consuming, but some may want to do it.
    153     # It is also very unreliable, and currently (svn 12577) completely
    154     # broken on *many* systems.
    155152    # Comment by leif: Also, PARI's Configure calls "make" (instead of $MAKE)
    156153    #                  if we do tuning, so:
    157154    #            TODO: Replace that in our patched version of Configure!
  • spkg-make

    diff -r d4c104308548 spkg-make
    a b  
    6161cd parisvn
    6262svn update -r 12577
    6363
     64# Patch config/Makefile.SH (for Solaris)
     65svn update -r 12588 config/Makefile.SH
    6466
    65 # make pari (must run bison, etc...)
    66 ./Configure || exit
     67# Patch src/test/tune.c (fix tuning)
     68svn update -r 12588 src/test/tune.c
     69
     70
     71# make pari (must run bison, etc...) but disable optimization to speed
     72# up compilation (the output of the compiling is not used anyway).
     73env CFLAGS="-O0" ./Configure || exit
    6774make gp doc || exit
    6875
    6976