From 94bbea8346414e0da5abd376c112126ffa096bff Mon Sep 17 00:00:00 2001 From: Matthias Koeppe Date: Tue, 19 Dec 2023 18:37:47 -0800 Subject: [PATCH 1/3] build/pkgs/normaliz/patches: Add https://github.com/Normaliz/Normaliz/issues/412\#issuecomment-1862036237 --- .../normaliz/patches/flint3_d-torrance.patch | 55 +++++++++++++++++++ 1 file changed, 55 insertions(+) create mode 100644 build/pkgs/normaliz/patches/flint3_d-torrance.patch diff --git a/build/pkgs/normaliz/patches/flint3_d-torrance.patch b/build/pkgs/normaliz/patches/flint3_d-torrance.patch new file mode 100644 index 00000000000..5a6e36c51c4 --- /dev/null +++ b/build/pkgs/normaliz/patches/flint3_d-torrance.patch @@ -0,0 +1,55 @@ +--- a/source/libnormaliz/vector_operations.h ++++ b/source/libnormaliz/vector_operations.h +@@ -547,7 +547,10 @@ + + fmpq_poly_fit_length(flp, n); + for (size_t i = 0; i < poly_vector.size(); ++i) { +- fmpq_poly_set_coeff_mpq(flp, (slong)i, poly_vector[i].get_mpq_t()); ++ fmpq_t fcurrent_coeff; ++ fmpq_init(fcurrent_coeff); ++ fmpq_set_mpq(fcurrent_coeff, poly_vector[i].get_mpq_t()); ++ fmpq_poly_set_coeff_fmpq(flp, (slong)i, fcurrent_coeff); + } + } + +@@ -560,8 +563,11 @@ + poly_vector.resize(length); + for (slong i = 0; i < length; i++) { + mpq_t current_coeff; ++ fmpq_t fcurrent_coeff; + mpq_init(current_coeff); +- fmpq_poly_get_coeff_mpq(current_coeff, flp, (slong)i); ++ fmpq_init(fcurrent_coeff); ++ fmpq_poly_get_coeff_fmpq(fcurrent_coeff, flp, (slong)i); ++ fmpq_get_mpq(current_coeff, fcurrent_coeff); + poly_vector[i] = mpq_class(current_coeff); + } + } +--- a/source/libnormaliz/HilbertSeries.cpp ++++ b/source/libnormaliz/HilbertSeries.cpp +@@ -72,7 +72,10 @@ + slong n = (slong)nmzp.size(); + fmpz_poly_fit_length(flp, n); + for (size_t i = 0; i < nmzp.size(); ++i) { +- fmpz_poly_set_coeff_mpz(flp, (slong)i, nmzp[i].get_mpz_t()); ++ fmpz_t fc; ++ fmpz_init(fc); ++ fmpz_set_mpz(fc, nmzp[i].get_mpz_t()); ++ fmpz_poly_set_coeff_fmpz(flp, (slong)i, fc); + } + } + +@@ -80,9 +83,12 @@ + size_t n = (size_t)fmpz_poly_length(flp); + nmzp.resize(n); + mpz_t c; ++ fmpz_t fc; + mpz_init(c); ++ fmpz_init(fc); + for (size_t i = 0; i < nmzp.size(); ++i) { +- fmpz_poly_get_coeff_mpz(c, flp, i); ++ fmpz_poly_get_coeff_fmpz(fc, flp, i); ++ fmpz_get_mpz(c, fc); + nmzp[i] = mpz_class(c); + } + mpz_clear(c); From ea60579b21da672e317aaf3002a686eb7c884b60 Mon Sep 17 00:00:00 2001 From: Matthias Koeppe Date: Tue, 19 Dec 2023 21:41:45 -0800 Subject: [PATCH 2/3] build/pkgs/normaliz/spkg-install.in: Override FLINT configure test --- build/pkgs/normaliz/spkg-install.in | 2 ++ 1 file changed, 2 insertions(+) diff --git a/build/pkgs/normaliz/spkg-install.in b/build/pkgs/normaliz/spkg-install.in index 0d329656614..683a3200e5b 100644 --- a/build/pkgs/normaliz/spkg-install.in +++ b/build/pkgs/normaliz/spkg-install.in @@ -8,6 +8,8 @@ cd src # that an error will be signalled if FLINT or E-ANTIC cannot be found, rather # than building normaliz without it. +export ac_cv_lib_flint_fmpz_poly_set_coeff_mpz=yes + sdh_configure --with-flint --with-e-antic --with-nauty sdh_make sdh_make_install From 6115c96d8e556d96c115607169b30fd1686c1ee4 Mon Sep 17 00:00:00 2001 From: Matthias Koeppe Date: Tue, 19 Dec 2023 22:46:45 -0800 Subject: [PATCH 3/3] build/pkgs/{normaliz,pynormaliz}: Add patchlevel to trigger build of pynormaliz in 'CI Linux incremental' --- build/pkgs/normaliz/package-version.txt | 2 +- build/pkgs/pynormaliz/package-version.txt | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/build/pkgs/normaliz/package-version.txt b/build/pkgs/normaliz/package-version.txt index f870be23bad..2377fe517a0 100644 --- a/build/pkgs/normaliz/package-version.txt +++ b/build/pkgs/normaliz/package-version.txt @@ -1 +1 @@ -3.10.1 +3.10.1.p0 diff --git a/build/pkgs/pynormaliz/package-version.txt b/build/pkgs/pynormaliz/package-version.txt index fc249e9a747..fae0ceb2953 100644 --- a/build/pkgs/pynormaliz/package-version.txt +++ b/build/pkgs/pynormaliz/package-version.txt @@ -1 +1 @@ -2.18 +2.18.p0