diff options
Diffstat (limited to 'gnu/packages/maths.scm')
-rw-r--r-- | gnu/packages/maths.scm | 269 |
1 files changed, 161 insertions, 108 deletions
diff --git a/gnu/packages/maths.scm b/gnu/packages/maths.scm index dad9d4c4d5..c0987f699e 100644 --- a/gnu/packages/maths.scm +++ b/gnu/packages/maths.scm @@ -61,14 +61,14 @@ ;;; Copyright © 2022, 2023 Nicolas Graves <ngraves@ngraves.fr> ;;; Copyright © 2022 Roman Scherer <roman.scherer@burningswell.com> ;;; Copyright © 2023 Jake Leporte <jakeleporte@outlook.com> -;;; Copyright © 2023 Camilo Q.S. (Distopico) <distopico@riseup.net> +;;; Copyright © 2023, 2025 Camilo Q.S. (Distopico) <distopico@riseup.net> ;;; Copyright © 2023, 2025 David Elsing <david.elsing@posteo.net> ;;; Copyright © 2024 Herman Rimm <herman@rimm.ee> ;;; Copyright © 2024 Foundation Devices, Inc. <hello@foundation.xyz> ;;; Copyright © 2024, 2025 Artyom V. Poptsov <poptsov.artyom@gmail.com> ;;; Copyright © 2024 Zheng Junjie <873216071@qq.com> ;;; Copyright © 2025 Luca Cirrottola <luca.cirrottola@inria.fr> -;;; Copyright © 2025 Maxim Cournoyer <maxim.cournoyer@gmail.com> +;;; Copyright © 2025 Maxim Cournoyer <maxim@guixotic.coop> ;;; Copyright © 2025 Sören Tempel <soeren@soeren-tempel.net> ;;; Copyright © 2025 nomike Postmann <nomike@nomike.com> ;;; @@ -289,27 +289,35 @@ interactive dialogs to guide them.") (define-public calc (package (name "calc") - (version "2.14.2.1") + (version "2.15.1.1") (source (origin (method url-fetch) (uri (string-append "http://www.isthe.com/chongo/src/calc/calc-" version ".tar.bz2")) (sha256 - (base32 "1swalx3cxjcx4aprnchb2jf0wig89ggvxjzzzx488r115w58lxnr")))) + (base32 "1710wsyjg3k6qx5xaa5fa1r81izpgjiy676ayznd2p42rn3czmm2")))) (build-system gnu-build-system) (inputs (list readline)) - (native-inputs (list util-linux)) ; for col + (native-inputs (list man-db util-linux)) ;for col (arguments - (list #:phases #~(modify-phases %standard-phases - (delete 'configure) - (add-before 'build 'patch-makefile - (lambda _ - (substitute* "Makefile" - (("^PREFIX= /usr/local") - (string-append "PREFIX=" #$output)) - (("=\\s?/usr") - "= ${PREFIX}"))))))) + (list + #:phases + #~(modify-phases %standard-phases + (delete 'configure) + (add-before 'build 'patch-makefile + (lambda _ + (substitute* "Makefile.config" + (("^PREFIX= /usr/local") + (string-append "PREFIX=" + #$output)) + (("=\\s?/usr") + "= ${PREFIX}")) + (substitute* "Makefile.target" + (("LIBCALC_SHLIB=") + "LIBCALC_SHLIB= -Wl,-rpath='$$ORIGIN'") + (("LIBCUSTCALC_SHLIB=") + "LIBCUSTCALC_SHLIB= -Wl,-rpath='$$ORIGIN'"))))))) (synopsis "Arbitrary precision console calculator") (description "Calc is an arbitrary precision arithmetic system that uses a C-like @@ -829,20 +837,6 @@ translator for the language. In addition to the C library, a stand-alone LP/MIP solver is included in the package.") (license license:gpl3+))) -(define-public glpk-4 - (package - (inherit glpk) - (name "glpk") - (version "4.65") - (source - (origin - (method url-fetch) - (uri (string-append "mirror://gnu/glpk/glpk-" - version ".tar.gz")) - (sha256 - (base32 - "040sfaa9jclg2nqdh83w71sv9rc1sznpnfiripjdyr48cady50a2")))))) - (define-public linasm (package (name "linasm") @@ -1260,37 +1254,40 @@ of partial differential equations using iterative methods.") "0nnap9q1mv14g57dl3vkvxrdr10k5w7zzyxs6rgxhia8q8mphgqb")))) (build-system cmake-build-system) (arguments - `(#:configure-flags '("-DCMAKE_C_FLAGS=-fcommon -O2") + (list + #:configure-flags + #~(list (string-append "-DCMAKE_C_FLAGS=-fcommon -O2" + " -Wno-error=implicit-function-declaration")) #:phases - (modify-phases %standard-phases - ;; These tests use a lot of stack variables and segfault without - ;; lifting resource limits. - (add-after 'unpack 'disable-broken-tests - (lambda _ - (substitute* "TESTING/CMakeLists.txt" - (("add_lapack_test.* xeigtstz\\)") "")))) - (replace 'install - (lambda* (#:key outputs #:allow-other-keys) - (let* ((out (assoc-ref outputs "out")) - (libdir (string-append out "/lib")) - (f2cinc (string-append out "/include/libf2c"))) - (mkdir-p f2cinc) - (display (getcwd)) - (for-each (lambda (file) - (install-file file libdir)) - '("SRC/liblapack.a" - "F2CLIBS/libf2c/libf2c.a" - "TESTING/MATGEN/libtmglib.a" - "BLAS/SRC/libblas.a")) - (for-each (lambda (file) - (install-file file f2cinc)) - (cons "F2CLIBS/libf2c/arith.h" - (find-files (string-append "../clapack-" - ,version "-CMAKE/F2CLIBS/libf2c") - "\\.h$"))) - (copy-recursively (string-append "../clapack-" - ,version "-CMAKE/INCLUDE") - (string-append out "/include")))))))) + #~(modify-phases %standard-phases + ;; These tests use a lot of stack variables and segfault without + ;; lifting resource limits. + (add-after 'unpack 'disable-broken-tests + (lambda _ + (substitute* "TESTING/CMakeLists.txt" + (("add_lapack_test.* xeigtstz\\)") "")))) + (replace 'install + (lambda _ + (let ((libdir (string-append #$output "/lib")) + (f2cinc (string-append #$output "/include/libf2c"))) + (mkdir-p f2cinc) + (display (getcwd)) + (for-each (lambda (file) + (install-file file libdir)) + '("SRC/liblapack.a" + "F2CLIBS/libf2c/libf2c.a" + "TESTING/MATGEN/libtmglib.a" + "BLAS/SRC/libblas.a")) + (for-each (lambda (file) + (install-file file f2cinc)) + (cons "F2CLIBS/libf2c/arith.h" + (find-files (string-append + "../clapack-" + #$version "-CMAKE/F2CLIBS/libf2c") + "\\.h$"))) + (copy-recursively (string-append "../clapack-" + #$version "-CMAKE/INCLUDE") + (string-append #$output "/include")))))))) (home-page "https://www.netlib.org/clapack/") (synopsis "Numerical linear algebra library for C") (description @@ -2022,7 +2019,43 @@ extremely large and complex data collections.") (lambda _ (invoke "perl" "bin/make_err" "src/H5err.txt") (invoke "perl" "bin/make_vers" "src/H5vers.txt") - (invoke "perl" "bin/make_overflow" "src/H5overflow.txt")))))) + (invoke "perl" "bin/make_overflow" "src/H5overflow.txt"))) + ;; Remove references to GCC/GFortran/binutils in order to decrease + ;; package size. + (add-before 'generate-headers 'remove-referencess + (lambda _ + (substitute* '("src/libhdf5.settings.cmake.in" + "src/H5build_settings.cmake.c.in") + (("@CMAKE_AR@") "ar") + (("@CMAKE_RANLIB@") "ranlib") + (("@CMAKE_C_COMPILER@") "gcc") + (("@CMAKE_CXX_COMPILER") "g++") + (("@CMAKE_Fortran_COMPILER@") "gfortran")) + (substitute* '("src/libhdf5.settings.autotools.in" + "src/H5build_settings.autotools.c.in") + (("@AR@") "ar") + (("@RANLIB@") "ranlib") + (("@CXX_VERSION@") "g++") + (("@@CC_VERSION@") "gcc") + (("@FC_VERSION@") "gfortran")))) + (add-after 'install 'remove-gcc-references + (lambda _ + (substitute* (map (lambda (f) + (string-append #$output "/" f)) + '("bin/h5hlcc" + "bin/h5hlc++" + "bin/h5cc" + "bin/h5c++")) + (("/gnu/store/[a-z0-9]*-gcc-[0-9.]*/bin/") + "")))) + (add-after 'install 'remove-gfortran-references + (lambda _ + (substitute* (map (lambda (f) + (string-append #$output "/" f)) + '("bin/h5hlfc" + "bin/h5fc")) + (("/gnu/store/[a-z0-9]*-gfortran-[0-9.]*/bin/") + ""))))))) (inputs (list libaec zlib)) (native-inputs (list bison @@ -2280,7 +2313,15 @@ Swath).") ;; test per line in this file). (substitute* "testpar/CMakeLists.txt" (("(t_pmulti_dset|t_shapesame|t_filters_parallel)" _ test) - (string-append "# " test "\n"))))))))) + (string-append "# " test "\n"))))) + (replace 'remove-gcc-references + (lambda _ + (substitute* (map (lambda (f) + (string-append #$output "/" f)) + '("bin/h5hlcc" + "bin/h5cc")) + (("/gnu/store/[a-z0-9]*-gcc-[0-9.]*/bin/") + "")))))))) (synopsis "Management suite for data with parallel IO support"))) (define-public hdf5-blosc @@ -3389,7 +3430,7 @@ can solve two kinds of problems: (define-public octave-cli (package (name "octave-cli") - (version "10.2.0") + (version "10.3.0") (source (origin (method url-fetch) @@ -3397,7 +3438,7 @@ can solve two kinds of problems: version ".tar.xz")) (sha256 (base32 - "0szpna905qz9fskpnmc4sv4xpna2a2rkxs22d20nx1l16gwb1869")))) + "18ad4mpq9kgxqmab3khgjk9lk6vimbvv9l4zvz98na6dxpr9pblj")))) (build-system gnu-build-system) (inputs (list alsa-lib @@ -3676,7 +3717,7 @@ supports the propositional fragment of PDDL2.2.") (define-public gmsh (package (name "gmsh") - (version "4.13.1") + (version "4.14.1") (source (origin (method git-fetch) @@ -3687,7 +3728,7 @@ supports the propositional fragment of PDDL2.2.") (string-replace-substring version "." "_"))))) (file-name (git-file-name name version)) (sha256 - (base32 "16abxhadyyj7890lv6cdfxskg25w105pcpqvb5iwf6a59py8na8y")) + (base32 "1s53b7llkq30imyahf0f1rwmhfq9149czbrqhfvidkdxzhwpk27d")) (modules '((guix build utils))) (snippet '(delete-file-recursively "contrib/metis")))) @@ -4743,9 +4784,11 @@ Mathematics (GLM) library to Python.") (list python-accupy python-pytest python-setuptools - python-wheel unzip vtk)) + (inputs + ;; [optional] + (list python-matplotlib)) (propagated-inputs (list python-importlib-metadata python-numpy @@ -5873,7 +5916,7 @@ implementation.")))) (define-public wxmaxima (package (name "wxmaxima") - (version "24.11.0") + (version "25.04.0") (source (origin (method git-fetch) (uri (git-reference @@ -5882,7 +5925,7 @@ implementation.")))) (file-name (git-file-name name version)) (sha256 (base32 - "1q66qv7m7dky9h7m6dzvlw6pkzixna4bhrdkz11sg7bv3a9qrlfy")))) + "0m8sk02cmiqxqlcw8rcljyinwajn5hvj5ldf3xr5v1asq1mvck00")))) (build-system cmake-build-system) (native-inputs (list gettext-minimal)) (inputs (list bash-minimal @@ -6003,7 +6046,7 @@ parts of it.") (define-public openblas (package (name "openblas") - (version "0.3.29") + (version "0.3.30") (source (origin (method git-fetch) @@ -6013,7 +6056,7 @@ parts of it.") (file-name (git-file-name name version)) (sha256 (base32 - "1wm00hn0vzb45nqg0q3ka15wjqjzma5lh1x6227di73icqdcbzcz")))) + "08crjjs7avnkk7l226pghhz68mw9ak62xcghc9hdpshbflwzd0vy")))) (build-system gnu-build-system) (arguments (list @@ -6027,10 +6070,11 @@ parts of it.") "MAKE_NB_JOBS=0" ;use jobserver for submakes "NO_STATIC=1" ;avoid a 67 MiB static archive - ;; This is the maximum number of threads OpenBLAS will ever use (that - ;; is, if $OPENBLAS_NUM_THREADS is greater than that, then NUM_THREADS - ;; is used.) If we don't set it, the makefile sets it to the number - ;; of cores of the build machine, which is obviously wrong. + ;; This is the maximum number of threads OpenBLAS will ever use + ;; (that is, if $OPENBLAS_NUM_THREADS is greater than that, then + ;; NUM_THREADS is used.) If we don't set it, the makefile sets + ;; it to the number of cores of the build machine, which is + ;; obviously wrong. "NUM_THREADS=128" ;; DYNAMIC_ARCH is only supported on some architectures. @@ -6071,7 +6115,8 @@ parts of it.") (string-append "-L" (dirname - (search-input-file inputs "/lib/libgfortran.so"))))))))) + (search-input-file inputs + "/lib/libgfortran.so"))))))))) (inputs (list `(,gfortran "lib"))) (native-inputs @@ -6099,8 +6144,6 @@ from the GotoBLAS2-1.13 BSD version.") (synopsis "Optimized BLAS library based on GotoBLAS (ILP64 version)") (license license:bsd-3))) -(define-public openblas-0.3.29 openblas) - (define-public libblastrampoline (package (name "libblastrampoline") @@ -7775,14 +7818,15 @@ in finite element programs.") (native-inputs (list unzip)) (inputs - `(("hdf5" ,hdf5) - ;; FIXME: 'mkoctfile' fails with a linker error: - ;; ld: cannot find -loctinterp - ;; ld: cannot find -loctave - ;; Disable it for now. - ;;("octave" ,octave-cli) - ("python" ,python-2) ; print syntax - ("zlib" ,zlib))) + (list + hdf5 + ;; FIXME: 'mkoctfile' fails with a linker error: + ;; ld: cannot find -loctinterp + ;; ld: cannot find -loctave + ;; Disable it for now. + ;; octave-cli + python + zlib)) (arguments `(;; The 'share/flann/octave' contains a .mex file, which is an ELF file ;; taken 46 MiB unstripped, and 6 MiB stripped. @@ -8162,37 +8206,36 @@ instruction sets. Thus, an application written with Vc can be compiled for: (define-public reducelcs ;; This is the last commit which is available upstream, no ;; release happened since 2010. - (let ((commit "474f88deb968061abe8cf11c959e02319b8ae5c0") - (revision "1")) + (let ((commit "963f74f7279ba6fc0ea7d8ddfd361ea190c80313") + (revision "2")) (package (name "reducelcs") - (version (string-append "1.0-" revision "." (string-take commit 7))) + (version (git-version "1.0" revision commit)) (source (origin (method git-fetch) (uri (git-reference (url "https://github.com/gdv/Reduce-Expand-for-LCS") (commit commit))) - (file-name (string-append name "-" version "-checkout")) + (file-name (git-file-name name version)) (sha256 (base32 - "1rllzcfwc042c336mhq262a8ha90x6afq30kvk60r7i4761j4yjm")))) + "03chvd9wb2z08r7ka2npr49dbimjvzn2gfm7cnp5l079vbw1dfny")))) (build-system gnu-build-system) - (inputs - (list openlibm)) + (inputs (list openlibm)) (arguments - `(#:tests? #f ; no tests - #:phases - (modify-phases %standard-phases - (delete 'configure) ; No configure script exists. - (replace 'install ; No install phase exists. - (lambda* (#:key outputs #:allow-other-keys) - (let* ((out (assoc-ref outputs "out")) - (bin (string-append out "/bin"))) - (install-file "Approximation" bin) - (install-file "CollectResults" bin) - (install-file "GenerateInstances" bin) - #t)))))) + (list + #:tests? #f ; no tests + #:phases + #~(modify-phases %standard-phases + (delete 'configure) ; No configure script exists. + (replace 'install ; No install phase exists. + (lambda* (#:key outputs #:allow-other-keys) + (let* ((out (assoc-ref outputs "out")) + (bin (string-append out "/bin"))) + (install-file "Approximation" bin) + (install-file "CollectResults" bin) + (install-file "GenerateInstances" bin))))))) (synopsis "Approximate Longest Commons Subsequence computation tool") (description "@code{reduceLCS} is an implementation of the Reduce-Expand @@ -8476,7 +8519,7 @@ operations.") (define-public bitwuzla (package (name "bitwuzla") - (version "0.7.0") + (version "0.8.2") (source (origin (method git-fetch) @@ -8485,7 +8528,7 @@ operations.") (commit version))) (file-name (git-file-name name version)) (sha256 - (base32 "1fpd1kgb5xdbcjiqbbc6j0b8g2ly9bp9m3la78fiayl4qlmsvh2b")))) + (base32 "0nakqz29cfkn91yvx1xzsk50rlqbiihslflbjanv4lflcl2zx6mz")))) (build-system meson-build-system) (arguments `(#:configure-flags '("-Dtesting=enabled" "-Ddefault_library=shared" @@ -9845,6 +9888,11 @@ researchers and developers alike to get started on SAT.") #~(modify-phases %standard-phases (add-after 'unpack 'patch-source (lambda* (#:key inputs #:allow-other-keys) + (substitute* "scripts/generate-build-header.sh" + ;; by default BUILD includes the build date which + ;; makes the build not reproducible. + (("^BUILD=.*$") + "BUILD=guix\n")) (substitute* "src/file.c" (("(bzip2|gzip|lzma|xz) -c" all cmd) (string-append (search-input-file inputs @@ -11273,8 +11321,12 @@ the Wolfram language.") (sha256 (base32 "1iagdic8f0yjx01kdds40jfcxcpdbrd3i0ywydl01dhyyvd2yjk9")))) (build-system pyproject-build-system) - (propagated-inputs (list python-mathics-scanner python-pygments)) - (native-inputs (list python-setuptools python-wheel)) + (native-inputs + (list python-pytest + python-setuptools)) + (propagated-inputs + (list python-mathics-scanner + python-pygments)) (home-page "http://github.com/Mathics3/mathics-pygments/") (synopsis "Wolfram language lexer for Pygments") (description "This package provides a Wolfram language lexer for Pygments.") @@ -11399,9 +11451,10 @@ Mathics3.") (setenv "PYTHONPATH" (getcwd)) (setenv "DJANGO_SETTINGS_MODULE" "mathics_django.settings") (invoke "django-admin" "test")))))) - (propagated-inputs (list python-django-4.2 + (propagated-inputs (list python-django python-mathics-scanner python-mathics-core + python-matplotlib python-networkx python-pygments python-requests)) |