diff options
author | Markus Dittrich <markusle@gentoo.org> | 2009-11-24 03:38:03 +0000 |
---|---|---|
committer | Markus Dittrich <markusle@gentoo.org> | 2009-11-24 03:38:03 +0000 |
commit | 49c4db631ef9ffee829db3849ed6fa76d3eba823 (patch) | |
tree | 82696164432d5a1c8e118c9d4d523f9a92f28f3c /sci-mathematics/singular | |
parent | add use dep for libsdl (diff) | |
download | gentoo-2-49c4db631ef9ffee829db3849ed6fa76d3eba823.tar.gz gentoo-2-49c4db631ef9ffee829db3849ed6fa76d3eba823.tar.bz2 gentoo-2-49c4db631ef9ffee829db3849ed6fa76d3eba823.zip |
Version bump (fixes #293645 and #293084).
(Portage version: 2.1.7.4/cvs/Linux x86_64)
Diffstat (limited to 'sci-mathematics/singular')
5 files changed, 289 insertions, 1 deletions
diff --git a/sci-mathematics/singular/ChangeLog b/sci-mathematics/singular/ChangeLog index e95ebb25b0d3..567f442548d2 100644 --- a/sci-mathematics/singular/ChangeLog +++ b/sci-mathematics/singular/ChangeLog @@ -1,6 +1,14 @@ # ChangeLog for sci-mathematics/singular # Copyright 1999-2009 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/sci-mathematics/singular/ChangeLog,v 1.28 2009/08/09 16:09:21 ssuominen Exp $ +# $Header: /var/cvsroot/gentoo-x86/sci-mathematics/singular/ChangeLog,v 1.29 2009/11/24 03:38:03 markusle Exp $ + +*singular-3.1.0.7 (24 Nov 2009) + + 24 Nov 2009; Markus Dittrich <markusle@gentoo.org> + +files/singular-3.1.0-emacs-22.patch, +files/singular-3.1.0-gentoo.patch, + +files/singular-3.1.0-glibc-2.10.patch, +singular-3.1.0.7.ebuild: + Version bump (fixes #293645 and #293084). I've dropped ppc until + we have ntl keyworded on ppc. 09 Aug 2009; Samuli Suominen <ssuominen@gentoo.org> singular-3.0.4.4.ebuild, +files/singular-3.0.4.4-glibc-2.10.patch: diff --git a/sci-mathematics/singular/files/singular-3.1.0-emacs-22.patch b/sci-mathematics/singular/files/singular-3.1.0-emacs-22.patch new file mode 100644 index 000000000000..3f4f3c76203c --- /dev/null +++ b/sci-mathematics/singular/files/singular-3.1.0-emacs-22.patch @@ -0,0 +1,13 @@ +diff -Naur Singular-3-1-0/emacs/singular.el Singular-3-1-0.new/emacs/singular.el +--- Singular-3-1-0/emacs/singular.el 2008-11-03 09:16:38.000000000 -0500 ++++ Singular-3-1-0.new/emacs/singular.el 2009-08-20 22:16:57.000000000 -0400 +@@ -865,7 +865,8 @@ + (add-hook 'singular-post-output-filter-functions 'singular-prompt-remove-filter nil t) + + ;; some relict from Comint mode +- (setq comint-prompt-regexp singular-comint-prompt-regexp)) ++ (setq comint-prompt-regexp singular-comint-prompt-regexp) ++ (setq comint-use-prompt-regexp-instead-of-fields 1)) + ;; required to use prompt-regexp + (setq comint-use-prompt-regexp t) + ;;}}} diff --git a/sci-mathematics/singular/files/singular-3.1.0-gentoo.patch b/sci-mathematics/singular/files/singular-3.1.0-gentoo.patch new file mode 100644 index 000000000000..ecfba313e149 --- /dev/null +++ b/sci-mathematics/singular/files/singular-3.1.0-gentoo.patch @@ -0,0 +1,83 @@ +diff -Naur Singular-3-1-0/kernel/feResource.cc Singular-3-1-0.new/kernel/feResource.cc +--- Singular-3-1-0/kernel/feResource.cc 2009-06-04 04:11:42.000000000 -0400 ++++ Singular-3-1-0.new/kernel/feResource.cc 2009-08-23 19:05:00.000000000 -0400 +@@ -41,7 +41,7 @@ + #define SINGULAR_DEFAULT_DIR "/usr/local/Singular/"S_VERSION1 + #endif + #else // ! defined(MAKE_DISTRIBUTION) +-#define SINGULAR_DEFAULT_DIR S_ROOT_DIR ++#define SINGULAR_DEFAULT_DIR "/usr" + #endif // defined(MAKE_DISTRIBUTION) + + /***************************************************************** +@@ -73,33 +73,31 @@ + { + {"SearchPath", 's', feResPath, NULL, + "$SINGULARPATH;" +- "%b/LIB;" +- "%b/MOD;" ++ "%r/share/singular/MOD;" + "%r/LIB;" +- "%r/../LIB;" ++ "%r/share/singular/LIB;" + "%d/LIB;" +- "%d/../LIB" + ""}, +- {"Singular", 'S', feResBinary,"SINGULAR_EXECUTABLE", "%d/"S_UNAME"/Singular",(char *)""}, +- {"BinDir", 'b', feResDir, "SINGULAR_BIN_DIR", "%d/"S_UNAME, (char *)""}, +- {"RootDir", 'r', feResDir, "SINGULAR_ROOT_DIR", "%b/..", (char *)""}, ++ {"Singular", 'S', feResBinary,"SINGULAR_EXECUTABLE", "%d/bin/Singular",(char *)""}, ++ {"BinDir", 'b', feResDir, "SINGULAR_BIN_DIR", "%d/bin", (char *)""}, ++ {"RootDir", 'r', feResDir, "SINGULAR_ROOT_DIR", "%d", (char *)""}, + {"DefaultDir",'d', feResDir, "SINGULAR_DEFAULT_DIR", SINGULAR_DEFAULT_DIR, (char *)""}, +- {"InfoFile", 'i', feResFile, "SINGULAR_INFO_FILE", "%r/info/singular.hlp", (char *)""}, +- {"IdxFile", 'x', feResFile, "SINGULAR_IDX_FILE", "%r/doc/singular.idx", (char *)""}, +- {"HtmlDir", 'h', feResDir, "SINGULAR_HTML_DIR", "%r/html", (char *)""}, ++ {"InfoFile", 'i', feResFile, "SINGULAR_INFO_FILE", "%r/share/info/singular.info.bz2", (char *)""}, ++ {"IdxFile", 'x', feResFile, "SINGULAR_IDX_FILE", "%r/share/singular/singular.idx", (char *)""}, ++ {"HtmlDir", 'h', feResDir, "SINGULAR_HTML_DIR", "%r/share/doc/PFSUBST/html", (char *)""}, + #ifdef ix86_Win + {"HtmlHelpFile",'C', feResFile, "SINGULAR_CHM_FILE", "%r/doc/Manual.chm", (char *)""}, + #endif + {"ManualUrl", 'u', feResUrl, "SINGULAR_URL", "http://www.singular.uni-kl.de/Manual/"S_VERSION1, (char *)""}, +- {"ExDir", 'm', feResDir, "SINGULAR_EXAMPLES_DIR","%r/examples", (char *)""}, ++ {"ExDir", 'm', feResDir, "SINGULAR_EXAMPLES_DIR","%r/share/doc/PFSUBST/examples", (char *)""}, + {"Path", 'p', feResPath, NULL, "%b;$PATH", (char *)""}, + + #ifdef ESINGULAR + {"emacs", 'E', feResBinary,"ESINGULAR_EMACS", "%b/emacs", (char *)""}, + {"xemacs", 'A', feResBinary,"ESINGULAR_EMACS", "%b/xemacs", (char *)""}, + {"SingularEmacs",'M', feResBinary,"ESINGULAR_SINGULAR", "%b/Singular", (char *)""}, +- {"EmacsLoad", 'l', feResFile, "ESINGULAR_EMACS_LOAD", "%e/.emacs-singular", (char *)""}, +- {"EmacsDir", 'e', feResDir, "ESINGULAR_EMACS_DIR", "%r/emacs", (char *)""}, ++ {"EmacsLoad", 'l', feResFile, "ESINGULAR_EMACS_LOAD", "%r/share/emacs/site-lisp/singular/.emacs-singular", (char *)""}, ++ {"EmacsDir", 'e', feResDir, "ESINGULAR_EMACS_DIR", "%r/share/emacs/site-lisp/singular", (char *)""}, + #elif defined(TSINGULAR) + {"SingularXterm",'M', feResBinary,"TSINGULAR_SINGULAR", "%b/Singular", (char *)""}, + #ifdef ix86_Win +@@ -108,7 +106,7 @@ + {"xterm", 'X', feResBinary,"XTERM", "%b/xterm", (char *)""}, + #endif + #else +- {"EmacsDir", 'e', feResDir, "SINGULAR_EMACS_DIR", "%r/emacs", (char *)""}, ++ {"EmacsDir", 'e', feResDir, "SINGULAR_EMACS_DIR", "%r/share/emacs/site-lisp/singular", (char *)""}, + #endif + {NULL, 0, feResUndef, NULL, NULL, NULL}, // must be the last record + }; +diff -Naur Singular-3-1-0/kernel/mod_raw.cc Singular-3-1-0.new/kernel/mod_raw.cc +--- Singular-3-1-0/kernel/mod_raw.cc 2009-06-04 06:18:12.000000000 -0400 ++++ Singular-3-1-0.new/kernel/mod_raw.cc 2009-08-23 19:04:22.000000000 -0400 +@@ -109,11 +109,11 @@ + void* dynl_open_binary_warn(const char* binary_name, const char* msg) + { + void* handle = NULL; +- const char* bin_dir = feGetResource('b'); ++ const char* bin_dir = feGetResource('r'); + if (bin_dir != NULL) + { + char path_name[MAXPATHLEN]; +- sprintf(path_name, "%s%s%s.%s", bin_dir, DIR_SEPP, binary_name, ++ sprintf(path_name, "%s%s%s%s.%s", bin_dir,"/lib/singular", DIR_SEPP, binary_name, + DL_TAIL); + handle = dynl_open(path_name); + if (handle == NULL && ! warn_handle) diff --git a/sci-mathematics/singular/files/singular-3.1.0-glibc-2.10.patch b/sci-mathematics/singular/files/singular-3.1.0-glibc-2.10.patch new file mode 100644 index 000000000000..0593eded2a08 --- /dev/null +++ b/sci-mathematics/singular/files/singular-3.1.0-glibc-2.10.patch @@ -0,0 +1,34 @@ +diff -Naur Singular-3-1-0/kernel/febase.cc Singular-3-1-0.new/kernel/febase.cc +--- Singular-3-1-0/kernel/febase.cc 2009-06-22 13:16:57.000000000 -0400 ++++ Singular-3-1-0.new/kernel/febase.cc 2009-08-20 22:31:06.000000000 -0400 +@@ -739,13 +739,15 @@ + char* dir_sep; + struct passwd *pw_entry; + strcpy (longpath, path); +- dir_sep = strchr(longpath, DIR_SEP); ++ // TODO: fix the ugly casting away of const ++ dir_sep = const_cast<char*> ( strchr(longpath, DIR_SEP) ); + *dir_sep = '\0'; + pw_entry = getpwnam(&longpath[1]); + if (pw_entry != NULL) + { + strcpy(longpath, pw_entry->pw_dir); +- dir_sep = strchr((char *)path, DIR_SEP); ++ // TODO: fix the ugly casting away of const ++ dir_sep = const_cast<char*> ( strchr((char*)path, DIR_SEP) ); + strcat(longpath, dir_sep); + path = longpath; + } +diff -Naur Singular-3-1-0/kernel/mpr_complex.cc Singular-3-1-0.new/kernel/mpr_complex.cc +--- Singular-3-1-0/kernel/mpr_complex.cc 2009-06-22 13:16:57.000000000 -0400 ++++ Singular-3-1-0.new/kernel/mpr_complex.cc 2009-08-20 22:28:58.000000000 -0400 +@@ -83,7 +83,8 @@ + BOOLEAN neg=false; + if (*in == '-') { in++; neg=TRUE; } + char *s; +- if ((s=strchr((char *)in,'E')) !=NULL) ++ /* TODO: fix the ugly casting away of const */ ++ if ((s = const_cast<char*> ( strchr(in,'E') )) !=NULL) + { + *s='e'; + } diff --git a/sci-mathematics/singular/singular-3.1.0.7.ebuild b/sci-mathematics/singular/singular-3.1.0.7.ebuild new file mode 100644 index 000000000000..2e552f08e0fb --- /dev/null +++ b/sci-mathematics/singular/singular-3.1.0.7.ebuild @@ -0,0 +1,150 @@ +# Copyright 1999-2009 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/sci-mathematics/singular/singular-3.1.0.7.ebuild,v 1.1 2009/11/24 03:38:03 markusle Exp $ + +EAPI="2" + +inherit eutils elisp-common flag-o-matic autotools multilib versionator + +PV_MAJOR=${PV%.*} +MY_PV=${PV//./-} +MY_PN=${PN/s/S} +MY_PV_MAJOR=${MY_PV%-*} +MY_SHARE="3-1-0-4" + +DESCRIPTION="Computer algebra system for polynomial computations" +HOMEPAGE="http://www.singular.uni-kl.de/" +SRC_URI="http://www.mathematik.uni-kl.de/ftp/pub/Math/Singular/SOURCES/${MY_PV_MAJOR}/${MY_PN}-${MY_PV}.tar.gz + http://www.mathematik.uni-kl.de/ftp/pub/Math/Singular/UNIX/${MY_PN}-${MY_SHARE}-share.tar.gz" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="~amd64 ~x86" +IUSE="doc emacs boost" + +RDEPEND=">=dev-libs/gmp-4.1-r1 + >=dev-libs/ntl-5.5.1 + emacs? ( >=virtual/emacs-22 )" + +DEPEND="${RDEPEND} + >=dev-lang/perl-5.6 + boost? ( dev-libs/boost )" + +S="${WORKDIR}"/${MY_PN}-${MY_PV_MAJOR} +SITEFILE=60${PN}-gentoo.el + +src_prepare () { + epatch "${FILESDIR}"/${PN}-${PV_MAJOR}-gentoo.patch + epatch "${FILESDIR}"/${PN}-3.0.4.4-nostrip.patch + epatch "${FILESDIR}"/${PN}-${PV_MAJOR}-emacs-22.patch + epatch "${FILESDIR}"/${PN}-${PV_MAJOR}-glibc-2.10.patch + + sed -e "s/PFSUBST/${PF}/" -i kernel/feResource.cc \ + || die "sed failed on feResource.cc" + + cd "${S}"/Singular || die "failed to cd into Singular/" + + if use boost; then + sed -e "/CXXFLAGS/ s/--no-exceptions//g" \ + -i configure.in \ + || die "failed to fix --no-exceptions for boost" + fi + eautoconf +} + +src_configure() { + local myconf="$(use_with boost Boost) \ + $(use_enable emacs) \ + --disable-doc \ + --without-MP \ + --with-factory \ + --with-libfac \ + --disable-NTL \ + --disable-gmp \ + --prefix=${S}" + + econf ${myconf} || die "econf failed" +} + +src_compile() { + emake -j1 || die "make failed" + + if use emacs; then + cd "${WORKDIR}"/${MY_PN}/${MY_PV_MAJOR}/emacs/ + elisp-compile *.el || die "elisp-compile failed" + fi +} + +src_install () { + # install basic docs + cd "${S}" && dodoc BUGS ChangeLog || \ + die "failed to install docs" + + # install data files + insinto /usr/share/${PN}/LIB + cd "${S}"/${MY_PN}/LIB && doins *.lib help.cnf \ + || die "failed to install lib files" + insinto /usr/share/${PN}/LIB/gftables + cd gftables && doins * \ + || die "failed to install files int LIB/gftables" + + cd "${S}"/*-Linux + + # install binaries + rm ${MY_PN} || die "failed to remove ${MY_PN}" + dobin ${MY_PN}* gen_test change_cost solve_IP toric_ideal LLL \ + || die "failed to install binaries" + + # install libraries + insinto /usr/$(get_libdir)/${PN} + doins *.so || die "failed to install libraries" + + # create symbolic link + dosym /usr/bin/${MY_PN}-${MY_PV_MAJOR} /usr/bin/${MY_PN} \ + || die "failed to create symbolic link" + + # install examples + cd "${WORKDIR}"/${MY_PN}/${MY_PV_MAJOR} + insinto /usr/share/${PN}/examples + doins examples/* || die "failed to install examples" + + # install extended docs + if use doc; then + dohtml -r html/* || die "failed to install html docs" + + insinto /usr/share/${PN} + doins doc/singular.idx || die "failed to install idx file" + + cp info/${PN}.hlp info/${PN}.info && + doinfo info/${PN}.info \ + || die "failed to install info files" + fi + + # install emacs specific stuff here, as we did a directory change + # some lines above! + if use emacs; then + elisp-install ${PN} emacs/*.el emacs/*.elc emacs/.emacs* \ + || die "elisp-install failed" + elisp-site-file-install "${FILESDIR}/${SITEFILE}" + fi +} + +pkg_postinst() { + einfo "The authors ask you to register as a SINGULAR user." + einfo "Please check the license file for details." + + if use emacs; then + echo + ewarn "Please note that the ESingular emacs wrapper has been" + ewarn "removed in favor of full fledged singular support within" + ewarn "Gentoo's emacs infrastructure; i.e. just fire up emacs" + ewarn "and you should be good to go! See bug #193411 for more info." + echo + fi + + use emacs && elisp-site-regen +} + +pkg_postrm() { + use emacs && elisp-site-regen +} |