summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Orlitzky <mjo@gentoo.org>2021-03-24 17:35:49 -0400
committerMichael Orlitzky <mjo@gentoo.org>2021-03-25 10:35:26 -0400
commit99d068bcd512389b60a972d53c95f22571ed3537 (patch)
treec2d97a731e1d71733a02a44c602dc4e0a0f3921f /sci-mathematics/maxima
parentsci-mathematics/maxima: Revert "don't hardcode python" (diff)
downloadgentoo-99d068bcd512389b60a972d53c95f22571ed3537.tar.gz
gentoo-99d068bcd512389b60a972d53c95f22571ed3537.tar.bz2
gentoo-99d068bcd512389b60a972d53c95f22571ed3537.zip
sci-mathematics/maxima: re-enable ECL package.
The ECL package needed for USE=ecls got dropped from the ebuild because the patch it requires no longer applied. We take François Bissey's patch from the sage-on-gentoo overlay and re-enable it. Closes: https://bugs.gentoo.org/732776 Package-Manager: Portage-3.0.13, Repoman-3.0.2 Signed-off-by: Michael Orlitzky <mjo@gentoo.org>
Diffstat (limited to 'sci-mathematics/maxima')
-rw-r--r--sci-mathematics/maxima/files/ecls-4.patch16
-rw-r--r--sci-mathematics/maxima/maxima-5.44.0-r1.ebuild (renamed from sci-mathematics/maxima/maxima-5.44.0.ebuild)20
2 files changed, 33 insertions, 3 deletions
diff --git a/sci-mathematics/maxima/files/ecls-4.patch b/sci-mathematics/maxima/files/ecls-4.patch
new file mode 100644
index 000000000000..7c597c223333
--- /dev/null
+++ b/sci-mathematics/maxima/files/ecls-4.patch
@@ -0,0 +1,16 @@
+diff --git a/src/maxima.system b/src/maxima.system
+index ee7ca0f..85ec36f 100644
+--- a/src/maxima.system
++++ b/src/maxima.system
+@@ -75,6 +75,11 @@
+ ;; Convert dir/foo.fas to dir/foo.o
+ (make-pathname :type "o" :defaults p))
+ files)))
++ (c::build-fasl "binary-ecl/maxima" :lisp-files obj
++ :ld-flags
++ (let ((x (symbol-value (find-symbol "*AUTOCONF-LD-FLAGS*"
++ (find-package "MAXIMA")))))
++ (if (and x (not (string= x ""))) (list x))))
+ (c::build-program "binary-ecl/maxima" :lisp-files obj
+ :ld-flags
+ (let ((x (symbol-value (find-symbol "*AUTOCONF-LD-FLAGS*"
diff --git a/sci-mathematics/maxima/maxima-5.44.0.ebuild b/sci-mathematics/maxima/maxima-5.44.0-r1.ebuild
index 6588716b4947..4cb02071d129 100644
--- a/sci-mathematics/maxima/maxima-5.44.0.ebuild
+++ b/sci-mathematics/maxima/maxima-5.44.0-r1.ebuild
@@ -1,9 +1,9 @@
-# Copyright 1999-2020 Gentoo Authors
+# Copyright 1999-2021 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=6
-inherit autotools elisp-common eutils xdg-utils
+inherit autotools elisp-common eutils flag-o-matic xdg-utils
DESCRIPTION="Free computer algebra environment based on Macsyma"
HOMEPAGE="http://maxima.sourceforge.net/"
@@ -20,7 +20,7 @@ SUPP_RL=( . . y . . y )
# . - just --enable-<lisp>, <flag> - --enable-<flag>
CONF_FLAG=( . . . ecl ccl . )
# patch file version; . - no patch
-PATCH_V=( 2 1 . . 3 1 )
+PATCH_V=( 2 1 . 4 3 1 )
IUSE="emacs tk nls unicode X test ${LISPS[*]}"
RESTRICT="!test? ( test )"
@@ -142,7 +142,14 @@ src_configure() {
done
fi
+ # Using raw-ldflags fixes the error,
+ #
+ # x86_64-pc-linux-gnu/bin/ld: fatal error: -O1 -Wl: invalid option
+ # value (expected an integer): 1 -Wl
+ #
+ # when building the maxima.fas library for ECL.
econf ${CONFS} \
+ LDFLAGS="$(raw-ldflags)" \
$(use_with tk wish) \
$(use_enable emacs) \
--with-lispdir="${EPREFIX}/${SITELISP}/${PN}"
@@ -188,6 +195,13 @@ src_install() {
doins interfaces/emacs/imaxima/README
doins -r interfaces/emacs/imaxima/imath-example
fi
+
+ if use ecls; then
+ # Use ECL to find the path where it expects to load packages from.
+ ECLLIB=$(ecl -eval "(princ (SI:GET-LIBRARY-PATHNAME))" -eval "(quit)")
+ insinto "${ECLLIB#${EPREFIX}}"
+ doins src/binary-ecl/maxima.fas
+ fi
}
pkg_postinst() {