diff options
author | Thomas Kahle <tom111@gmx.de> | 2010-10-10 18:51:57 +0200 |
---|---|---|
committer | Thomas Kahle <tom111@gmx.de> | 2010-10-10 18:53:07 +0200 |
commit | b765c22788249bf93f86066e5337ebe436a466c7 (patch) | |
tree | 9b03bf71225b26caa1a5f5fb316316d76ddee916 /sci-mathematics/Macaulay2 | |
parent | Another prefix fix (diff) | |
download | sci-b765c22788249bf93f86066e5337ebe436a466c7.tar.gz sci-b765c22788249bf93f86066e5337ebe436a466c7.tar.bz2 sci-b765c22788249bf93f86066e5337ebe436a466c7.zip |
Macaulay2-1.4_pre SVN from 1.4 branch
Diffstat (limited to 'sci-mathematics/Macaulay2')
-rw-r--r-- | sci-mathematics/Macaulay2/ChangeLog | 7 | ||||
-rw-r--r-- | sci-mathematics/Macaulay2/Macaulay2-1.4_pre.ebuild | 150 | ||||
-rw-r--r-- | sci-mathematics/Macaulay2/Manifest | 4 | ||||
-rw-r--r-- | sci-mathematics/Macaulay2/files/1.4_pre-paths-of-external-programs.patch | 61 |
4 files changed, 221 insertions, 1 deletions
diff --git a/sci-mathematics/Macaulay2/ChangeLog b/sci-mathematics/Macaulay2/ChangeLog index a91d82790..983f78d89 100644 --- a/sci-mathematics/Macaulay2/ChangeLog +++ b/sci-mathematics/Macaulay2/ChangeLog @@ -2,6 +2,13 @@ # Copyright 1999-2010 Gentoo Foundation; Distributed under the GPL v2 # $Header: $ +*Macaulay2-1.4_pre (10 Oct 2010) + + 10 Oct 2010; Thomas Kahle <tom111@gmx.de> + +files/1.4_pre-paths-of-external-programs.patch, + +Macaulay2-1.4_pre.ebuild: + SVN from 1.4 branch added + 29 Sep 2010; Thomas Kahle <tom111@gmx.de> Macaulay2-9999.ebuild: Live ebuild: Upstream fixed a bug. diff --git a/sci-mathematics/Macaulay2/Macaulay2-1.4_pre.ebuild b/sci-mathematics/Macaulay2/Macaulay2-1.4_pre.ebuild new file mode 100644 index 000000000..f0369c9b5 --- /dev/null +++ b/sci-mathematics/Macaulay2/Macaulay2-1.4_pre.ebuild @@ -0,0 +1,150 @@ +# Copyright 1999-2010 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: $ + +EAPI="2" + +inherit autotools elisp-common eutils subversion + +IUSE="emacs optimization" + +ESVN_REPO_URI="svn://svn.macaulay2.com/Macaulay2/release-branches/1.4" + +DESCRIPTION="research tool for commutative algebra and algebraic geometry" +SRC_BASE="http://www.math.uiuc.edu/${PN}/Downloads/" +SRC_URI="${SRC_BASE}/OtherSourceCode/1.3/factory-3-1-1.tar.gz + ${SRC_BASE}/OtherSourceCode/1.3/libfac-3-1-1.tar.gz + http://www.math.uiuc.edu/Macaulay2/Extra/gc-7.2alpha5-2010-09-03.tar.gz" + +HOMEPAGE="http://www.math.uiuc.edu/Macaulay2/" + +SLOT="0" +LICENSE="GPL-2" +KEYWORDS="" + +DEPEND="sys-libs/gdbm + >=dev-libs/ntl-5.5.2 + >=sci-mathematics/pari-2.3.4[gmp] + >=sys-libs/readline-6.1 + dev-libs/libxml2 + sci-mathematics/frobby + sci-mathematics/4ti2 + sci-mathematics/nauty + >=sci-mathematics/normaliz-2.5 + sci-mathematics/gfan + >=dev-libs/mpfr-3.0.0 + >=sci-libs/mpir-2.1.1[cxx] + sci-libs/cddlib + sci-libs/lrslib + virtual/blas + virtual/lapack + dev-util/ctags + sys-libs/ncurses + sys-process/time + emacs? ( virtual/emacs )" +RDEPEND="${DEPEND}" + +SITEFILE=70Macaulay2-gentoo.el + +S="${WORKDIR}/${PN}-${PV}" + +RESTRICT="mirror" + +pkg_setup () { + tc-export CC CPP CXX +} + +src_prepare() { + # Patching .m2 files to look for external programs in + # /usr/bin + epatch "${FILESDIR}"/${PV}-paths-of-external-programs.patch + + # This is now a configure option: +# if ! use optimization ; then +# epatch "${FILESDIR}"/respect-CFLAGS.patch +# fi + +## fixed in trunk as of 09/28/10 +# # The Posets-Package refers to a non-existent Graphs package. +# # We dump it for now. +# rm "${S}"/Macaulay2/packages/Posets.m2 +# sed -i "/ Posets/d" "${S}"/configure.ac +# sed -i "/Posets/d" "${S}"/Macaulay2/packages/Macaulay2Doc/changes.m2 + + # Fixing make warnings about unavailable jobserver: + sed -i "s/\$(MAKE)/+ \$(MAKE)/g" "${S}"/distributions/Makefile.in + + # Factory, and libfac are statically linked libraries which (in this flavor) + # are not used by any other program. We build them internally and don't install them + # Permission was granted to tomka by bicatali on IRC. + # Macaulay 2 in this version insists on a snapshot of boehm-gc that is not available elsewhere + # We will let it build its internal version for now. + mkdir "${S}/BUILD/tarfiles" || die "Creation of directory failed" + cp "${DISTDIR}/factory-3-1-1.tar.gz" "${S}/BUILD/tarfiles/" \ + || die "copy failed" + cp "${DISTDIR}/libfac-3-1-1.tar.gz" "${S}/BUILD/tarfiles/" \ + || die "copy failed" + cp "${DISTDIR}/gc-7.2alpha5-2010-09-03.tar.gz" "${S}/BUILD/tarfiles/" \ + || die "copy failed" + + eautoreconf +} + +src_configure (){ + + # Recommended in bug #268064 Possibly unecessary + # but should not hurt anybody. + if ! use emacs; then + tags="ctags" + fi + + CPPFLAGS="-I/usr/include/frobby" \ + ./configure --prefix="${D}/usr" \ + --disable-encap \ + --disable-strip \ + $(use_enable optimization optimize) \ + --enable-build-libraries="factory libfac" \ + --with-unbuilt-programs="4ti2 gfan normaliz nauty cddplus lrslib" \ + || die "failed to configure Macaulay" +} + +src_compile() { + # Parallel build not supported yet + emake -j1 || die "failed to build Macaulay" + + if use emacs; then + cd "${S}/Macaulay2/emacs" + elisp-compile *.el || die "elisp-compile failed" + fi +} + +src_test() { + emake check || die "tests failed" +} + +src_install () { + # Parallel install not supported yet + emake -j1 install || die "install failed" + + # Remove emacs files and install them in the + # correct place if use emacs + + rm -rf "${D}"/usr/share/emacs/site-lisp + if use emacs; then + cd "${S}/Macaulay2/emacs" + elisp-install ${PN} *.elc *.el || die "elisp-install failed" + elisp-site-file-install "${FILESDIR}/${SITEFILE}" + fi +} + +pkg_postinst() { + if use emacs; then + elisp-site-regen + elog "If you want to set a hot key for Macaulay2 in Emacs add a line similar to" + elog "(global-set-key [ f12 ] 'M2)" + elog "in order to set it to F12 (or choose a different one)." + fi +} +pkg_postrm() { + use emacs && elisp-site-regen +} diff --git a/sci-mathematics/Macaulay2/Manifest b/sci-mathematics/Macaulay2/Manifest index d0af48565..80772f0aa 100644 --- a/sci-mathematics/Macaulay2/Manifest +++ b/sci-mathematics/Macaulay2/Manifest @@ -1,3 +1,4 @@ +AUX 1.4_pre-paths-of-external-programs.patch 3175 RMD160 ad0f634b52b3fe883e49a53815481ca5b73d93c3 SHA1 4644c4b8c64678ca8205515436666651f467ee58 SHA256 162823069e075d7b7712db841d8c7bb8e1f03f2c33d4ade18e0b7a20543f5230 AUX 70Macaulay2-gentoo.el 597 RMD160 bdf3a30bb4d15a77e0dff86c866134d06c443fa0 SHA1 d4a4036042ab13bc20d8be90b559e9168bfc0ef5 SHA256 e5583d11e6ab662261abb32e90fcf31ccf6bd56f2b23b691b9255d1b8d8acb2f AUX 9999-paths-of-external-programs.patch 3175 RMD160 ad0f634b52b3fe883e49a53815481ca5b73d93c3 SHA1 4644c4b8c64678ca8205515436666651f467ee58 SHA256 162823069e075d7b7712db841d8c7bb8e1f03f2c33d4ade18e0b7a20543f5230 AUX paths-of-dependencies.patch 2437 RMD160 9b63baeee97428406bed8bfbf67cf6fead95974a SHA1 cf245ad8bcdbe119e127242119b2b96342100035 SHA256 bffbaaf077f99f1e135fe0eff61be702c6eb138f4b4ae715cec8c5be62ee8046 @@ -10,6 +11,7 @@ DIST libfac-3-1-0.tar.gz 91544 RMD160 2500d402328ad532756c677015c1d01f8594e394 S DIST libfac-3-1-1.tar.gz 90104 RMD160 8ca086ad2dc1dfbf3d8824e244f0b1af087eef62 SHA1 3753363a6f56cfeb0d0be3bdf471d6bd55c14ede SHA256 4c463af2d22375aa62be4fb1f9a32cada6723ca5e3ddbd8a4f5cab72b675e33a EBUILD Macaulay2-1.3.1-r3.ebuild 2651 RMD160 ca4332c7ccbffd35ea516f968a77dfbc01e9c8eb SHA1 0551b9803cff0ff7993e4ca90d70b12eec628f6c SHA256 6f957b390ffadf97dce4c91ba30376cca016be8c3d93dedc83e4be23a2a96e92 EBUILD Macaulay2-1.3.1-r4.ebuild 3323 RMD160 685a9e92768a913984f4b75e47bebac2c988d9ac SHA1 0247845b210eeb7b4f2e92764a99ca88b570e16e SHA256 07baf8dfcdc3ed2cf92db4f0a2530a3f63269452eab42c7d128f13c23ecf5d04 +EBUILD Macaulay2-1.4_pre.ebuild 4047 RMD160 f1ea5e493b19e709823971e937b72099267d47ca SHA1 5e26a833f90d33e14f1d91c0f0bfbe8725bc6c95 SHA256 de8b3fe715120ffdfe250749050cfeaf050ab70bc4d78eaa094421412c8f5a0f EBUILD Macaulay2-9999.ebuild 4035 RMD160 d6ca1392a273391d5dac7a6cf7adaffed674072b SHA1 7ea21110a461ae8055bc32eb0460c30136251f49 SHA256 cedae2be98b75f08151154569e70df8ef19e313cd21ab2a5a0f33f5499fcb63e -MISC ChangeLog 3073 RMD160 a59406cd37f57e5e2e13f704faf8c3b4f197b16a SHA1 d5be23b322b7650abd3b878bd1bb1a6a228eb79f SHA256 399e1d85a9cd2b02fc296f90373d7a1f5c788cf6f3c06f60241269fb0272ad8c +MISC ChangeLog 3260 RMD160 32175315190cc4055714c163c62b9d05724bc142 SHA1 e0c579ff8c08ea19d6771c366de7dfb87fc9064e SHA256 982aa36d2ab04f22cddb75ebb0c3d8cf1612c510134cc4d294e9e772fb2d05fb MISC metadata.xml 486 RMD160 0e913360cd4f3dd6b814bf44341c83005739a22b SHA1 83fb4a5ca743b184562281c8f1a5b8f722528514 SHA256 5937610a5ea0ddb9d15953121aa4f512f6ba8c2bcd35882a2dfe401f1dbddaa7 diff --git a/sci-mathematics/Macaulay2/files/1.4_pre-paths-of-external-programs.patch b/sci-mathematics/Macaulay2/files/1.4_pre-paths-of-external-programs.patch new file mode 100644 index 000000000..9b16e5a51 --- /dev/null +++ b/sci-mathematics/Macaulay2/files/1.4_pre-paths-of-external-programs.patch @@ -0,0 +1,61 @@ +diff -U 3 -dHrN M2source.orig/Macaulay2/packages/FourTiTwo.m2 M2source.patches/Macaulay2/packages/FourTiTwo.m2 +--- M2source.orig/Macaulay2/packages/FourTiTwo.m2 2010-09-19 02:32:45.000000000 +0200 ++++ M2source.patches/Macaulay2/packages/FourTiTwo.m2 2010-09-19 02:37:25.000000000 +0200 +@@ -47,7 +47,7 @@ + + path'4ti2 = (options FourTiTwo).Configuration#"path" + -- NOTE: the absolute path should be put into the .init file for 4ti2 inside the .Macaulay2 directory. +-if path'4ti2 == "" then path'4ti2 = prefixDirectory | currentLayout#"programs" ++if path'4ti2 == "" then path'4ti2 = "/usr/bin/" + + getFilename = () -> ( + filename := temporaryFileName(); +diff -U 3 -dHrN M2source.orig/Macaulay2/packages/gfanInterface.m2 M2source.patches/Macaulay2/packages/gfanInterface.m2 +--- M2source.orig/Macaulay2/packages/gfanInterface.m2 2010-09-19 02:32:45.000000000 +0200 ++++ M2source.patches/Macaulay2/packages/gfanInterface.m2 2010-09-19 02:38:08.000000000 +0200 +@@ -26,7 +26,7 @@ + } + + gfan'path = gfanInterface#Options#Configuration#"path" +-if gfan'path == "" then gfan'path = prefixDirectory | currentLayout#"programs" ++if gfan'path == "" then gfan'path = "/usr/bin/" + if instance(gfan'path, String) then gfan'path = {gfan'path} + if not instance(gfan'path,List) then error "expected configuration option gfan'path to be a list of strings or a string" + gfan'path = join( +diff -U 3 -dHrN M2source.orig/Macaulay2/packages/Nauty.m2 M2source.patches/Macaulay2/packages/Nauty.m2 +--- M2source.orig/Macaulay2/packages/Nauty.m2 2010-09-19 02:33:04.000000000 +0200 ++++ M2source.patches/Macaulay2/packages/Nauty.m2 2010-09-19 02:40:46.000000000 +0200 +@@ -27,7 +27,8 @@ + -- Check the ~/.Macaulay2/init-Nauty.m2 file for the absolute path. + -- If it's not there, then use the M2-Programs directory. + nauty'path = (options Nauty).Configuration#"path"; +-if nauty'path == "" then nauty'path = prefixDirectory | currentLayout#"programs"; ++if nauty'path == "" then nauty'path = "/usr/bin/"; ++ + + ------------------- + -- Exports +diff -U 3 -dHrN M2source.orig/Macaulay2/packages/Normaliz.m2 M2source.patches/Macaulay2/packages/Normaliz.m2 +--- M2source.orig/Macaulay2/packages/Normaliz.m2 2010-09-19 02:33:04.000000000 +0200 ++++ M2source.patches/Macaulay2/packages/Normaliz.m2 2010-09-19 02:39:12.000000000 +0200 +@@ -156,7 +156,7 @@ + nmzExec="norm64"; + ); + -- return nmzExec; +- return prefixDirectory | currentLayout#"programs" | nmzExec; ++ return "/usr/bin/" | nmzExec; + ); + + +diff -U 3 -dHrN M2source.orig/Macaulay2/packages/StatePolytope.m2 M2source.patches/Macaulay2/packages/StatePolytope.m2 +--- M2source.orig/Macaulay2/packages/StatePolytope.m2 2010-09-19 02:32:46.000000000 +0200 ++++ M2source.patches/Macaulay2/packages/StatePolytope.m2 2010-09-19 02:38:39.000000000 +0200 +@@ -31,7 +31,7 @@ + + + gfanCommand = (options StatePolytope)#Configuration#"gfan command" +-if gfanCommand === "gfan" then gfanCommand = prefixDirectory | currentLayout#"programs" | gfanCommand ++if gfanCommand === "gfan" then gfanCommand = "/usr/bin/" | gfanCommand + gfanCommand = "!" | gfanCommand + + --The next two functions print out the ring and the ideal in the format required by gfan |