From 1f1076242577ecb2fa626eca18e2db0fa052bee3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gonzalo=20Tornar=C3=ADa?= Date: Mon, 4 Oct 2021 00:13:23 -0300 Subject: [PATCH] maxima: update to 5.45.1. Also: - add rlwrap to depends so rmaxima (readline cli) works. - add gnuplot to checkdepends, fixes 2 failing tests. - add patch to allow more rounding, fixes 2 failing tests on musl. - add rmaxima.1 and xmaxima.1 man pages as symlinks to maxima.1. - do not compress info files, since they are used for in-program help and it doesn't work when they are compressed. - add patch to copy test output to stdout, since it's too silent otherwise. --- srcpkgs/maxima/patches/check-output.patch | 13 +++++++++++++ srcpkgs/maxima/patches/musl-round.patch | 23 +++++++++++++++++++++++ srcpkgs/maxima/template | 18 ++++++++++++++---- 3 files changed, 50 insertions(+), 4 deletions(-) create mode 100644 srcpkgs/maxima/patches/check-output.patch create mode 100644 srcpkgs/maxima/patches/musl-round.patch diff --git a/srcpkgs/maxima/patches/check-output.patch b/srcpkgs/maxima/patches/check-output.patch new file mode 100644 index 000000000000..c20368f64300 --- /dev/null +++ b/srcpkgs/maxima/patches/check-output.patch @@ -0,0 +1,13 @@ +Copy test output to stdout in addition to $log_file + +--- a/test-driver 2021-10-04 00:20:29.356330263 -0300 ++++ b/test-driver 2021-10-04 00:19:56.144741073 -0300 +@@ -92,7 +92,7 @@ + trap "st=143; $do_exit" 15 + + # Test script is run here. +-"$@" >$log_file 2>&1 ++"$@" 2>&1 | tee $log_file + estatus=$? + if test $enable_hard_errors = no && test $estatus -eq 99; then + estatus=1 diff --git a/srcpkgs/maxima/patches/musl-round.patch b/srcpkgs/maxima/patches/musl-round.patch new file mode 100644 index 000000000000..a532415ee60b --- /dev/null +++ b/srcpkgs/maxima/patches/musl-round.patch @@ -0,0 +1,23 @@ +Add a bit more room for rounding errors which cause two tests to fail +on x86_64-musl + +--- a/tests/rtest16.mac 2021-10-03 21:31:01.654932345 -0300 ++++ b/tests/rtest16.mac 2021-10-03 21:31:51.633283404 -0300 +@@ -2229,7 +2229,7 @@ + true; + + closeto(li[4](10.0) - (9.6140263862742968515251940747859 - 6.3921313179656069159740055708257*%i), +- 5.618e-15); ++ 7.945e-15); + true; + + closeto(li[4](10.0b0) - (9.6140263862742968515251940747859b0 - 6.3921313179656069159740055708257b0*%i), +@@ -2277,7 +2277,7 @@ + true; + + closeto(li[5](10.0) - (11.2390407376112991620107110964539 - 3.6796065713019972004384472107791*%i), +- 9.93014e-15); ++ 1.25608e-14); + true; + + closeto(li[5](10.0b0) - (11.2390407376112991620107110964539b0 - 3.6796065713019972004384472107791b0*%i), diff --git a/srcpkgs/maxima/template b/srcpkgs/maxima/template index 69b4fc3d990a..6e8a62c81791 100644 --- a/srcpkgs/maxima/template +++ b/srcpkgs/maxima/template @@ -1,18 +1,19 @@ # Template file for 'maxima' pkgname=maxima -version=5.44.0 -revision=4 +version=5.45.1 +revision=1 build_style=gnu-configure configure_args="$(vopt_enable clisp) $(vopt_enable sbcl sbcl-exec)" hostmakedepends="python3 perl emacs texinfo" makedepends="$(vopt_if clisp clisp) $(vopt_if sbcl sbcl)" -depends="$(vopt_if clisp clisp)" +depends="$(vopt_if clisp clisp) rlwrap" +checkdepends=gnuplot short_desc="Computer Algebra System" maintainer="Bosco Garcia " license="GPL-2.0-only" homepage="http://maxima.sourceforge.net" distfiles="${SOURCEFORGE_SITE}/maxima/maxima-${version}.tar.gz" -checksum=d93f5e48c4daf8f085d609cb3c7b0bdf342c667fd04cf750c846426874c9d2ec +checksum=fe9016276970bef214a1a244348558644514d7fdfaa4fc8b9d0e87afcbb4e7dc nostrip=yes nopie=yes @@ -25,6 +26,14 @@ vopt_conflict clisp sbcl post_install() { vmkdir usr/share/doc ln -sf ../maxima/${version}/doc ${DESTDIR}/usr/share/doc/maxima + + # symlink man pages for rmaxima and xmaxima + ln -sf maxima.1 ${DESTDIR}/usr/share/man/man1/rmaxima.1 + ln -sf maxima.1 ${DESTDIR}/usr/share/man/man1/xmaxima.1 + + # info files are used for maxima help, and need to be uncompressed + # removing this file prevents compression of info files + rm ${DESTDIR}/usr/share/info/dir } maxima-src_package() { @@ -48,6 +57,7 @@ xmaxima_package() { depends="${sourcepkg}-${version}_${revision} tk" pkg_install() { vmove usr/bin/xmaxima + vmove usr/share/man/man1/xmaxima.1 vmove usr/share/maxima/${version}/xmaxima vmove usr/share/info/xmaxima.info vinstall ${FILESDIR}/maxima.desktop 644 usr/share/applications