summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJustin Lecher <jlec@gentoo.org>2010-02-06 21:50:41 +0000
committerJustin Lecher <jlec@gentoo.org>2010-02-06 21:50:41 +0000
commit1bd1a7e84bbb1147936b2a1fd01009a59c3a6a63 (patch)
treea3684cc09e5e50c677464864253004eb8c2a2d0f /sci-chemistry/aria
parentAdded aria support per 220905 (diff)
downloadhistorical-1bd1a7e84bbb1147936b2a1fd01009a59c3a6a63.tar.gz
historical-1bd1a7e84bbb1147936b2a1fd01009a59c3a6a63.tar.bz2
historical-1bd1a7e84bbb1147936b2a1fd01009a59c3a6a63.zip
inital commit
Package-Manager: portage-2.2_rc62/cvs/Linux x86_64
Diffstat (limited to 'sci-chemistry/aria')
-rw-r--r--sci-chemistry/aria/ChangeLog11
-rw-r--r--sci-chemistry/aria/aria-2.2_p2.ebuild92
-rw-r--r--sci-chemistry/aria/files/2.2_p2-numpy.patch82
-rw-r--r--sci-chemistry/aria/files/2.2_p2-test.patch13
-rw-r--r--sci-chemistry/aria/files/sa_ls_cool2.patch12
-rw-r--r--sci-chemistry/aria/metadata.xml8
6 files changed, 218 insertions, 0 deletions
diff --git a/sci-chemistry/aria/ChangeLog b/sci-chemistry/aria/ChangeLog
new file mode 100644
index 000000000000..4f99e2d830ed
--- /dev/null
+++ b/sci-chemistry/aria/ChangeLog
@@ -0,0 +1,11 @@
+# ChangeLog for sci-chemistry/aria
+# Copyright 1999-2010 Gentoo Foundation; Distributed under the GPL v2
+# $Header: /var/cvsroot/gentoo-x86/sci-chemistry/aria/ChangeLog,v 1.1 2010/02/06 21:50:40 jlec Exp $
+
+*aria-2.2_p2 (06 Feb 2010)
+
+ 06 Feb 2010; Justin Lecher (jlec) <jlec@gentoo.org>
+ +files/2.2_p2-numpy.patch, +aria-2.2_p2.ebuild, +files/2.2_p2-test.patch,
+ +files/sa_ls_cool2.patch, +metadata.xml:
+ Initial commit
+
diff --git a/sci-chemistry/aria/aria-2.2_p2.ebuild b/sci-chemistry/aria/aria-2.2_p2.ebuild
new file mode 100644
index 000000000000..d3f16a96de4d
--- /dev/null
+++ b/sci-chemistry/aria/aria-2.2_p2.ebuild
@@ -0,0 +1,92 @@
+# Copyright 1999-2010 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/sci-chemistry/aria/aria-2.2_p2.ebuild,v 1.1 2010/02/06 21:50:40 jlec Exp $
+
+EAPI="3"
+
+SUPPORT_PYTHON_ABIS="1"
+PYTHON_USE_WITH="tk"
+
+inherit base python eutils versionator
+
+MY_P="${PN}$(get_version_component_range 1-2 ${PV})"
+
+DESCRIPTION="Software for automated NOE assignment and NMR structure calculation."
+HOMEPAGE="http://aria.pasteur.fr/"
+SRC_URI="http://aria.pasteur.fr/archives/${MY_P}.tar.gz"
+
+SLOT="0"
+LICENSE="cns"
+KEYWORDS="~amd64 ~x86"
+IUSE="examples"
+
+RDEPEND="
+ dev-python/numpy
+ dev-python/matplotlib[tk]
+ sci-chemistry/cns[aria,openmp]
+ >=dev-lang/tk-8.3
+ >=dev-python/scientificpython-2.7.3
+ >=sci-chemistry/ccpn-2.0.5
+ >=dev-tcltk/tix-8.1.4"
+DEPEND="${RDEPENED}"
+RESTRICT_PYTHON_ABIS="3.*"
+
+RESTRICT="fetch"
+
+S="${WORKDIR}/${PN}2.2"
+
+src_prepare() {
+ epatch "${FILESDIR}"/sa_ls_cool2.patch
+ epatch "${FILESDIR}"/${PV}-numpy.patch
+ epatch "${FILESDIR}"/${PV}-test.patch
+ python_copy_sources --no-link
+}
+
+pkg_nofetch(){
+ einfo "Go to ${HOMEPAGE}, download ${A}"
+ einfo "and place it in ${DISTDIR}"
+}
+
+src_test(){
+ test() {
+ export CCPNMR_TOP_DIR="${EPREFIX}"/$(python_get_sitedir)
+ export PYTHONPATH=.:${CCPNMR_TOP_DIR}/ccpn/python
+ $(PYTHON) check.py || die
+ }
+ python_execute_function -s test
+}
+
+src_install(){
+ installation() {
+ insinto "$(python_get_sitedir)/${PN}"
+ doins -r src aria2.py || die "failed to install ${PN}"
+ insinto "$(python_get_sitedir)/${PN}"/cns
+ doins -r cns/{protocols,toppar,src/helplib} || die "failed to install cns part"
+ }
+ python_execute_function -s installation
+
+ if use examples; then
+ insinto /usr/share/${P}/
+ doins -r examples
+ fi
+
+ # ENV
+ cat >> "${T}"/20aria <<- EOF
+ ARIA2="${EPREFIX}/$(python_get_sitedir -f)/${PN}"
+ EOF
+
+ doenvd "${T}"/20aria
+
+ # Launch Wrapper
+ cat >> "${T}"/aria <<- EOF
+ #!/bin/sh
+ export CCPNMR_TOP_DIR="${EPREFIX}/$(python_get_sitedir -f)"
+ export PYTHONPATH="${EPREFIX}/$(python_get_sitedir -f)/ccpn/python"
+ exec "$(PYTHON -f)" -O "\${ARIA2}"/aria2.py \$@
+ EOF
+
+ dobin "${T}"/aria || die "failed to install wrapper"
+ dosym aria /usr/bin/aria2
+
+ dodoc README || die
+}
diff --git a/sci-chemistry/aria/files/2.2_p2-numpy.patch b/sci-chemistry/aria/files/2.2_p2-numpy.patch
new file mode 100644
index 000000000000..40d81964d9c2
--- /dev/null
+++ b/sci-chemistry/aria/files/2.2_p2-numpy.patch
@@ -0,0 +1,82 @@
+diff -arNu aria2.2/aria2.py aria2.2.new/aria2.py
+--- aria2.2/aria2.py 2008-02-14 11:02:31.000000000 +0100
++++ aria2.2.new/aria2.py 2009-07-14 12:01:02.000000000 +0200
+@@ -427,7 +427,7 @@
+
+ def check_numeric_slice():
+
+- msg = "\nThe version of Numeric (%s) is known to be incompatible with ARIA.\nConsider reverting to a more stable version (like 23.8).\n"
++ msg = "\nThe version of Numeric (%s) is known to be incompatible with ARIA.\nSo we are using numpy instead.\n"
+
+ try:
+ from Numeric import ones, __version__ as NUMERIC_VERSION
+diff -arNu aria2.2/check.py aria2.2.new/check.py
+--- aria2.2/check.py 2009-07-14 11:50:54.000000000 +0200
++++ aria2.2.new/check.py 2009-07-14 12:02:56.000000000 +0200
+@@ -55,18 +55,6 @@
+ failed = 0
+
+ try:
+- import Numeric
+- msg += 'ok (numeric).'
+-
+- except:
+- #msg = 'could not import Numeric module.'
+- failed = 1
+-
+- if not failed:
+- print msg
+- return 'numeric'#, None
+-
+- try:
+ import numpy.oldnumeric
+ version = LooseVersion(numpy.oldnumeric.__version__)
+
+@@ -79,14 +67,14 @@
+ msg += 'version > %s required for Numpy' % str(NUMPY_MIN_VERSION)
+
+ except:
+- msg += 'could not import Numeric/Numpy module.'
++ msg += 'could not import Numpy module.'
+
+ print msg
+ return None
+
+ def check_numeric_slice():
+
+- msg = "\nWARNING: This version of Numeric (%s) is known to be incompatible with ARIA.\nConsider reverting to a more stable version (like 23.8).\n"
++ msg = "\nWARNING: This version of Numeric (%s) is known to be incompatible with ARIA.\nSo we use numpy instead.\n"
+
+ from Numeric import ones, __version__ as NUMERIC_VERSION
+ if not ones(10)[2:]:
+diff -arNu aria2.2/src/py/Merger.py aria2.2.new/src/py/Merger.py
+--- aria2.2/src/py/Merger.py 2007-03-05 16:50:12.000000000 +0100
++++ aria2.2.new/src/py/Merger.py 2009-07-14 12:06:55.000000000 +0200
+@@ -213,12 +213,9 @@
+ new_long = []
+
+ try:
+- from RandomArray import permutation
++ from numpy.oldnumeric.random_array import permutation
+ except:
+- try:
+- from numpy.oldnumeric.random_array import permutation
+- except:
+- return n, []
++ return n, []
+
+ ids = permutation(len(long_range))
+
+diff -arNu aria2.2/src/py/N.py aria2.2.new/src/py/N.py
+--- aria2.2/src/py/N.py 2007-12-04 17:01:46.000000000 +0100
++++ aria2.2.new/src/py/N.py 2009-07-14 12:07:16.000000000 +0200
+@@ -1,7 +1,4 @@
+ try:
+- from Numeric import *
++ from numpy.oldnumeric import *
+ except:
+- try:
+- from numpy.oldnumeric import *
+- except:
+- pass
++ pass
diff --git a/sci-chemistry/aria/files/2.2_p2-test.patch b/sci-chemistry/aria/files/2.2_p2-test.patch
new file mode 100644
index 000000000000..991a168ab3a5
--- /dev/null
+++ b/sci-chemistry/aria/files/2.2_p2-test.patch
@@ -0,0 +1,13 @@
+diff --git a/check.py b/check.py
+index 6592951..47772f5 100644
+--- a/check.py
++++ b/check.py
+@@ -170,8 +170,6 @@ if __name__ == '__main__':
+ print 'Checking Python environment...\n'
+
+ check_python()
+- numeric = check_numeric()
+- check_numeric_slice()
+ scientific = check_scientific()
+ check_tix()
+ check_ccpn()
diff --git a/sci-chemistry/aria/files/sa_ls_cool2.patch b/sci-chemistry/aria/files/sa_ls_cool2.patch
new file mode 100644
index 000000000000..d52666a883f9
--- /dev/null
+++ b/sci-chemistry/aria/files/sa_ls_cool2.patch
@@ -0,0 +1,12 @@
+--- aria2.2/cns/protocols/sa_ls_cool2.cns.orig 2008-05-07 18:39:59.000000000 +0200
++++ aria2.2/cns/protocols/sa_ls_cool2.cns 2008-05-07 18:40:29.000000000 +0200
+@@ -33,8 +33,8 @@
+ masym dist &Data.masy_cool2
+ masym hbon &Data.masy_cool2
+
+- scale ambi &Data.amb_cool2
+ scale dist &Data.unamb_cool2
++ scale ambi &Data.amb_cool2
+ scale hbon &Data.hbond_cool2
+ end
+
diff --git a/sci-chemistry/aria/metadata.xml b/sci-chemistry/aria/metadata.xml
new file mode 100644
index 000000000000..c6856dc7f2cf
--- /dev/null
+++ b/sci-chemistry/aria/metadata.xml
@@ -0,0 +1,8 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+<herd>sci</herd>
+<maintainer>
+ <email>jlec@gentoo.org</email>
+</maintainer>
+</pkgmetadata>