diff --git a/.gitignore b/.gitignore index b0df62e..9b7b3a9 100644 --- a/.gitignore +++ b/.gitignore @@ -14,34 +14,3 @@ /giac-1.4.9.41.tar.gz /giac-1.4.9.43.tar.gz /giac-1.4.9.45.tar.gz -/giac-1.4.9.59.tar.gz -/giac-1.5.0.3.tar.gz -/giac-1.5.0.35.tar.gz -/giac-1.5.0.53.tar.gz -/giac-1.5.0.63.tar.gz -/giac-1.5.0.75.tar.gz -/giac-1.5.0.85.tar.gz -/giac-1.6.0.7.tar.gz -/giac-1.6.0.25.tar.gz -/giac-1.7.0.1.tar.gz -/giac-1.7.0.13.tar.gz -/giac-1.7.0.29.tar.gz -/giac-1.9.0.19.tar.gz -/giac-1.9.0.29.tar.gz -/giac-1.9.0.35.tar.gz -/giac-1.9.0.37.tar.gz -/giac-1.9.0.57.tar.gz -/giac-1.9.0.59.tar.gz -/giac-1.9.0.61.tar.gz -/giac-1.9.0.63.tar.gz -/giac-1.9.0.69.tar.gz -/giac-1.9.0.73.tar.gz -/giac-1.9.0.91.tar.gz -/giac-1.9.0.97.tar.gz -/giac-1.9.0.99.tar.gz -/giac-1.9.0.992.tar.gz -/giac-1.9.0.993.tar.gz -/giac-1.9.0.998.tar.gz -/giac-1.9.0.999.tar.gz -/giac-2.0.0.17.tar.gz -/giac-2.0.0.18.tar.gz diff --git a/giac-1.9.0-fix_micropy_compiler_flags.patch b/giac-1.9.0-fix_micropy_compiler_flags.patch deleted file mode 100644 index 7789d51..0000000 --- a/giac-1.9.0-fix_micropy_compiler_flags.patch +++ /dev/null @@ -1,84 +0,0 @@ ---- micropython-1.12/ports/unix/Makefile.orig 2020-10-21 13:52:17.066827941 +0200 -+++ micropython-1.12/ports/unix/Makefile 2020-10-21 13:55:01.614107239 +0200 -@@ -27,14 +27,14 @@ - # compiler settings - CWARN = -Wall -Werror - CWARN += -Wpointer-arith -Wuninitialized --CFLAGS = $(INC) $(CWARN) -std=gnu99 -DUNIX $(CFLAGS_MOD) $(COPT) $(CFLAGS_EXTRA) -+CFLAGS = $(INC) $(CWARN) -DUNIX $(CFLAGS_MOD) $(COPT) $(CFLAGS_EXTRA) ${CFLAGS_FEDORA} -std=gnu99 - - # Debugging/Optimization - ifdef DEBUG - CFLAGS += -g - COPT = -O0 - else --COPT = -Os -fdata-sections -ffunction-sections -DNDEBUG -+COPT = -fdata-sections -ffunction-sections -DNDEBUG - # _FORTIFY_SOURCE is a feature in gcc/glibc which is intended to provide extra - # security for detecting buffer overflows. Some distros (Ubuntu at the very least) - # have it enabled by default. ---- micropython-1.12/xcas/Makefile.orig 2020-10-21 15:27:04.025499976 +0200 -+++ micropython-1.12/xcas/Makefile 2020-10-21 15:30:30.579300358 +0200 -@@ -32,16 +32,16 @@ - ifdef DEBUG - COPT = -g - else --COPT = -g #-fomit-frame-pointer -flto -+COPT = -g - endif - - # compiler settings --CWARN = -Wall #-Werror -Wno-error=cpp -Wno-error=format --CFLAGS = -fPIC -DMICROPY_LIB $(INC) $(CWARN) -ansi -std=gnu99 $(CFLAGS_MOD) $(COPT) $(CFLAGS_EXTRA) -+CWARN = -Wall -+CFLAGS = -fPIC -DMICROPY_LIB $(INC) $(CWARN) ${CFLAGS_FEDORA} -std=gnu99 $(CFLAGS_MOD) $(COPT) $(CFLAGS_EXTRA) - - - --LDFLAGS = $(LDFLAGS_MOD) -lm $(LDFLAGS_EXTRA) -+LDFLAGS = ${LDFLAGS_FEDORA} $(LDFLAGS_MOD) -lm $(LDFLAGS_EXTRA) - - # source files - SRC_C = $(shell find . -name \*.c) ---- micropython-1.12/nspire/Makefile.orig 2020-04-30 09:52:40.000000000 +0200 -+++ micropython-1.12/nspire/Makefile 2020-10-21 14:02:09.081234972 +0200 -@@ -31,14 +31,14 @@ - ifdef DEBUG - COPT = -O0 -g - else --COPT = -Os -g #-fomit-frame-pointer -flto -+COPT = -g - endif - - # compiler settings - CWARN = -Wall -Werror -Wno-error=cpp -Wno-error=format -Wno-error=implicit-function-declaration --CFLAGS = -DMICROPY_LIB -mthumb-interwork $(INC) $(CWARN) -ansi -std=gnu99 $(CFLAGS_MOD) $(COPT) $(CFLAGS_EXTRA) -+CFLAGS = -DMICROPY_LIB -mthumb-interwork $(INC) $(CWARN) $(CFLAGS_FEDORA) -std=gnu99 $(CFLAGS_MOD) $(COPT) $(CFLAGS_EXTRA) - --LDFLAGS = $(LDFLAGS_MOD) -lm $(LDFLAGS_EXTRA) -Wl,--nspireio -+LDFLAGS = $(LDFLAGS_FEDORA) $(LDFLAGS_MOD) -lm $(LDFLAGS_EXTRA) -Wl,--nspireio - - # source files - SRC_C = $(shell find . -name \*.c) ---- micropython-1.12/numworks/Makefile.orig 2020-04-30 09:52:40.000000000 +0200 -+++ micropython-1.12/numworks/Makefile 2020-10-21 14:04:15.408648069 +0200 -@@ -31,16 +31,16 @@ - ifdef DEBUG - COPT = -O0 -g - else --COPT = -Ofast -g #-fomit-frame-pointer -flto -+COPT = -g - endif - - # compiler settings - CWARN = -Wall -Werror -Wno-error=cpp -Wno-error=format --CFLAGS = -DNUMWORKS -DMICROPY_LIB $(INC) $(CWARN) -ansi -std=gnu99 $(CFLAGS_MOD) $(COPT) $(CFLAGS_EXTRA) -+CFLAGS = -DNUMWORKS -DMICROPY_LIB $(INC) $(CWARN) $(CFLAGS_MOD) $(COPT) $(CFLAGS_EXTRA) $(CFLAGS_FEDORA) -std=gnu99 - CFLAGS += -mthumb -march=armv7e-m -mfloat-abi=hard -mcpu=cortex-m7 -mfpu=fpv5-sp-d16 -fdata-sections -ffunction-sections -fno-strict-aliasing -fno-exceptions # -fpermissive - - --LDFLAGS = $(LDFLAGS_MOD) -lm $(LDFLAGS_EXTRA) -+LDFLAGS = ${LDFLAGS_FEDORA} $(LDFLAGS_MOD) -lm $(LDFLAGS_EXTRA) - - # source files - SRC_C = $(shell find . -name \*.c) diff --git a/giac-cocoalib.patch b/giac-cocoalib.patch deleted file mode 100644 index f910f9f..0000000 --- a/giac-cocoalib.patch +++ /dev/null @@ -1,163 +0,0 @@ ---- configure.ac.orig 2020-04-30 01:52:40.000000000 -0600 -+++ configure.ac 2020-10-27 17:05:31.732729921 -0600 -@@ -272,7 +272,7 @@ AC_ARG_ENABLE([cocoa], - [if test "$enableval" = "no"; then CONFIG_COCOA="no"; fi], []) - - if test "$CONFIG_COCOA" = "yes"; then -- AC_CHECK_HEADER(CoCoA/io.H, [], [CONFIG_COCOA="no"]) -+ AC_CHECK_HEADER(CoCoA/BigInt.H, [], [CONFIG_COCOA="no"]) - fi - if test "$CONFIG_COCOA" = "yes"; then - save_LIBS="$LIBS" ---- configure.orig 2020-04-30 01:52:40.000000000 -0600 -+++ configure 2020-10-27 17:06:22.817658796 -0600 -@@ -16662,8 +16662,8 @@ fi - - - if test "$CONFIG_COCOA" = "yes"; then -- ac_fn_cxx_check_header_mongrel "$LINENO" "CoCoA/io.H" "ac_cv_header_CoCoA_io_H" "$ac_includes_default" --if test "x$ac_cv_header_CoCoA_io_H" = xyes; then : -+ ac_fn_cxx_check_header_mongrel "$LINENO" "CoCoA/BigInt.H" "ac_cv_header_CoCoA_BigInt_H" "$ac_includes_default" -+if test "x$ac_cv_header_CoCoA_BigInt_H" = xyes; then : - - else - CONFIG_COCOA="no" ---- src/TmpFGLM.C.orig 2019-11-03 11:23:52.000000000 -0700 -+++ src/TmpFGLM.C 2020-11-06 09:58:43.358885872 -0700 -@@ -109,14 +109,14 @@ namespace CoCoADortmund - void FGLMBasisConversion(vector& NewGB, const vector& OldGB, const PPOrdering& NewOrdering) - { - if (OldGB.empty()) -- CoCoA_ERROR(ERR::nonstandard, "FGLMBasisConversion: empty Groebner Basis vector"); -+ CoCoA_THROW_ERROR(ERR::nonstandard, "FGLMBasisConversion: empty Groebner Basis vector"); - - // Check if generated ideal is zero-dimensional - // const ideal I(AsSparsePolyRing(owner(OldGB.front())), OldGB); - const ideal I(SparsePolyRing(static_cast - (owner(OldGB.front()).myRawPtr())), OldGB); - if (!IsZeroDim(I)) -- CoCoA_ERROR(ERR::nonstandard, "FGLMBasisConversion: ideal must be 0-dimensional"); -+ CoCoA_THROW_ERROR(ERR::nonstandard, "FGLMBasisConversion: ideal must be 0-dimensional"); - - // Initialization of objects needed for computation - // const SparsePolyRing Kx = AsSparsePolyRing(owner(OldGB.front())); ---- src/TmpLESystemSolver.C.orig 2019-11-03 11:20:03.000000000 -0700 -+++ src/TmpLESystemSolver.C 2020-11-06 09:38:58.349024036 -0700 -@@ -29,6 +29,7 @@ - #include "CoCoA/matrix.H" - #include "CoCoA/ring.H" - #include "CoCoA/error.H" -+#include "CoCoA/MachineInt.H" - - // #include // Included by DenseMatrix.H - using std::vector; -@@ -50,7 +51,11 @@ namespace CoCoADortmund - - for (size_t row = 0; row < NumRowsMSource; ++row) - for (size_t col = 0; col < NumColsMSource; ++col) -- SetEntry(MTarget, row, col, MSource(row, col)); -+ { -+ const MachineInt rowInt(static_cast(row)); -+ const MachineInt colInt(static_cast(col)); -+ SetEntry(MTarget, row, col, MSource(rowInt, colInt)); -+ } - } - - // Solve the linear system M*x = b by using Gauss' algorithm -@@ -60,22 +65,23 @@ namespace CoCoADortmund - const size_t NumColsM = NumCols(M); - const size_t NumRowsb = NumRows(b); - const size_t NumColsb = NumCols(b); -+ const MachineInt zInt(0); - - // Dimension check - if (NumRowsM != NumRowsb) -- CoCoA_ERROR(ERR::BadMatrixSize, "mySolve: M and b must have same number of rows."); -+ CoCoA_THROW_ERROR(ERR::BadMatrixSize, "mySolve: M and b must have same number of rows."); - if (NumColsM != NumRows(x0)) -- CoCoA_ERROR(ERR::BadMatrixSize, "mySolve: M and x0 must have same number of columns."); -+ CoCoA_THROW_ERROR(ERR::BadMatrixSize, "mySolve: M and x0 must have same number of columns."); - if (NumCols(x0) != 1) -- CoCoA_ERROR(ERR::BadMatrixSize, "mySolve: NumCols(x0) > 1."); -+ CoCoA_THROW_ERROR(ERR::BadMatrixSize, "mySolve: NumCols(x0) > 1."); - if (NumColsb != 1) -- CoCoA_ERROR(ERR::BadMatrixSize, "mySolve: NumCols(b) > 1."); -+ CoCoA_THROW_ERROR(ERR::BadMatrixSize, "mySolve: NumCols(b) > 1."); - - // Field check; should we also check if BaseRing(M) = BaseRing(b) = BaseRing(x0)? - // ring K(BaseRing(M)); - ring K(RingOf(M)); - if (!IsField(K)) -- CoCoA_ERROR(ERR::NotField, "mySolve: Gauss' algorithm over non-fields not yet implemented."); -+ CoCoA_THROW_ERROR(ERR::NotField, "mySolve: Gauss' algorithm over non-fields not yet implemented."); - - // Create working copies of M and b - matrix MCopy(NewDenseMat(K, NumRowsM, NumColsM)); -@@ -91,13 +97,17 @@ namespace CoCoADortmund - size_t row = 0; - for (size_t col = 0; col < NumColsM && row < NumRowsM; ++col) - { -+ const MachineInt rowInt(static_cast(row)); -+ const MachineInt colInt(static_cast(col)); -+ - // Check if current column contains an element != 0 -- if (IsZero(MCopy(row, col))) -+ if (IsZero(MCopy(rowInt, colInt))) - { - size_t i = row+1; - for ( ; i < NumRowsM; ++i) - { -- if (!IsZero(MCopy(i, col))) -+ const MachineInt iInt(static_cast(i)); -+ if (!IsZero(MCopy(iInt, colInt))) - { - // Switch MCopy and bCopy rows - MCopy->mySwapRows(i, row); -@@ -113,13 +123,14 @@ namespace CoCoADortmund - positions.push_back(make_pair(row, col)); - - // Found an element != 0 in current column; apply elemination -- c = MCopy(row, col); -+ c = MCopy(rowInt, colInt); - - for (size_t i = row+1; i < NumRowsM; ++i) - { - // Transform MCopy and bCopy -- bCopy->myAddRowMul(i, row, -MCopy(i, col)/c); -- MCopy->myAddRowMul(i, row, -MCopy(i, col)/c); -+ const MachineInt iInt(static_cast(i)); -+ bCopy->myAddRowMul(i, row, -MCopy(iInt, colInt)/c); -+ MCopy->myAddRowMul(i, row, -MCopy(iInt, colInt)/c); - } - - ++row; -@@ -128,7 +139,8 @@ namespace CoCoADortmund - // row = rank(MCopy); check if a solution for the equation system exists - for (size_t i = row; i < NumRowsb; ++i) - { -- if (!IsZero(bCopy(i, 0))) -+ const MachineInt iInt(static_cast(i)); -+ if (!IsZero(bCopy(iInt, zInt))) - return false; - } - -@@ -138,13 +150,16 @@ namespace CoCoADortmund - while (!positions.empty()) - { - const size_t i = positions.back().first, j = positions.back().second; -+ const MachineInt iInt(static_cast(i)); -+ const MachineInt jInt(static_cast(j)); - -- RingElem x(bCopy(i, 0)); -+ RingElem x(bCopy(iInt, zInt)); - for (size_t k = j + 1; k < NumColsM; ++k) - { -- x -= MCopy(i, k) * x0Tmp(k, 0); -+ const MachineInt kInt(static_cast(k)); -+ x -= MCopy(iInt, kInt) * x0Tmp(kInt, zInt); - } -- SetEntry(x0Tmp, j, 0, x/MCopy(i, j)); -+ SetEntry(x0Tmp, j, 0, x/MCopy(iInt, jInt)); - - positions.pop_back(); - } diff --git a/giac-config.patch b/giac-config.patch deleted file mode 100644 index 4e69123..0000000 --- a/giac-config.patch +++ /dev/null @@ -1,19 +0,0 @@ -diff --git a/m4/intdiv0.m4 b/m4/intdiv0.m4 -index b8d7817..23fdc1d 100644 ---- a/m4/intdiv0.m4 -+++ b/m4/intdiv0.m4 -@@ -29,10 +29,10 @@ sigfpe_handler (sig) int sig; - exit (sig != SIGFPE); - } - --int x = 1; --int y = 0; --int z; --int nan; -+volatile int x = 1; -+volatile int y = 0; -+volatile int z; -+volatile int nan; - - int main () - { diff --git a/giac-faking_mkjs.patch b/giac-faking_mkjs.patch deleted file mode 100644 index 4978d74..0000000 --- a/giac-faking_mkjs.patch +++ /dev/null @@ -1,22 +0,0 @@ ---- a/src/Makefile.orig.am 2024-05-13 08:25:27.000000000 +0200 -+++ b/src/Makefile.am 2024-07-16 21:37:38.681076855 +0200 -@@ -71,7 +71,7 @@ - ./mkjs - - mkjs: mkjs.cc -- g++ mkjs.cc -o mkjs -+ g++ mkjs.cc -o mkjs.fake - - AM_CPPFLAGS = -DIN_GIAC -I$(srcdir) -I$(top_srcdir) -I$(builddir) \ - -I$(top_builddir) $(GMP_CFLAGS) $(NTL_CFLAGS) \ ---- a/src/Makefile.orig.in 2024-05-23 17:09:52.000000000 +0200 -+++ b/src/Makefile.in 2024-07-16 21:36:49.122491632 +0200 -@@ -1470,7 +1470,7 @@ - ./mkjs - - mkjs: mkjs.cc -- g++ mkjs.cc -o mkjs -+ g++ mkjs.cc -o mkjs.fake - - install-exec-hook: - rm -f $(DESTDIR)$(bindir)/cas_help diff --git a/giac-fix_graphe_file.patch b/giac-fix_graphe_file.patch deleted file mode 100644 index 5129aa9..0000000 --- a/giac-fix_graphe_file.patch +++ /dev/null @@ -1,11 +0,0 @@ ---- a/src/graphe.orig.cc 2021-09-06 21:27:18.514049316 +0200 -+++ b/src/graphe.cc 2021-09-06 21:27:17.150072679 +0200 -@@ -15757,7 +15757,7 @@ - continue; - std::sort(d.begin(),d.end()); - if (d==d0) { -- G.make_haar_graph(n); -+ G.make_haar_graph(int(n)); - if (is_isomorphic(G,isom,false)) { - vecteur v(k); - for (int i=0;i #endif // HAVE_LIBGSL diff --git a/giac-makesrc.sh b/giac-makesrc.sh index e7cca4e..e205500 100755 --- a/giac-makesrc.sh +++ b/giac-makesrc.sh @@ -4,8 +4,8 @@ # package maintainer. # -VERSION="2.0.0" -VERSIONREV="18" +VERSION="1.4.9" +VERSIONREV="45" # The upstream tarball name is: giac"$SOURCEORIG".tar.gz SOURCEORIG=_"$VERSION"-"$VERSIONREV" @@ -20,11 +20,13 @@ if [ -f "$OUTPUTFILEBASENAME".tar.gz -o -f "$OUTPUTFILEBASENAME".tar.bz2 ] ; the fi echo >&2 "Build a temporary working dir" -mkdir -p giac-src -cd giac-src +TARGET=$(mkdir -p "giac-src") +ORIGDIR=`pwd` +cd "$TARGET" echo >&2 "Downloading upstream source ..." -wget "https://www-fourier.univ-grenoble-alpes.fr/~parisse/debian/dists/stable/main/source/giac$SOURCEORIG.tar.gz" +wget "http://www-fourier.ujf-grenoble.fr/~parisse/debian/dists/stable/main/source/giac$SOURCEORIG.tar.gz" + echo >&2 "Untar upstream source ..." tar -xzf giac"$SOURCEORIG".tar.gz @@ -58,10 +60,11 @@ touch html_vall echo >&2 "Building giac source tarball ..." cd ../../../ tar -cz giac-"$VERSION" -f "$OUTPUTFILEBASENAME".tar.gz -mv "giac"$OUTPUTFILEBASENAME".tar.gz" ../ -cd ../ + echo >&2 "Cleaning extracted dir ..." rm -rf giac-src +rm -f "giac$SOURCEORIG.tar.gz" +rm -rf giac-"$VERSION" echo >&2 "Finished." diff --git a/giac-pari2.15.patch b/giac-pari2.15.patch deleted file mode 100644 index ae0b52f..0000000 --- a/giac-pari2.15.patch +++ /dev/null @@ -1,30 +0,0 @@ ---- giac-1.9.0/src/pari.cc.orig 2022-03-16 05:38:05.000000000 -0600 -+++ giac-1.9.0/src/pari.cc 2022-09-20 09:23:12.304717931 -0600 -@@ -749,7 +749,7 @@ namespace giac { - RET_INT=2, - RET_LONG=3 - }; -- typedef GEN (*PFGEN)(ANYARG); -+ typedef GEN (*PFGEN)(...); - - extern const unary_function_ptr * const at_pari; - static gen in_pari(const gen & args,GIAC_CONTEXT){ -@@ -884,15 +884,15 @@ namespace giac { - break; - - case RET_INT: -- m = (long)((int (*)(ANYARG))call)(_ARGS_); -+ m = (long)((int (*)(...))call)(_ARGS_); - res = stoi(m); break; - - case RET_LONG: -- m = ((long (*)(ANYARG))call)(_ARGS_); -+ m = ((long (*)(...))call)(_ARGS_); - res = stoi(m); break; - - case RET_VOID: -- ((void (*)(ANYARG))call)(_ARGS_); -+ ((void (*)(...))call)(_ARGS_); - res = gnil; break; - } - diff --git a/giac-undefine_GLIBCXX_ASSERTIONS.patch b/giac-undefine_GLIBCXX_ASSERTIONS.patch deleted file mode 100644 index 1b36832..0000000 --- a/giac-undefine_GLIBCXX_ASSERTIONS.patch +++ /dev/null @@ -1,37 +0,0 @@ ---- a/src/first.orig.h 2023-05-24 09:52:40.000000000 +0200 -+++ b/src/first.h 2024-02-10 19:37:26.376884368 +0100 -@@ -27,12 +27,7 @@ - #endif - - // register is deprecated in c++17 --#define register -- -- --#ifdef _GLIBCXX_ASSERTIONS --#undef _GLIBCXX_ASSERTIONS --#endif -+#define register - - #if defined NUMWORKS && !defined SDL_KHICAS - #define KHICAS 1 ---- a/src/vecteur.orig.cc 2024-06-04 08:13:22.000000000 +0200 -+++ b/src/vecteur.cc 2024-11-01 17:58:56.061073533 +0100 -@@ -8498,15 +8498,15 @@ - } - else { - int C=col+1; -- longlong * ptr= &buffer[C],*ptrend=&buffer[0]+cmax-4; -- const int *ptrN=&Nline[C]; -+ longlong * ptr= &buffer[0]+C,*ptrend=&buffer[0]+cmax-4; -+ const int *ptrN=&Nline[0]+C; - for (;ptr