summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPacho Ramos <pacho@gentoo.org>2020-09-12 10:42:12 +0200
committerPacho Ramos <pacho@gentoo.org>2020-09-12 10:43:34 +0200
commit0ebaba15bd34846ab1d803a212ed01d8da5854e0 (patch)
tree98bfaa3406d47fca6a726ee69786a1476a97fdbb /sci-chemistry/molequeue
parentapp-crypt/tpm2-pkcs11: Remove old (diff)
downloadgentoo-0ebaba15bd34846ab1d803a212ed01d8da5854e0.tar.gz
gentoo-0ebaba15bd34846ab1d803a212ed01d8da5854e0.tar.bz2
gentoo-0ebaba15bd34846ab1d803a212ed01d8da5854e0.zip
sci-chemistry/molequeue: Switch to python3
- Switch to python3, bug #735464 - python is not always needed, bug #710454 - Port to cmake.eclass - Drop unneeded patch that was breaking configure with tests. Restrict tests as they are broken anyway. - Update virtualx.eclass usage Bug: https://bugs.gentoo.org/735464 Closes: https://bugs.gentoo.org/741422 Closes: https://bugs.gentoo.org/710454 Thanks-to: Samuel Bauer Package-Manager: Portage-3.0.4, Repoman-3.0.1 Signed-off-by: Pacho Ramos <pacho@gentoo.org>
Diffstat (limited to 'sci-chemistry/molequeue')
-rw-r--r--sci-chemistry/molequeue/molequeue-0.9.0-r1.ebuild91
1 files changed, 91 insertions, 0 deletions
diff --git a/sci-chemistry/molequeue/molequeue-0.9.0-r1.ebuild b/sci-chemistry/molequeue/molequeue-0.9.0-r1.ebuild
new file mode 100644
index 000000000000..f9c43a6463b2
--- /dev/null
+++ b/sci-chemistry/molequeue/molequeue-0.9.0-r1.ebuild
@@ -0,0 +1,91 @@
+# Copyright 1999-2020 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+PYTHON_COMPAT=( python3_{6..9} )
+
+inherit cmake python-r1 virtualx
+
+DESCRIPTION="Abstract, manage and coordinate execution of tasks"
+HOMEPAGE="https://www.openchemistry.org/projects/molequeue/"
+SRC_URI="https://github.com/OpenChemistry/molequeue/archive/${PV}.tar.gz -> ${P}.tar.gz"
+
+SLOT="0"
+LICENSE="BSD"
+KEYWORDS="~amd64 ~x86 ~amd64-linux ~x86-linux"
+
+IUSE="+client doc server test +zeromq"
+RESTRICT="!test? ( test )"
+
+REQUIRED_USE="
+ server? ( client )
+ test? ( server )
+ zeromq? ( ${PYTHON_REQUIRED_USE} )
+"
+
+BDEPEND="
+ doc? ( app-doc/doxygen )
+"
+RDEPEND="
+ dev-qt/qtcore:5
+ dev-qt/qtgui:5
+ dev-qt/qtnetwork:5
+ dev-qt/qtwidgets:5
+ zeromq? (
+ ${PYTHON_DEPS}
+ net-libs/cppzmq:0=
+ )
+"
+DEPEND="${RDEPEND}"
+
+# Some tests still fail
+RESTRICT="test"
+
+src_configure() {
+ configuration() {
+ local mycmakeargs=(
+ -DMoleQueue_USE_EZHPC_UIT=OFF
+ -DBUILD_DOCUMENTATION=$(usex doc)
+ -DMoleQueue_BUILD_CLIENT=$(usex client)
+ -DMoleQueue_BUILD_APPLICATION=$(usex server)
+ -DENABLE_TESTING=$(usex test)
+ -DUSE_ZERO_MQ=$(usex zeromq)
+ -DINSTALL_LIBRARY_DIR=$(get_libdir)
+ )
+ use zeromq && \
+ mycmakeargs+=( -DZeroMQ_ROOT_DIR=\"${EPREFIX}/usr\" )
+
+ cmake_src_configure
+ }
+ if use zeromq; then
+ python_foreach_impl run_in_build_dir configuration
+ else
+ configuration
+ fi
+}
+
+src_compile() {
+ if use zeromq; then
+ python_foreach_impl run_in_build_dir cmake_src_compile all $(usex doc documentation "")
+ else
+ cmake_src_compile all $(usex doc documentation "")
+ fi
+}
+
+src_test() {
+ if use zeromq; then
+ python_foreach_impl run_in_build_dir virtx cmake_src_test
+ else
+ virtx cmake_src_test
+ fi
+}
+
+src_install() {
+ use doc && local HTML_DOCS=( "${BUILD_DIR}"/docs/html/. )
+ if use zeromq; then
+ python_foreach_impl run_in_build_dir cmake_src_install
+ python_foreach_impl run_in_build_dir python_optimize
+ else
+ cmake_src_install
+ fi
+}