diff --git a/math/maxima/Makefile b/math/maxima/Makefile index 3cf885c284f9..e509d2b930fe 100644 --- a/math/maxima/Makefile +++ b/math/maxima/Makefile @@ -1,140 +1,141 @@ # Created by: Scott Flatman PORTNAME= maxima PORTVERSION= 5.46.0 -PORTREVISION= 2 +PORTREVISION= 3 CATEGORIES= math lisp tk MASTER_SITES= SF/maxima/Maxima-source/${PORTVERSION}-source MAINTAINER= salvadore@FreeBSD.org COMMENT= Symbolic mathematics program -LICENSE= GPLv2 MAXIMAEXTRACLAUSE +LICENSE= BSD3CLAUSE GPLv2 MAXIMAEXTRACLAUSE LICENSE_COMB= multi LICENSE_NAME_MAXIMAEXTRACLAUSE= Maxima extra clause +LICENSE_FILE_BSD3CLAUSE= ${WRKSRC}/LICENSES/getopt-license.txt +LICENSE_FILE_GPLv2= ${WRKSRC}/COPYING LICENSE_FILE_MAXIMAEXTRACLAUSE= ${FILESDIR}/license-extra-clause.txt LICENSE_PERMS_MAXIMAEXTRACLAUSE= dist-mirror dist-sell pkg-mirror \ pkg-sell auto-accept RUN_DEPENDS= gnuplot:math/gnuplot \ rlwrap:devel/rlwrap USES= autoreconf gmake makeinfo shared-mime-info GNU_CONFIGURE= yes -CONFIGURE_ARGS= PYTHON=dummy TEST_TARGET= check -INFO= imaxima maxima xmaxima abs_integrate drawutils kovacicODE logic +INFO= imaxima maxima xmaxima abs_integrate drawutils kovacicODE logic \ + symplectic_ode PLIST_SUB+= PORTVERSION=${PORTVERSION} PORTDATA= * PORTDOCS= * PORTEXAMPLES= * OPTIONS_DEFINE= DOCS EXAMPLES MANPAGES NOUSERINIT SAGE TEST XMAXIMA OPTIONS_DEFAULT= ECL MANPAGES NOUSERINIT SAGE TEST XMAXIMA OPTIONS_SINGLE= LISP -OPTIONS_SINGLE_LISP= CCL CMUCL ECL SBCL +OPTIONS_SINGLE_LISP= CCL ECL SBCL OPTIONS_SUB= yes CCL_DESC= Build with Clozure Common Lisp -CMUCL_DESC= Build with CMU Common Lisp ECL_DESC= Build with Embedabble Common Lisp NOUSERINIT_DESC= Do not load user init file for lisp (only for sbcl) SAGE_DESC= Build with patches from Sage (implies ECL) SBCL_DESC= Build with Steel Bank Common Lisp XMAXIMA_DESC= Install xmaxima (implies DOCS and TEST) CCL_BUILD_DEPENDS= ccl:lang/ccl CCL_RUN_DEPENDS= ccl:lang/ccl CCL_CONFIGURE_ON= --with-ccl=ccl CCL_PLIST_SUB= BINDIR=binary-openmcl \ BINNAME=maxima.image - -CMUCL_BUILD_DEPENDS= lisp:lang/cmucl -CMUCL_RUN_DEPENDS= lisp:lang/cmucl -CMUCL_CONFIGURE_ON= --enable-cmucl -CMUCL_PLIST_SUB= BINDIR=binary-cmucl \ - BINNAME=maxima_core +CCL_VARS= NO_ARCH=yes ECL_BUILD_DEPENDS= ecl:lang/ecl ECL_LIB_DEPENDS= libffi.so:devel/libffi \ libgc-threaded.so:devel/boehm-gc-threaded \ libgc.so:devel/boehm-gc \ libgmp.so:math/gmp ECL_RUN_DEPENDS= ecl:lang/ecl # libgc-threaded.so is really only used when ecl is built with THREADS on, # which is the default. See https://reviews.freebsd.org/D24959 for more # details. ECL_CONFIGURE_ON= --with-ecl=ecl ECL_PLIST_SUB= BINDIR=binary-ecl \ BINNAME=maxima -NOUSERINIT_EXTRA_PATCHES= ${PATCHDIR}/extra-patch-src_maxima.in -NOUSERINIT_EXTRA_PATCHES_OFF= ${PATCHDIR}/extra-patch-OFF-src_maxima.in +NOUSERINIT_EXTRA_PATCHES= ${PATCHDIR}/extra-patch-nouserinit-src_maxima.in SAGE_IMPLIES= ECL SAGE_BUILD_DEPENDS= ${LOCALBASE}/lib/libatomic_ops.a:devel/libatomic_ops SAGE_EXTRA_PATCHES= ${PATCHDIR}/extra-patch-share_linearalgebra_matrixexp.lisp \ ${PATCHDIR}/extra-patch-src_grind.lisp \ ${PATCHDIR}/extra-patch-src_hayat.lisp \ ${PATCHDIR}/extra-patch-src_init-cl.lisp SBCL_BUILD_DEPENDS= sbcl:lang/sbcl SBCL_RUN_DEPENDS= sbcl:lang/sbcl SBCL_CONFIGURE_ON= --enable-sbcl +SBCL_EXTRA_PATCHES= ${PATCHDIR}/extra-patch-sbcl-src_maxima.in SBCL_PLIST_SUB= BINDIR=binary-sbcl \ BINNAME=maxima_core +SBCL_VARS= NO_ARCH=yes TEST_BUILD_DEPENDS= gnuplot:math/gnuplot \ rlwrap:devel/rlwrap -TEST_EXTRA_PATCHES_OFF= ${PATCHDIR}/extra-patch-OFF-Makefile.am XMAXIMA_IMPLIES= DOCS TEST XMAXIMA_USES= tk XMAXIMA_CONFIGURE_WITH= wish=${WISH} XMAXIMA_EXTRA_PATCHES_OFF= ${PATCHDIR}/extra-patch-interfaces_Makefile.am post-patch: ${GREP} -Fe '.core' -l -r ${WRKSRC} | ${XARGS} ${REINPLACE_CMD} 's;\.core;_core;g' ${REINPLACE_CMD} "s;tclsh;${TCLSH};g" ${WRKSRC}/interfaces/xmaxima/Makefile.in ${REINPLACE_CMD} "s;/usr;${LOCALBASE};g" ${WRKSRC}/src/intl.lisp +post-patch-TEST-off: + ${REINPLACE_CMD} 's;tests;;' ${WRKSRC}/Makefile.am + post-patch-XMAXIMA-on: ${REINPLACE_CMD} "s;%%DOCSDIR%%;/${DOCSDIR:S,/, ,g};" \ ${WRKSRC}/interfaces/xmaxima/Tkmaxima/Paths.tcl post-configure: ${REINPLACE_CMD} '/ld-flags/s|" |"|' ${WRKSRC}/src/autoconf-variables.lisp ${REINPLACE_CMD} '/ld-flags/s| ")|")|' ${WRKSRC}/src/autoconf-variables.lisp pre-build-CCL-on: cd ${WRKSRC}/src/ && ${MKDIR} binary-ccl && ${LN} -s binary-ccl binary-openmcl post-build-MANPAGES-on: ${GZIP_CMD} ${WRKSRC}/doc/man/maxima.1 post-install: for x in "" "-1" "-2" "-3"; do ${INSTALL_MAN} ${WRKSRC}/doc/info/maxima.info$$x ${STAGEDIR}${PREFIX}/${INFO_PATH}; done ${INSTALL_MAN} ${WRKSRC}/doc/info/maxima-index.lisp ${STAGEDIR}${PREFIX}/${INFO_PATH} post-install-DOCS-on: ${MKDIR} ${STAGEDIR}${DOCSDIR} cd ${WRKSRC}/doc/info && ${COPYTREE_SHARE} . ${STAGEDIR}${DOCSDIR} '-name maxima*\.html' +post-install-ECL-on: + ${MKDIR} ${STAGEDIR}${PREFIX}/lib/ecl + ${INSTALL_LIB} ${WRKSRC}/src/binary-ecl/maxima.fas \ + ${STAGEDIR}${PREFIX}/lib/ecl + ${STRIP_CMD} ${STAGEDIR}${PREFIX}/lib/maxima/${PORTVERSION}/binary-ecl/maxima + post-install-EXAMPLES-on: ${MKDIR} ${STAGEDIR}${EXAMPLESDIR} cd ${WRKSRC}/demo && ${COPYTREE_SHARE} . ${STAGEDIR}${EXAMPLESDIR} '-name *\.dem' post-install-MANPAGES-on: - ${INSTALL_MAN} ${WRKSRC}/doc/man/maxima.1.gz ${STAGEDIR}${PREFIX}/man/man1 - -post-install-ECL-on: - ${MKDIR} ${STAGEDIR}${PREFIX}/lib/ecl - ${INSTALL_DATA} ${WRKSRC}/src/binary-ecl/maxima.fas \ - ${STAGEDIR}${PREFIX}/lib/ecl + ${MKDIR} ${STAGEDIR}${PREFIX}/man/man1 && \ + ${INSTALL_MAN} ${WRKSRC}/doc/man/maxima.1.gz ${STAGEDIR}${PREFIX}/man/man1/maxima.1.gz .include diff --git a/math/maxima/files/extra-patch-OFF-Makefile.am b/math/maxima/files/extra-patch-OFF-Makefile.am deleted file mode 100644 index add8db5334ac..000000000000 --- a/math/maxima/files/extra-patch-OFF-Makefile.am +++ /dev/null @@ -1,11 +0,0 @@ ---- Makefile.am.orig 2020-06-15 21:43:09 UTC -+++ Makefile.am -@@ -6,7 +6,7 @@ if ENABLE_GETTEXT - LOCALE_DIR = locale - endif - --SUBDIRS = admin crosscompile-windows src lisp-utils tests doc interfaces share demo plotting desktopintegration $(LOCALE_DIR) -+SUBDIRS = admin crosscompile-windows src lisp-utils interfaces share plotting desktopintegration $(LOCALE_DIR) - - EXTRA_DIST = \ - common.mk maxima.iss.in \ diff --git a/math/maxima/files/extra-patch-src_maxima.in b/math/maxima/files/extra-patch-nouserinit-src_maxima.in similarity index 79% rename from math/maxima/files/extra-patch-src_maxima.in rename to math/maxima/files/extra-patch-nouserinit-src_maxima.in index 2a0ee963a226..9ade2db6c4cf 100644 --- a/math/maxima/files/extra-patch-src_maxima.in +++ b/math/maxima/files/extra-patch-nouserinit-src_maxima.in @@ -1,22 +1,14 @@ --- src/maxima.in.orig 2020-05-02 19:21:19 UTC +++ src/maxima.in -@@ -165,6 +165,7 @@ if [ -d "$MAXIMA_INITIAL_FOLDER" ]; then - fi - - maxima_image_base="$MAXIMA_IMAGESDIR/binary-$MAXIMA_LISP/maxima" -+maxima_image_base_core="$MAXIMA_IMAGESDIR/binary-$MAXIMA_LISP/maxima_core" - - if [ "$verbose" = "true" ]; then - set -x @@ -243,9 +243,9 @@ elif [ "$MAXIMA_LISP" = "sbcl" ]; then # one has to extend the amount of memory sbcl will be able to claim by using the # switch --dynamic-space-size in order to do so. if [ -x "$MAXIMA_IMAGESDIR/binary-$MAXIMA_LISP/maxima" ]; then - exec "$MAXIMA_IMAGESDIR/binary-$MAXIMA_LISP/maxima" --noinform $MAXIMA_LISP_OPTIONS --end-runtime-options --eval '(cl-user::run)' --end-toplevel-options "$@" + exec "$MAXIMA_IMAGESDIR/binary-$MAXIMA_LISP/maxima" --noinform $MAXIMA_LISP_OPTIONS --end-runtime-options --no-userinit --eval '(cl-user::run)' --end-toplevel-options "$@" else - exec "@SBCL_NAME@" --core "$maxima_image_base.core" --noinform $MAXIMA_LISP_OPTIONS --end-runtime-options --eval '(cl-user::run)' --end-toplevel-options "$@" + exec "@SBCL_NAME@" --core "$maxima_image_base.core" --noinform $MAXIMA_LISP_OPTIONS --end-runtime-options --no-userinit --eval '(cl-user::run)' --end-toplevel-options "$@" fi else diff --git a/math/maxima/files/extra-patch-sbcl-src_maxima.in b/math/maxima/files/extra-patch-sbcl-src_maxima.in new file mode 100644 index 000000000000..f0236fdb7e9e --- /dev/null +++ b/math/maxima/files/extra-patch-sbcl-src_maxima.in @@ -0,0 +1,10 @@ +--- src/maxima.in.orig 2020-05-02 19:21:19 UTC ++++ src/maxima.in +@@ -165,6 +165,7 @@ if [ -d "$MAXIMA_INITIAL_FOLDER" ]; then + fi + + maxima_image_base="$MAXIMA_IMAGESDIR/binary-$MAXIMA_LISP/maxima" ++maxima_image_base_core="$MAXIMA_IMAGESDIR/binary-$MAXIMA_LISP/maxima_core" + + if [ "$verbose" = "true" ]; then + set -x diff --git a/math/maxima/files/patch-Makefile.am b/math/maxima/files/patch-Makefile.am new file mode 100644 index 000000000000..165de96d6477 --- /dev/null +++ b/math/maxima/files/patch-Makefile.am @@ -0,0 +1,11 @@ +--- Makefile.am.orig 2022-05-09 16:39:32 UTC ++++ Makefile.am +@@ -10,7 +10,7 @@ endif + DOC_DIR = doc + endif + +-SUBDIRS = admin crosscompile-windows src lisp-utils tests $(DOC_DIR) interfaces share demo plotting desktopintegration $(LOCALE_DIR) ++SUBDIRS = admin crosscompile-windows src lisp-utils tests interfaces share plotting desktopintegration $(LOCALE_DIR) + + EXTRA_DIST = \ + common.mk maxima.iss.in \ diff --git a/math/maxima/files/patch-configure.ac b/math/maxima/files/patch-configure.ac index 2d42071d5c66..74433aa98ca2 100644 --- a/math/maxima/files/patch-configure.ac +++ b/math/maxima/files/patch-configure.ac @@ -1,39 +1,39 @@ ---- configure.ac.orig 2021-06-22 16:59:07.387685000 -0600 -+++ configure.ac 2021-06-22 16:59:40.892936000 -0600 -@@ -165,21 +165,21 @@ +--- configure.ac.orig 2022-04-13 05:02:12 UTC ++++ configure.ac +@@ -165,21 +165,21 @@ dnl See if git exists. If it does, update VERSION to dnl See if git exists. If it does, update VERSION to include a git tag -AC_CHECK_PROG(git_found, git, true, false) -if test x"${git_found}" = xtrue; then - # Test to see if git describe works (discarding any output). If - # it works, use it. Otherwise, keep existing value of VERSION. - # (git describe fails if git is executed in a non-Git directory, e.g., - # an unpacked tarball. Since the exit codes of git describe are undocumented, - # we cannot distinguish that from a missing annotated tag. - # Play it safe by refusing to change VERSION.) - if git describe > /dev/null 2>&1; then - VERSION="`git describe --dirty`" - # When building RPMs, hyphens in the version are not allowed, so - # replace them with underscores. - VERSION=`echo $VERSION | sed 's;-;_;g'` - fi -fi +dnl AC_CHECK_PROG(git_found, git, true, false) +dnl if test x"${git_found}" = xtrue; then +dnl # Test to see if git describe works (discarding any output). If +dnl # it works, use it. Otherwise, keep existing value of VERSION. +dnl # (git describe fails if git is executed in a non-Git directory, e.g., +dnl # an unpacked tarball. Since the exit codes of git describe are undocumented, +dnl # we cannot distinguish that from a missing annotated tag. +dnl # Play it safe by refusing to change VERSION.) +dnl if git describe > /dev/null 2>&1; then +dnl VERSION="`git describe --dirty`" +dnl # When building RPMs, hyphens in the version are not allowed, so +dnl # replace them with underscores. +dnl VERSION=`echo $VERSION | sed 's;-;_;g'` +dnl fi +dnl fi dnl Parses the version number for the manual manual_version=`echo $VERSION | sed 's+branch_++; s+_base++; s+_dirty++; s+_+.+g'` diff --git a/math/maxima/pkg-plist b/math/maxima/pkg-plist index c6eb0b5cb98a..1d7ad6bebb0f 100644 --- a/math/maxima/pkg-plist +++ b/math/maxima/pkg-plist @@ -1,38 +1,34 @@ bin/maxima bin/rmaxima %%XMAXIMA%%bin/xmaxima %%SAGE%%lib/ecl/maxima.fas lib/maxima/%%PORTVERSION%%/%%BINDIR%%/%%BINNAME%% -%%CMUCL%%lib/maxima/%%PORTVERSION%%/%%BINDIR%%/lisp libexec/maxima/%%PORTVERSION%%/mgnuplot %%MANPAGES%%man/man1/maxima.1.gz -%%MANPAGES%%man/de/man1/maxima.1.gz -%%MANPAGES%%man/ru/man1/maxima.1.gz share/applications/net.sourceforge.maxima.xmaxima.desktop share/bash-completion/completions/maxima share/bash-completion/completions/rmaxima share/bash-completion/completions/xmaxima share/emacs/site-lisp/bookmode.el share/emacs/site-lisp/dbl.el share/emacs/site-lisp/emaxima.el share/emacs/site-lisp/emaxima.lisp share/emacs/site-lisp/emaxima.sty share/emacs/site-lisp/imath.el share/emacs/site-lisp/imaxima-autoconf-variables.el share/emacs/site-lisp/imaxima.el share/emacs/site-lisp/imaxima.lisp share/emacs/site-lisp/maxima-font-lock.el share/emacs/site-lisp/maxima.el share/emacs/site-lisp/mylatex.ltx.el share/emacs/site-lisp/setup-imaxima-imath.el share/emacs/site-lisp/smart-complete.el share/emacs/site-lisp/sshell.el share/info/maxima-index.lisp -share/info/symplectic_ode.info share/metainfo/net.sourceforge.maxima.xmaxima.appdata.xml share/mime/packages/x-mac.xml share/mime/packages/x-maxima-out.xml %%XMAXIMA%%share/pixmaps/net.sourceforge.maxima.png %%XMAXIMA%%share/pixmaps/net.sourceforge.maxima.svg share/pixmaps/text-x-maxima-out.svg share/pixmaps/text-x-maximasession.svg