summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJustin Lecher <jlec@gentoo.org>2014-05-07 11:00:43 +0000
committerJustin Lecher <jlec@gentoo.org>2014-05-07 11:00:43 +0000
commitd3c6c3b1506d3fa775e9e97ec58c8883ab3a0741 (patch)
treed07ae163b88b878395dcc40a5861b5f5f076958f /sci-biology
parentarm stable wrt bug #509684 (diff)
downloadgentoo-2-d3c6c3b1506d3fa775e9e97ec58c8883ab3a0741.tar.gz
gentoo-2-d3c6c3b1506d3fa775e9e97ec58c8883ab3a0741.tar.bz2
gentoo-2-d3c6c3b1506d3fa775e9e97ec58c8883ab3a0741.zip
sci-biology/biopython: Import changes from sci overlay
(Portage version: 2.2.10/cvs/Linux x86_64, signed Manifest commit with key B9D4F231BD1558AB!)
Diffstat (limited to 'sci-biology')
-rw-r--r--sci-biology/biopython/ChangeLog8
-rw-r--r--sci-biology/biopython/biopython-1.63-r1.ebuild52
-rw-r--r--sci-biology/biopython/files/SffIO_broken_padding.patch27
-rw-r--r--sci-biology/biopython/files/SffIO_error_in_check_eof.patch14
4 files changed, 100 insertions, 1 deletions
diff --git a/sci-biology/biopython/ChangeLog b/sci-biology/biopython/ChangeLog
index 119ccab60910..b15feab77d1a 100644
--- a/sci-biology/biopython/ChangeLog
+++ b/sci-biology/biopython/ChangeLog
@@ -1,6 +1,12 @@
# ChangeLog for sci-biology/biopython
# Copyright 1999-2014 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/sci-biology/biopython/ChangeLog,v 1.74 2014/01/30 15:15:24 jlec Exp $
+# $Header: /var/cvsroot/gentoo-x86/sci-biology/biopython/ChangeLog,v 1.75 2014/05/07 11:00:43 jlec Exp $
+
+*biopython-1.63-r1 (07 May 2014)
+
+ 07 May 2014; Justin Lecher <jlec@gentoo.org> +biopython-1.63-r1.ebuild,
+ +files/SffIO_broken_padding.patch, +files/SffIO_error_in_check_eof.patch:
+ Import changes from sci overlay
*biopython-1.63 (30 Jan 2014)
diff --git a/sci-biology/biopython/biopython-1.63-r1.ebuild b/sci-biology/biopython/biopython-1.63-r1.ebuild
new file mode 100644
index 000000000000..eeeb100d40fc
--- /dev/null
+++ b/sci-biology/biopython/biopython-1.63-r1.ebuild
@@ -0,0 +1,52 @@
+# Copyright 1999-2014 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/sci-biology/biopython/biopython-1.63-r1.ebuild,v 1.1 2014/05/07 11:00:43 jlec Exp $
+
+EAPI=5
+
+PYTHON_COMPAT=( python{2_6,2_7} )
+
+inherit distutils-r1 eutils
+
+DESCRIPTION="Python modules for computational molecular biology"
+HOMEPAGE="http://www.biopython.org/ http://pypi.python.org/pypi/biopython/"
+SRC_URI="http://www.biopython.org/DIST/${P}.tar.gz"
+
+LICENSE="HPND"
+SLOT="0"
+KEYWORDS="~amd64 ~ppc ~x86 ~amd64-linux ~x86-linux"
+IUSE="mysql postgres"
+
+REQUIRED_USE="${PYTHON_REQUIRED_USE}"
+
+RDEPEND="${PYTHON_DEPS}
+ dev-python/matplotlib[${PYTHON_USEDEP}]
+ dev-python/networkx[${PYTHON_USEDEP}]
+ dev-python/numpy[${PYTHON_USEDEP}]
+ dev-python/rdflib[${PYTHON_USEDEP}]
+ dev-python/pygraphviz[${PYTHON_USEDEP}]
+ dev-python/reportlab[${PYTHON_USEDEP}]
+ media-gfx/pydot[${PYTHON_USEDEP}]
+ mysql? ( dev-python/mysql-python[${PYTHON_USEDEP}] )
+ postgres? ( dev-python/psycopg[${PYTHON_USEDEP}] )"
+DEPEND="${RDEPEND}
+ sys-devel/flex"
+
+DOCS=( CONTRIB DEPRECATED NEWS README Doc/. )
+
+PATCHES=(
+ "${FILESDIR}/SffIO_error_in_check_eof.patch"
+ "${FILESDIR}/SffIO_broken_padding.patch"
+ )
+
+python_test() {
+ cd Tests || die
+ ${PYTHON} run_tests.py || die
+}
+
+python_install_all() {
+ distutils-r1_python_install_all
+
+ dodir /usr/share/${PN}
+ cp -r --preserve=mode Scripts Tests "${ED}"/usr/share/${PN} || die
+}
diff --git a/sci-biology/biopython/files/SffIO_broken_padding.patch b/sci-biology/biopython/files/SffIO_broken_padding.patch
new file mode 100644
index 000000000000..a009c58cbd04
--- /dev/null
+++ b/sci-biology/biopython/files/SffIO_broken_padding.patch
@@ -0,0 +1,27 @@
+diff --git a/Bio/SeqIO/SffIO.py b/Bio/SeqIO/SffIO.py
+index 735d55b..b89cf41 100644
+--- a/Bio/SeqIO/SffIO.py
++++ b/Bio/SeqIO/SffIO.py
+@@ -933,12 +933,20 @@ def _check_eof(handle, index_offset, index_length):
+ "null padding region ended '.sff' which could "
+ "be the start of a concatenated SFF file? "
+ "See offset %i" % (padding, offset))
++ if padding and not extra:
++ #TODO - Is this error harmless enough to just ignore?
++ import warnings
++ from Bio import BiopythonParserWarning
++ warnings.warn("Your SFF file is technically invalid as it is missing "
++ "a terminal %i byte null padding region." % padding,
++ BiopythonParserWarning)
++ return
+ if extra.count(_null) != padding:
+ import warnings
+ from Bio import BiopythonParserWarning
+ warnings.warn("Your SFF file is invalid, post index %i byte "
+- "null padding region contained data." % padding,
+- BiopythonParserWarning)
++ "null padding region contained data: %r"
++ % (padding, extra), BiopythonParserWarning)
+
+ offset = handle.tell()
+ assert offset % 8 == 0, \
diff --git a/sci-biology/biopython/files/SffIO_error_in_check_eof.patch b/sci-biology/biopython/files/SffIO_error_in_check_eof.patch
new file mode 100644
index 000000000000..9059604f6faa
--- /dev/null
+++ b/sci-biology/biopython/files/SffIO_error_in_check_eof.patch
@@ -0,0 +1,14 @@
+diff --git a/Bio/SeqIO/SffIO.py b/Bio/SeqIO/SffIO.py
+index 2bb0dac..735d55b 100644
+--- a/Bio/SeqIO/SffIO.py
++++ b/Bio/SeqIO/SffIO.py
+@@ -941,7 +941,8 @@ def _check_eof(handle, index_offset, index_length):
+ BiopythonParserWarning)
+
+ offset = handle.tell()
+- assert offset % 8 == 0
++ assert offset % 8 == 0, \
++ "Wanted offset %i %% 8 = %i to be zero" % (offset, offset % 8)
+ # Should now be at the end of the file...
+ extra = handle.read(4)
+ if extra == _sff: