summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlfredo Tupone <tupone@gentoo.org>2024-02-19 22:28:25 +0100
committerAlfredo Tupone <tupone@gentoo.org>2024-02-19 22:29:07 +0100
commit31b343d6ff49561e71151fdedd9634385656f764 (patch)
tree36481fde773bd60d6a74a6c8d4b3307d15d220c5 /sci-libs
parentsys-fs/mdadm: QA fix missing udev_reload (diff)
downloadgentoo-31b343d6ff49561e71151fdedd9634385656f764.tar.gz
gentoo-31b343d6ff49561e71151fdedd9634385656f764.tar.bz2
gentoo-31b343d6ff49561e71151fdedd9634385656f764.zip
sci-libs/onnx: always depends on python
Closes: https://bugs.gentoo.org/924937 Signed-off-by: Alfredo Tupone <tupone@gentoo.org>
Diffstat (limited to 'sci-libs')
-rw-r--r--sci-libs/onnx/onnx-1.15.0-r1.ebuild (renamed from sci-libs/onnx/onnx-1.15.0.ebuild)44
1 files changed, 24 insertions, 20 deletions
diff --git a/sci-libs/onnx/onnx-1.15.0.ebuild b/sci-libs/onnx/onnx-1.15.0-r1.ebuild
index 1e57c8b8213f..8e846b3e6d5f 100644
--- a/sci-libs/onnx/onnx-1.15.0.ebuild
+++ b/sci-libs/onnx/onnx-1.15.0-r1.ebuild
@@ -1,9 +1,8 @@
-# Copyright 2022-2023 Gentoo Authors
+# Copyright 2022-2024 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
DISTUTILS_USE_PEP517=setuptools
-DISTUTILS_OPTIONAL=1
DISTUTILS_EXT=1
PYTHON_COMPAT=( python3_{9..12} )
inherit distutils-r1 cmake
@@ -16,44 +15,49 @@ SRC_URI="https://github.com/onnx/${PN}/archive/refs/tags/v${PV}.tar.gz
LICENSE="Apache-2.0"
SLOT="0"
KEYWORDS="~amd64 ~riscv"
-IUSE="python"
RESTRICT="test"
-REQUIRED_USE="python? ( ${PYTHON_REQUIRED_USE} )"
RDEPEND="
- python? (
- ${PYTHON_DEPS}
- dev-python/protobuf-python[${PYTHON_USEDEP}]
- dev-python/pybind11[${PYTHON_USEDEP}]
- )
+ dev-python/protobuf-python[${PYTHON_USEDEP}]
+ dev-python/pybind11[${PYTHON_USEDEP}]
dev-libs/protobuf:=
"
DEPEND="${RDEPEND}"
-BDEPEND="python? (
- ${DISTUTILS_DEPS}
-)"
-
src_prepare() {
cmake_src_prepare
- use python && distutils-r1_src_prepare
+ distutils-r1_src_prepare
}
-src_configure() {
+python_configure_all() {
mycmakeargs=(
-DONNX_USE_PROTOBUF_SHARED_LIBS=ON
-DONNX_USE_LITE_PROTO=ON
)
cmake_src_configure
- use python && distutils-r1_src_configure
}
-src_compile() {
+src_configure() {
+ distutils-r1_src_configure
+}
+
+python_compile_all() {
cmake_src_compile
- use python && CMAKE_ARGS="${mycmakeargs[@]}" distutils-r1_src_compile
}
-src_install() {
+src_compile() {
+ mycmakeargs=(
+ -DONNX_USE_PROTOBUF_SHARED_LIBS=ON
+ -DONNX_USE_LITE_PROTO=ON
+ )
+ CMAKE_ARGS="${mycmakeargs[@]}" distutils-r1_src_compile
+}
+
+python_install_all() {
cmake_src_install
- use python && distutils-r1_src_install
+ distutils-r1_python_install_all
+}
+
+src_install() {
+ distutils-r1_src_install
}