1 # Copyright 1999-2016 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
6 inherit autotools elisp-common flag-o-matic multilib prefix versionator
9 MY_PV=$(replace_all_version_separators '.')
10 # Consistency is different...
11 MY_DIR2=$(get_version_component_range 1-3 ${PV})
12 MY_DIR=$(replace_all_version_separators '-' ${MY_DIR2})
13 # This is where the share tarball unpacks to
15 DESCRIPTION="Computer algebra system for polynomial computations"
16 HOMEPAGE="http://www.singular.uni-kl.de/"
17 SRC_URI="http://www.mathematik.uni-kl.de/ftp/pub/Math/${MY_PN}/SOURCES/${MY_DIR}/${PN}-${MY_PV}.tar.gz
18 http://www.mathematik.uni-kl.de/ftp/pub/Math/${MY_PN}/SOURCES/${MY_DIR}/${PN}-${MY_PV}-share.tar.gz"
22 KEYWORDS="~amd64 ~ppc ~x86 ~x86-linux ~x86-macos"
23 IUSE="boost doc emacs examples python +readline"
25 RDEPEND="dev-libs/gmp:0
27 emacs? ( >=virtual/emacs-22 )
34 boost? ( dev-libs/boost )
35 readline? ( sys-libs/readline )"
37 SITEFILE=60${PN}-gentoo.el
39 S="${WORKDIR}/${PN}-${MY_DIR2}"
43 append-ldflags "-fPIC"
44 tc-export AR CC CPP CXX
46 # Ensure that >=emacs-22 is selected
48 elisp-need-emacs 22 || die "Emacs version too low"
53 eapply "${FILESDIR}"/"${P}"-fix-resources-name.patch
54 eapply "${FILESDIR}"/"${P}"-fix-destdir.patch
56 # autoreconf everything since otherwise it assumes autmake-1.13 is installed
69 --enable-IntegerProgramming \
70 $(use_with python python embed) \
71 $(use_with boost Boost) \
73 $(use_with readline) || die "configure failed"
81 elisp-compile *.el || die "elisp-compile failed"
86 einfo "The authors ask you to register as a SINGULAR user."
87 einfo "Please check the license file for details."
91 ewarn "Please note that the ESingular emacs wrapper has been"
92 ewarn "removed in favor of full fledged singular support within"
93 ewarn "Gentoo's emacs infrastructure; i.e. just fire up emacs"
94 ewarn "and you should be good to go! See bug #193411 for more info."
98 use emacs && elisp-site-regen
102 use emacs && elisp-site-regen