dev-python/scikit-learn: New package
authorPatrick McLean <patrick.mclean@sony.com>
Wed, 1 Apr 2020 21:02:43 +0000 (14:02 -0700)
committerPatrick McLean <chutzpah@gentoo.org>
Wed, 1 Apr 2020 21:04:07 +0000 (14:04 -0700)
Copyright: Sony Interactive Entertainment Inc.
Package-Manager: Portage-2.3.96, Repoman-2.3.22
Signed-off-by: Patrick McLean <chutzpah@gentoo.org>
dev-python/scikit-learn/Manifest [new file with mode: 0644]
dev-python/scikit-learn/metadata.xml [new file with mode: 0644]
dev-python/scikit-learn/scikit-learn-0.22.2_p1.ebuild [new file with mode: 0644]

diff --git a/dev-python/scikit-learn/Manifest b/dev-python/scikit-learn/Manifest
new file mode 100644 (file)
index 0000000..8e745c8
--- /dev/null
@@ -0,0 +1 @@
+DIST scikit-learn-0.22.2_p1.tar.gz 7034850 BLAKE2B 41c362ef6594e837a9fc798837e666fbb51e33954fdf700292650204fd9d1ab4fc4d1695890d02a24ad68f4dcc2d3cde8f0827eca70c6fb9a6f0e5c0d9c04fd5 SHA512 20bcda5c65f76bce9b71c5b5fb1b499f7f3a7a3f6fa5fade80a38dc658cb434e16e9d5a4906a9657157a5cc90a6d51080575d6e510207baa9f8b06c4fa761d5b
diff --git a/dev-python/scikit-learn/metadata.xml b/dev-python/scikit-learn/metadata.xml
new file mode 100644 (file)
index 0000000..56cae16
--- /dev/null
@@ -0,0 +1,8 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+  <maintainer type="person">
+    <email>chutzpah@gentoo.org</email>
+    <name>Patrick McLean</name>
+  </maintainer>
+</pkgmetadata>
diff --git a/dev-python/scikit-learn/scikit-learn-0.22.2_p1.ebuild b/dev-python/scikit-learn/scikit-learn-0.22.2_p1.ebuild
new file mode 100644 (file)
index 0000000..c67f8b4
--- /dev/null
@@ -0,0 +1,41 @@
+# Copyright 2020 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+PYTHON_COMPAT=( python3_{6,7,8} )
+inherit distutils-r1
+
+MY_PV="${PV//_p/.post}"
+DESCRIPTION="Machine learning library for Python"
+HOMEPAGE="https://scikit-learn.org/stable/
+       https://github.com/scikit-learn/scikit-learn"
+SRC_URI="https://github.com/${PN}/${PN}/archive/${MY_PV}.tar.gz -> ${P}.tar.gz"
+S="${WORKDIR}/${PN}-${MY_PV}"
+
+LICENSE="BSD"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE="test"
+RESTRICT="!test? ( test )"
+
+RDEPEND="
+       dev-python/wheel[${PYTHON_USEDEP}]
+       dev-python/cython[${PYTHON_USEDEP}]
+       dev-python/numpy[${PYTHON_USEDEP}]
+       sci-libs/scipy[${PYTHON_USEDEP}]
+"
+BDEPEND="${RDEPEND}
+       test? (
+               dev-python/joblib[${PYTHON_USEDEP}]
+       )
+"
+
+distutils_enable_tests pytest
+
+python_test() {
+       distutils_install_for_testing
+       pushd "${TEST_DIR}/lib" >/dev/null || die
+       pytest -vv || die "testing failed with ${EPYTHON}"
+       popd >/dev/null || die
+}