summaryrefslogtreecommitdiff
path: root/dev-python/oct2py
diff options
context:
space:
mode:
Diffstat (limited to 'dev-python/oct2py')
-rw-r--r--dev-python/oct2py/Manifest7
-rw-r--r--dev-python/oct2py/files/oct2py-5.2.0-mask-pkg-load-test.patch10
-rw-r--r--dev-python/oct2py/oct2py-3.6.0.ebuild65
-rw-r--r--dev-python/oct2py/oct2py-5.2.0.ebuild (renamed from dev-python/oct2py/oct2py-4.0.6.ebuild)46
4 files changed, 34 insertions, 94 deletions
diff --git a/dev-python/oct2py/Manifest b/dev-python/oct2py/Manifest
index b5894f81f1b9..0ee6366bbcad 100644
--- a/dev-python/oct2py/Manifest
+++ b/dev-python/oct2py/Manifest
@@ -1,5 +1,4 @@
-DIST oct2py-3.6.0.tar.gz 668836 BLAKE2B 2edafd7c054a70a604273a7f3f5846926cb54dd05e7f2625aad57034d7760c099e9ad01120b719d3d047e6e6aa11f16e5fe8ca58e51079f038cea6d7aa3efe13 SHA512 f414a0231665bc3bedb7dcdaab8c86f32c140e5107ef80b70e2f99467e737d033de6ff492f2af7233671bff9b148475e0af4881c073ac727d0fd1228b7cf59b6
-DIST oct2py-4.0.6.tar.gz 431738 BLAKE2B d76fd323fa2405cd70dd1d4cbbdf64bbd346d45dc8065de0913d44d833f6d609d20ec8887cefeafdc4e59c382f862a8954b395557ff5ec127a67b1df2d560083 SHA512 997ca843571d2d68c4c57c0213a525c1be5f8b3e3dbffffb6cd41e423d68c8836dd12a03d5210d7f0cbf8ff19be7bb9d25b48c62a236cae68a0762547e574caa
-EBUILD oct2py-3.6.0.ebuild 1429 BLAKE2B 667980c3367e76fa7e3bf0e9cf3daa0885da9f25ba86bf1c35db162ccd9baa5cef41aecc84d2a4a9154023dfe1ac3f708790516dcca88ebbe6458bdb9e519d1b SHA512 e3aa34fe02c58ba077a4d675b9eb8e4170dcaf4a09bd506b40235e81bd2c5226d03562a2e44275a18ffd57103bf966e7f9d05a56c45620b1ae3ef9e164220d2d
-EBUILD oct2py-4.0.6.ebuild 1206 BLAKE2B fdb7df28d2b19e57178d5cdd3b7336deba02aba41627bab703293bdd7c34da4d9b617baf9956a8b38a64debaa80cdd0e592d4acbc7bf3e7d8725ddee04970726 SHA512 56851dff88a8762fcaa263058421abefbf83676f1fe920d3080af1a10bd30d5f129f2b65813e0a036404faca7c6e32bfec91ad8c90fc7401bc254eb80694d592
+AUX oct2py-5.2.0-mask-pkg-load-test.patch 384 BLAKE2B eb97b0f6fdf6df1bfc6907984ee1b223b9ec406c831c8c7f5908d3f5e130cddb85610487ee6eacf664e2e1859c3cc2ec1f5a22072d3dcac09b68bb631534e015 SHA512 44755cfd9725ef5e4dc572ac5e17954f023c4ae0bbe68ed984e696b485cf96bb15e11ee2d0a8a4a411237d0f5337269f13767af509554a9826fe572a7a2bfa71
+DIST oct2py-5.2.0.tar.gz 436128 BLAKE2B 674bd034a44aa9cdb5fd4258c96665fda1b1d79a13ae9fa8d36d168e39385a978ed75bf8748ecdd53f57720785ea8e6c5ffd85d81f3b3c307a748fbc8d328a86 SHA512 55c2ee68b4fd73a8901fa2f7f67fefde5fa37d5070434aee03bfa2a746ff5179f51ccb96541a112e416438eb912caa81e040a5a1cbcbfac36b0285d496ac96fd
+EBUILD oct2py-5.2.0.ebuild 1239 BLAKE2B 841a92e8634f7408e365705c35074559e40a5e9dd0e280988475a5a5fa93e996a78dcf4228f681985aacb2eaca9e30c37f648dfa5aeade4900851eab2ca65644 SHA512 3c1ec1c2c18279bbae0fc271addd4cb76486e13963042bcf1625a7d48fb75a4c9b61cb5d02caccb30c06a9fda0e5124c158e371d8a75264703ca4f11feb4a120
MISC metadata.xml 615 BLAKE2B 32a95461360131faf43212d3e419ba75a12f853749baf7f862499155d6f445492c311860ea5ee7c7e22c5e9586c722df8382cfe2eb6f67ac7bc1596f6cb9602a SHA512 e476f193cbbdefdf56caeb8a8a501f57daf1b74a12a32c426b6e9150ea0d5b2538b7bd9bbeb3b7f45ba01aa741be2fd0b4dbf8e8302e867230fc1b2512c10ca2
diff --git a/dev-python/oct2py/files/oct2py-5.2.0-mask-pkg-load-test.patch b/dev-python/oct2py/files/oct2py-5.2.0-mask-pkg-load-test.patch
new file mode 100644
index 000000000000..c233b45ec2c7
--- /dev/null
+++ b/dev-python/oct2py/files/oct2py-5.2.0-mask-pkg-load-test.patch
@@ -0,0 +1,10 @@
+--- a/oct2py/tests/test_usage.py
++++ b/oct2py/tests/test_usage.py
+@@ -338,6 +338,7 @@
+ with pytest.raises(Oct2PyError, match=exp):
+ self.oc.pyeval_like_error3(1)
+
++ @pytest.mark.skip(reason="requires octave 'signal' package to be installed")
+ def test_pkg_load(self):
+ self.oc.eval('pkg load signal')
+ t = np.linspace(0, 1, num=100)
diff --git a/dev-python/oct2py/oct2py-3.6.0.ebuild b/dev-python/oct2py/oct2py-3.6.0.ebuild
deleted file mode 100644
index 7439762cf917..000000000000
--- a/dev-python/oct2py/oct2py-3.6.0.ebuild
+++ /dev/null
@@ -1,65 +0,0 @@
-# Copyright 1999-2020 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=6
-
-PYTHON_COMPAT=( python3_6 )
-
-inherit distutils-r1
-
-DESCRIPTION="Python to GNU Octave bridge"
-HOMEPAGE="
- https://github.com/blink1073/oct2py
- https://blink1073.github.io/oct2py/"
-SRC_URI="mirror://pypi/${PN:0:1}/${PN}/${P}.tar.gz"
-
-LICENSE="MIT"
-SLOT="0"
-KEYWORDS="amd64 ~arm ~ppc ~ppc64 x86 ~amd64-linux ~x86-linux"
-IUSE="doc examples test"
-RESTRICT="!test? ( test )"
-
-RDEPEND="
- >=dev-python/numpy-1.7.1[${PYTHON_USEDEP}]
- >=sci-libs/scipy-0.12[${PYTHON_USEDEP}]
- >=sci-mathematics/octave-4.2.0"
-DEPEND="${RDEPEND}
- doc? (
- dev-python/sphinx-bootstrap-theme[${PYTHON_USEDEP}]
- dev-python/numpydoc[${PYTHON_USEDEP}]
- )
- test? (
- dev-python/nose[${PYTHON_USEDEP}]
- dev-python/ipython[${PYTHON_USEDEP}]
- )"
-
-python_prepare_all() {
- # https://github.com/blink1073/oct2py/issues/77
- sed \
- -e 's:test_help:disabled:g' \
- -i oct2py/tests/test_usage.py || die
-
- distutils-r1_python_prepare_all
-}
-
-python_compile_all() {
- if use doc; then
- sphinx-build docs html || die
- fi
-}
-
-python_test() {
- unset DISPLAY
- [[ ${EPYTHON} == python2.7 ]] && local OPTIONS="--with-doctest"
- nosetests --exe -v oct2py ${OPTIONS} || die "Tests fail with ${EPYTHON}"
-}
-
-python_install_all() {
- use doc && local HTML_DOCS=( html/. )
- if use examples; then
- docinto examples
- dodoc -r example/.
- fi
-
- distutils-r1_python_install_all
-}
diff --git a/dev-python/oct2py/oct2py-4.0.6.ebuild b/dev-python/oct2py/oct2py-5.2.0.ebuild
index 95327776d8b7..ddc73b701cdc 100644
--- a/dev-python/oct2py/oct2py-4.0.6.ebuild
+++ b/dev-python/oct2py/oct2py-5.2.0.ebuild
@@ -1,9 +1,9 @@
# Copyright 1999-2020 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
-EAPI=6
+EAPI=7
-PYTHON_COMPAT=( python3_6 )
+PYTHON_COMPAT=( python3_{6..9} )
inherit distutils-r1
@@ -16,39 +16,35 @@ SRC_URI="mirror://pypi/${PN:0:1}/${PN}/${P}.tar.gz"
LICENSE="MIT"
SLOT="0"
KEYWORDS="~amd64 ~x86 ~amd64-linux ~x86-linux"
-IUSE="doc examples test"
-RESTRICT="!test? ( test )"
+IUSE="examples"
RDEPEND="
- >=dev-python/numpy-1.11[${PYTHON_USEDEP}]
- dev-python/octave_kernel[${PYTHON_USEDEP}]
- >=sci-libs/scipy-0.17[${PYTHON_USEDEP}]
-"
-DEPEND="${RDEPEND}
- doc? (
- dev-python/numpydoc[${PYTHON_USEDEP}]
- dev-python/sphinx[${PYTHON_USEDEP}]
- dev-python/sphinx-bootstrap-theme[${PYTHON_USEDEP}]
- )
+ >=dev-python/numpy-1.12[${PYTHON_USEDEP}]
+ >=dev-python/octave_kernel-0.31.0[${PYTHON_USEDEP}]
+ >=sci-libs/scipy-0.17[${PYTHON_USEDEP}]"
+BDEPEND="
test? (
- dev-python/pytest[${PYTHON_USEDEP}]
dev-python/ipython[${PYTHON_USEDEP}]
- )
-"
-python_compile_all() {
- if use doc; then
- sphinx-build docs html || die
- HTML_DOCS=( html/. )
- fi
-}
+ dev-python/pandas[${PYTHON_USEDEP}]
+ )"
+
+distutils_enable_sphinx docs \
+ dev-python/numpydoc dev-python/sphinx-bootstrap-theme dev-python/sphinx_rtd_theme
+distutils_enable_tests pytest
+
+PATCHES=( "${FILESDIR}"/${PN}-5.2.0-mask-pkg-load-test.patch )
python_test() {
- cd "${BUILD_DIR}/lib" || die
- py.test -v -v || die
+ cd "${BUILD_DIR}"/lib || die
+ pytest -vv || die "Tests fail with ${EPYTHON}"
+
+ # remove cache which breaks python_install()
+ rm -r .pytest_cache || die
}
python_install_all() {
distutils-r1_python_install_all
+
if use examples; then
docinto examples
dodoc -r example/.