summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'sci-chemistry')
-rw-r--r--sci-chemistry/GromacsWrapper/GromacsWrapper-0.8.0-r1.ebuild6
-rw-r--r--sci-chemistry/MDAnalysis/MDAnalysis-1.0.0.ebuild4
-rw-r--r--sci-chemistry/MDAnalysis/MDAnalysis-2.0.0.ebuild37
-rw-r--r--sci-chemistry/MDAnalysis/Manifest1
-rw-r--r--sci-chemistry/autodock_vina/metadata.xml7
-rw-r--r--sci-chemistry/chemex/Manifest3
-rw-r--r--sci-chemistry/chemex/chemex-2021.4.0_p2.ebuild43
-rw-r--r--sci-chemistry/chemex/chemex-2021.4.0_p6.ebuild (renamed from sci-chemistry/chemex/chemex-2021.4.0_p4.ebuild)2
-rw-r--r--sci-chemistry/cluster/cluster-1.3.081231-r1.ebuild19
-rw-r--r--sci-chemistry/dssp/Manifest1
-rw-r--r--sci-chemistry/dssp/dssp-2.2.1-r2.ebuild45
-rw-r--r--sci-chemistry/dssp/dssp-3.0.11.ebuild5
-rw-r--r--sci-chemistry/dssp/dssp-4.0.1_p20210831.ebuild33
-rw-r--r--sci-chemistry/dssp/dssp-4.0.3.ebuild2
-rw-r--r--sci-chemistry/gnome-chemistry-utils/gnome-chemistry-utils-0.14.17_p6-r1.ebuild (renamed from sci-chemistry/gnome-chemistry-utils/gnome-chemistry-utils-0.14.17_p6.ebuild)12
-rw-r--r--sci-chemistry/gromacs/Manifest6
-rw-r--r--sci-chemistry/gromacs/files/gromacs-2019.6-missing-include.patch38
-rw-r--r--sci-chemistry/gromacs/gromacs-2018.8-r1.ebuild (renamed from sci-chemistry/gromacs/gromacs-2018.8.ebuild)4
-rw-r--r--sci-chemistry/gromacs/gromacs-2019.6-r1.ebuild (renamed from sci-chemistry/gromacs/gromacs-2019.6.ebuild)6
-rw-r--r--sci-chemistry/gromacs/gromacs-2019.6-r2.ebuild255
-rw-r--r--sci-chemistry/gromacs/gromacs-2020.4-r1.ebuild (renamed from sci-chemistry/gromacs/gromacs-2020.4.ebuild)6
-rw-r--r--sci-chemistry/gromacs/gromacs-2020.6-r1.ebuild (renamed from sci-chemistry/gromacs/gromacs-2020.6.ebuild)6
-rw-r--r--sci-chemistry/gromacs/gromacs-2021.2-r1.ebuild (renamed from sci-chemistry/gromacs/gromacs-2021.2.ebuild)4
-rw-r--r--sci-chemistry/gromacs/gromacs-2021.3-r1.ebuild (renamed from sci-chemistry/gromacs/gromacs-2021.3.ebuild)4
-rw-r--r--sci-chemistry/gromacs/gromacs-2021.4.ebuild356
-rw-r--r--sci-chemistry/gromacs/gromacs-2021.9999.ebuild4
-rw-r--r--sci-chemistry/gromacs/gromacs-2022.9999.ebuild349
-rw-r--r--sci-chemistry/gromacs/gromacs-2022_beta1-r2.ebuild349
-rw-r--r--sci-chemistry/gromacs/gromacs-9999.ebuild37
-rw-r--r--sci-chemistry/mdtraj/Manifest1
-rw-r--r--sci-chemistry/mdtraj/mdtraj-1.9.7.ebuild42
-rw-r--r--sci-chemistry/moldy/moldy-2.16e-r2.ebuild4
-rw-r--r--sci-chemistry/molmol/molmol-2k_p2-r5.ebuild4
-rw-r--r--sci-chemistry/molscript/molscript-2.1.2-r2.ebuild2
-rw-r--r--sci-chemistry/mopac7/mopac7-1.15-r1.ebuild2
-rw-r--r--sci-chemistry/openbabel/Manifest2
-rw-r--r--sci-chemistry/openbabel/files/openbabel-2.3.2-gcc-6_and_7-backport.patch13
-rw-r--r--sci-chemistry/openbabel/files/openbabel-2.4.1-gcc-8.patch15
-rw-r--r--sci-chemistry/openbabel/files/openbabel-python.cmake104
-rw-r--r--sci-chemistry/openbabel/metadata.xml4
-rw-r--r--sci-chemistry/openbabel/openbabel-2.4.1-r1.ebuild102
-rw-r--r--sci-chemistry/openbabel/openbabel-3.1.1_p20210225.ebuild272
-rw-r--r--sci-chemistry/openbabel/openbabel-9999.ebuild272
-rw-r--r--sci-chemistry/probe/probe-2.13.110909.ebuild2
-rw-r--r--sci-chemistry/pymol/Manifest1
-rw-r--r--sci-chemistry/pymol/files/pymol-2.4.0-fix_bug119.patch34
-rw-r--r--sci-chemistry/pymol/pymol-2.4.0-r1.ebuild116
-rw-r--r--sci-chemistry/tm-align/tm-align-20150914.ebuild4
-rw-r--r--sci-chemistry/vmd/Manifest1
-rw-r--r--sci-chemistry/vmd/vmd-1.9.4_alpha55.ebuild269
-rw-r--r--sci-chemistry/votca/Manifest2
-rw-r--r--sci-chemistry/votca/metadata.xml18
-rw-r--r--sci-chemistry/votca/votca-2022.ebuild70
-rw-r--r--sci-chemistry/votca/votca-2022_rc2.ebuild70
-rw-r--r--sci-chemistry/votca/votca-9999.ebuild70
55 files changed, 2657 insertions, 483 deletions
diff --git a/sci-chemistry/GromacsWrapper/GromacsWrapper-0.8.0-r1.ebuild b/sci-chemistry/GromacsWrapper/GromacsWrapper-0.8.0-r1.ebuild
index 8f747a7a5ac..e6354fb05f9 100644
--- a/sci-chemistry/GromacsWrapper/GromacsWrapper-0.8.0-r1.ebuild
+++ b/sci-chemistry/GromacsWrapper/GromacsWrapper-0.8.0-r1.ebuild
@@ -1,9 +1,9 @@
-# Copyright 1999-2021 Gentoo Authors
+# Copyright 1999-2022 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
-PYTHON_COMPAT=( python3_{7..9} )
+PYTHON_COMPAT=( python3_{7..10} )
if [[ ${PV} = *9999* ]]; then
scm_eclass=git-r3
@@ -16,7 +16,7 @@ else
KEYWORDS="~amd64 ~x86"
fi
-inherit eutils distutils-r1 ${scm_eclass}
+inherit distutils-r1 ${scm_eclass}
DESCRIPTION="Python framework for Gromacs"
HOMEPAGE="https://gromacswrapper.readthedocs.io"
diff --git a/sci-chemistry/MDAnalysis/MDAnalysis-1.0.0.ebuild b/sci-chemistry/MDAnalysis/MDAnalysis-1.0.0.ebuild
index 0b58e90489e..1f9c2ac3aa5 100644
--- a/sci-chemistry/MDAnalysis/MDAnalysis-1.0.0.ebuild
+++ b/sci-chemistry/MDAnalysis/MDAnalysis-1.0.0.ebuild
@@ -1,9 +1,9 @@
-# Copyright 1999-2021 Gentoo Authors
+# Copyright 1999-2022 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
-PYTHON_COMPAT=( python3_{7..9} )
+PYTHON_COMPAT=( python3_{7..10} )
inherit distutils-r1
diff --git a/sci-chemistry/MDAnalysis/MDAnalysis-2.0.0.ebuild b/sci-chemistry/MDAnalysis/MDAnalysis-2.0.0.ebuild
new file mode 100644
index 00000000000..aee4e82b683
--- /dev/null
+++ b/sci-chemistry/MDAnalysis/MDAnalysis-2.0.0.ebuild
@@ -0,0 +1,37 @@
+# Copyright 1999-2021 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+PYTHON_COMPAT=( python3_{8..10} )
+
+inherit distutils-r1
+
+DESCRIPTION="A python library to analyze and manipulate molecular dynamics trajectories"
+HOMEPAGE="https://www.mdanalysis.org"
+SRC_URI="mirror://pypi/M/${PN}/${P}.tar.gz"
+
+SLOT="0"
+LICENSE="GPL-2"
+KEYWORDS="~amd64 ~x86 ~amd64-linux ~x86-linux"
+
+# TODO: fix this
+# ImportError: MDAnalysis not installed properly. This can happen if your C extensions have not been built.
+RESTRICT="test"
+
+RDEPEND="
+ >=dev-python/numpy-1.16.0[${PYTHON_USEDEP}]
+ >=dev-python/scipy-1.0.0[${PYTHON_USEDEP}]
+ >=sci-biology/biopython-1.71[${PYTHON_USEDEP}]
+ >=dev-python/networkx-1.0[${PYTHON_USEDEP}]
+ >=dev-python/GridDataFormats-0.4.0[${PYTHON_USEDEP}]
+ >=dev-python/joblib-0.12[${PYTHON_USEDEP}]
+ >=dev-python/matplotlib-1.5.1[${PYTHON_USEDEP}]
+ >=dev-python/mmtf-python-1.0.0[${PYTHON_USEDEP}]
+ >=dev-python/tqdm-4.43.0[${PYTHON_USEDEP}]
+ >=dev-python/gsd-1.9.3[${PYTHON_USEDEP}]
+ dev-python/threadpoolctl[${PYTHON_USEDEP}]
+"
+BDEPEND="${RDEPEND}"
+
+distutils_enable_tests nose
diff --git a/sci-chemistry/MDAnalysis/Manifest b/sci-chemistry/MDAnalysis/Manifest
index 5a903a9f3b7..721870b0e52 100644
--- a/sci-chemistry/MDAnalysis/Manifest
+++ b/sci-chemistry/MDAnalysis/Manifest
@@ -1 +1,2 @@
DIST MDAnalysis-1.0.0.tar.gz 19552874 BLAKE2B dab625a898d71a67a37ac5b58eb23ded9487f475e3c76f6c335a0ed5b32a43785d0473d089fcfc56c07263d82248bf5ee7b50c513441b10fc97f97b49411cc5f SHA512 4a001f45695308dd5f296bd2850d5d585c065e6b0f55efca65d91e452d78c85f13fd614eca0176a8d330e14a1c9e8ccbb919c3d4ae995b1945d09dc3ad687195
+DIST MDAnalysis-2.0.0.tar.gz 3436654 BLAKE2B b29734dd61bfa1e4e1d6ead0eb9a2d00869d1adce18edf95b9368bdcc16b0d71d0d6536a7df48787034a623bf52585e1636842dcaaa9dde08a69576868c1657b SHA512 037eb3c709b9ddbdb2ba9b26a6632ff99a95331c3968176573076e4e208c8644c3ea262e1e9880f185eb080ff90180d887444cab0dfbfad04fc254d87f1ff986
diff --git a/sci-chemistry/autodock_vina/metadata.xml b/sci-chemistry/autodock_vina/metadata.xml
index f603fd62c19..f29cb87a570 100644
--- a/sci-chemistry/autodock_vina/metadata.xml
+++ b/sci-chemistry/autodock_vina/metadata.xml
@@ -17,11 +17,4 @@
multithreading
Journal of Computational Chemistry 31 (2010) 455-461
</longdescription>
- <!--
- <use>
- <flag name='flag'>Description of how USE='flag' affects this package</flag>
- <flag name='userland_GNU'>Description of how USERLAND='GNU' affects this package</flag>
- <flag name='aspell'>Uses <pkg>app-text/aspell</pkg> for spell checking. Requires an installed dictionary from <cat>app-dicts</cat></flag>
- </use>
- -->
</pkgmetadata>
diff --git a/sci-chemistry/chemex/Manifest b/sci-chemistry/chemex/Manifest
index 594cc24b868..195cb44f0ba 100644
--- a/sci-chemistry/chemex/Manifest
+++ b/sci-chemistry/chemex/Manifest
@@ -1,2 +1 @@
-DIST chemex-2021.4.0_p2.tar.gz 2384471 BLAKE2B 1eb609c4e4ad9ac0f7cac8ab523e72e8ab9c12d40671fd598cd26b8de2a3d6e68dfdcaee9202521fc583068f591377842b3e7b9f0e1f95e6cba8da9b0c6d63a4 SHA512 568072eaf0d1c666de2aedacc50cd98da15631e0ef15ba60414be671ac97a50967e5b4d6d00340b1263f730b3a803ccc8995fbb86cfc47517b9521c9920641c8
-DIST chemex-2021.4.0_p4.tar.gz 2387888 BLAKE2B 26b4467756ba1b31775c554906a2ce09556e1fb99dd2ff294620a12b92246f441a2daa07e6bad7cedf903bd18e6ecc0613b6473f54d27d89ed9117ddc6a27269 SHA512 7d93f213317e4cb5a987c0b3cfcce146fb02a15ac9efbde74f9d3fc56a5e86c89ca6b606f45013bf08ed10f3de17cc72fa010ce0e42c5cb746119ede0ce4d38f
+DIST chemex-2021.4.0_p6.tar.gz 2395324 BLAKE2B adb08fdebe816b66359c8a567d7f7a4600715015e6f9b86b568cb8e3cd5e66b040895c09688a956cedd398a7c56a6d3a73d77f647a2f4e83280a91879a6184d0 SHA512 7d20ae73a2cf52f9d21b875cd661cefc14ce36ff603402e5dacad3e21bcb0bdb28f8f111414691b99f93196a971215d0beec3fff07535d3d781b4e7bb6782c52
diff --git a/sci-chemistry/chemex/chemex-2021.4.0_p2.ebuild b/sci-chemistry/chemex/chemex-2021.4.0_p2.ebuild
deleted file mode 100644
index 8b5e04b8b08..00000000000
--- a/sci-chemistry/chemex/chemex-2021.4.0_p2.ebuild
+++ /dev/null
@@ -1,43 +0,0 @@
-# Copyright 1999-2021 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=8
-DISTUTILS_SINGLE_IMPL="yes"
-PYTHON_COMPAT=( python3_{8..10} )
-DISTUTILS_USE_SETUPTOOLS=pyproject.toml
-
-inherit distutils-r1
-
-DESCRIPTION="Program to fit chemical exchange induced shift and relaxation data"
-HOMEPAGE="https://github.com/gbouvignies/chemex"
-SRC_URI="https://github.com/gbouvignies/chemex/archive/${PV/_p/-dev}.tar.gz -> ${P}.tar.gz"
-
-SLOT="0"
-LICENSE="BSD"
-KEYWORDS="~amd64"
-IUSE="test"
-RESTRICT="!test? ( test )"
-
-RDEPEND="
- $(python_gen_cond_dep '
- >=dev-python/asteval-0.9.11[${PYTHON_USEDEP}]
- >=dev-python/jsonschema-3.2.0[${PYTHON_USEDEP}]
- >=dev-python/lmfit-1.0.2[${PYTHON_USEDEP}]
- >=dev-python/matplotlib-3.4.2[${PYTHON_USEDEP}]
- >=dev-python/numpy-1.21.0[${PYTHON_USEDEP}]
- dev-python/setuptools_scm[${PYTHON_USEDEP}]
- >=dev-python/scipy-1.7.0[${PYTHON_USEDEP}]
- >=dev-python/tomlkit-0.7.2[${PYTHON_USEDEP}]
- >=dev-python/tqdm-4.61.1[${PYTHON_USEDEP}]
- ')
-"
-DEPEND="${RDEPEND}"
-
-distutils_enable_tests pytest
-
-S="${WORKDIR}/ChemEx-${PV/_p/-dev}"
-
-src_prepare() {
- export SETUPTOOLS_SCM_PRETEND_VERSION="${PV}"
- distutils-r1_src_prepare
-}
diff --git a/sci-chemistry/chemex/chemex-2021.4.0_p4.ebuild b/sci-chemistry/chemex/chemex-2021.4.0_p6.ebuild
index 3a331d48eba..62c958f646d 100644
--- a/sci-chemistry/chemex/chemex-2021.4.0_p4.ebuild
+++ b/sci-chemistry/chemex/chemex-2021.4.0_p6.ebuild
@@ -18,7 +18,7 @@ KEYWORDS="~amd64"
IUSE="test"
#RESTRICT="!test? ( test )"
-# FIXME: Restrict until we figure out how to run tests properly, bug #815079
+# FIXME: Restrict until tests are readded https://github.com/gbouvignies/ChemEx/issues/51
RESTRICT="test"
RDEPEND="
diff --git a/sci-chemistry/cluster/cluster-1.3.081231-r1.ebuild b/sci-chemistry/cluster/cluster-1.3.081231-r1.ebuild
index d274ed0d378..b5f0395734e 100644
--- a/sci-chemistry/cluster/cluster-1.3.081231-r1.ebuild
+++ b/sci-chemistry/cluster/cluster-1.3.081231-r1.ebuild
@@ -1,26 +1,27 @@
# Copyright 1999-2021 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
-EAPI=5
+EAPI=8
-inherit epatch toolchain-funcs
+inherit toolchain-funcs
DESCRIPTION="Build lists of collections of interacting items"
HOMEPAGE="http://kinemage.biochem.duke.edu/software/index.php"
SRC_URI="http://kinemage.biochem.duke.edu/downloads/software/${PN}/${PN}.${PV}.src.tgz"
+S="${WORKDIR}"/${PN}1.3src
-SLOT="0"
LICENSE="richardson"
+SLOT="0"
KEYWORDS="amd64 x86 ~amd64-linux ~x86-linux"
-IUSE=""
-S="${WORKDIR}"/${PN}1.3src
+PATCHES=(
+ "${FILESDIR}"/${PV}-ldflags.patch
+ "${FILESDIR}"/${PV}-includes.patch
+)
-src_prepare() {
- epatch \
- "${FILESDIR}"/${PV}-ldflags.patch \
- "${FILESDIR}"/${PV}-includes.patch
+src_configure() {
tc-export CXX
+ default
}
src_install() {
diff --git a/sci-chemistry/dssp/Manifest b/sci-chemistry/dssp/Manifest
index 9fd132f8a29..2eecf341c88 100644
--- a/sci-chemistry/dssp/Manifest
+++ b/sci-chemistry/dssp/Manifest
@@ -1,4 +1,3 @@
DIST dssp-2.2.1.tgz 47141 BLAKE2B 34d8b2db8797a8c23763766c0214337f03584c4be52c1bc820a0df0db6a5f78ac0229aafdd47a60b8fd6f4832abf0399663c53f9e898c75f08ecbe22b141c8da SHA512 4a273714d6b3230daea166caa7f4117d5ccb225bea0cf1bc2eb61539b6cc8e227d0ba19047d61f0ad0d1d6bc2efdec9c193bd44341e15ef0950acb4a22498811
DIST dssp-3.0.11.tar.gz 168085 BLAKE2B e1c42fd22cfb2287f10b5deae48b56a4583d4a67737a3485dcbd160d1597a15c2d5105c3794c875d8001abede1c014efb4f7f5b7c250f867bdf9ed95a0860217 SHA512 a0cfe44e517ff1f909ef2928b62ae2c639c6bddfd8a0fb538883f647fd2771e00da68e0fd2521aa02ba3c6d1b0c9b784b7fe142392af3a3abf6ea89f1546bd9d
-DIST dssp-4.0.1_p20210831.tar.gz 121793 BLAKE2B 1e028b086b418772a93db350f8084d1786996ff6ea935d236b1431d8f4a07c0b33ebf374a4c4d5d4d243952f3f56e29a548ce09763863a1e0c529755fba6c211 SHA512 62f1ac781dd3d6f3436e6c155ae1a470d0baf6a6d9f6d6729034a7a5ef41550f76d0473c688d235279336306c9f3598377c056cddd6d00a89a826fbb04c1bfb3
DIST dssp-4.0.3.tar.gz 122872 BLAKE2B f88c330370645b4bd4e89656ad676e443a33c38d7882145bc60e329f823eb761777713df6c7ae44550d10bcd22256ac16db358587cadd39efd6268dd869655d4 SHA512 31ca481b097c9c59f407e35eb8175638b5e4102991007090b5b4ea30db0b076f97cff45d0aa9ae01a826f7673258464b572d68714f00e210db26020cea4be094
diff --git a/sci-chemistry/dssp/dssp-2.2.1-r2.ebuild b/sci-chemistry/dssp/dssp-2.2.1-r2.ebuild
deleted file mode 100644
index 63075d4d429..00000000000
--- a/sci-chemistry/dssp/dssp-2.2.1-r2.ebuild
+++ /dev/null
@@ -1,45 +0,0 @@
-# Copyright 1999-2021 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=6
-
-inherit toolchain-funcs
-
-DESCRIPTION="The protein secondary structure standard"
-HOMEPAGE="http://swift.cmbi.ru.nl/gv/dssp/"
-SRC_URI="ftp://ftp.cmbi.ru.nl/pub/molbio/software/dssp-2/${P}.tgz"
-
-LICENSE="Boost-1.0"
-SLOT="0"
-KEYWORDS="amd64 x86 ~amd64-linux ~x86-linux"
-IUSE=""
-
-RDEPEND="dev-libs/boost:=[threads(+)]"
-DEPEND="${RDEPEND}"
-
-PATCHES=(
- "${FILESDIR}"/${PN}-2.1.0-gentoo.patch
- "${FILESDIR}"/${PN}-2.2.1-boost-1.65-tr1-removal.patch
-)
-
-src_configure() {
- tc-export CXX
-
- cat >> make.config <<- EOF || die
- BOOST_LIB_SUFFIX = -mt
- BOOST_LIB_DIR = "${EPREFIX}/usr/$(get_libdir)"
- BOOST_INC_DIR = "${EPREFIX}/usr/include"
- EOF
-}
-
-src_install() {
- dobin mkdssp
- dosym mkdssp /usr/bin/dssp
- doman doc/mkdssp.1
- dodoc README.txt changelog
-
- cat >> "${T}"/30-${PN} <<- EOF || die
- DSSP="${EPREFIX}"/usr/bin/${PN}
- EOF
- doenvd "${T}"/30-${PN}
-}
diff --git a/sci-chemistry/dssp/dssp-3.0.11.ebuild b/sci-chemistry/dssp/dssp-3.0.11.ebuild
index b0771e31047..002c7d491d1 100644
--- a/sci-chemistry/dssp/dssp-3.0.11.ebuild
+++ b/sci-chemistry/dssp/dssp-3.0.11.ebuild
@@ -13,8 +13,9 @@ SRC_URI="https://github.com/cmbi/${MY_PN}/archive/refs/tags/${PV}.tar.gz -> ${P}
LICENSE="Boost-1.0"
SLOT="0"
-KEYWORDS="~amd64 ~x86 ~amd64-linux ~x86-linux"
-IUSE=""
+KEYWORDS="amd64 x86 ~amd64-linux ~x86-linux"
+# It's just cppcheck (at least in 3.0.11)
+RESTRICT="test"
RDEPEND="
dev-lang/perl:=
diff --git a/sci-chemistry/dssp/dssp-4.0.1_p20210831.ebuild b/sci-chemistry/dssp/dssp-4.0.1_p20210831.ebuild
deleted file mode 100644
index ca051ca5a0d..00000000000
--- a/sci-chemistry/dssp/dssp-4.0.1_p20210831.ebuild
+++ /dev/null
@@ -1,33 +0,0 @@
-# Copyright 1999-2021 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=7
-inherit cmake
-
-DESCRIPTION="The protein secondary structure standard"
-HOMEPAGE="https://swift.cmbi.umcn.nl/gv/dssp/ https://github.com/PDB-REDO/dssp"
-
-COMMIT="728cc7c6c8d95460d8db453cf7adb25a89ba15f6"
-SRC_URI="https://github.com/PDB-REDO/${PN}/archive/${COMMIT}.tar.gz -> ${P}.tar.gz"
-S="${WORKDIR}/${PN}-${COMMIT}"
-
-LICENSE="BSD-2"
-SLOT="0"
-KEYWORDS="~amd64 ~x86"
-IUSE=""
-
-BDEPEND="
- >=dev-libs/boost-1.70.0:=[bzip2,zlib,threads(+)]
- >=sci-libs/libcifpp-1.1.1
-"
-DEPEND=""
-RDEPEND="${BDEPEND}"
-
-pkg_postinst() {
- if has_version sci-chemistry/gromacs; then
- ewarn "DSSP > 3.0.x is not compatible with gmx do_dssp:"
- ewarn "https://gitlab.com/gromacs/gromacs/-/issues/4129"
- ewarn
- ewarn "Feel free to mask newer versions if needed."
- fi
-}
diff --git a/sci-chemistry/dssp/dssp-4.0.3.ebuild b/sci-chemistry/dssp/dssp-4.0.3.ebuild
index d9d8a5740c8..31f86f7e3cf 100644
--- a/sci-chemistry/dssp/dssp-4.0.3.ebuild
+++ b/sci-chemistry/dssp/dssp-4.0.3.ebuild
@@ -22,7 +22,7 @@ DEPEND=""
RDEPEND="${BDEPEND}"
pkg_postinst() {
- if has_version sci-chemistry/gromacs; then
+ if has_version "<=sci-chemistry/gromacs-2022"; then
ewarn "DSSP > 3.0.x is not compatible with gmx do_dssp:"
ewarn "https://gitlab.com/gromacs/gromacs/-/issues/4129"
ewarn
diff --git a/sci-chemistry/gnome-chemistry-utils/gnome-chemistry-utils-0.14.17_p6.ebuild b/sci-chemistry/gnome-chemistry-utils/gnome-chemistry-utils-0.14.17_p6-r1.ebuild
index c7f9cff1105..28d4cf3e6b8 100644
--- a/sci-chemistry/gnome-chemistry-utils/gnome-chemistry-utils-0.14.17_p6.ebuild
+++ b/sci-chemistry/gnome-chemistry-utils/gnome-chemistry-utils-0.14.17_p6-r1.ebuild
@@ -1,7 +1,7 @@
# Copyright 1999-2021 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
-EAPI=7
+EAPI=8
inherit autotools flag-o-matic xdg
DESCRIPTION="Programs and library containing GTK widgets and C++ classes related to chemistry"
@@ -22,7 +22,7 @@ RDEPEND="
>=gnome-extra/libgsf-1.14.9
>=sci-chemistry/bodr-5
>=sci-chemistry/chemical-mime-data-0.1.94
- >=sci-chemistry/openbabel-2.3.0:0
+ >=sci-chemistry/openbabel-2.3.0:0=
>=x11-libs/cairo-1.6.0
>=x11-libs/gdk-pixbuf-2.22.0
>=x11-libs/goffice-0.10.12
@@ -41,10 +41,12 @@ BDEPEND="
S="${WORKDIR}/${P/_p*}"
src_prepare() {
- xdg_src_prepare
+ default
+
+ if has_version '<sci-chemistry/openbabel-3'; then
+ sed -i -e '/openbabel-v3/d' "${WORKDIR}"/debian/patches/series || die
+ fi
- # We don't have openbabel3 yet
- sed -i -e '/openbabel-v3/d' "${WORKDIR}"/debian/patches/series || die
# Debian patches
for p in $(<"${WORKDIR}"/debian/patches/series) ; do
eapply -p1 "${WORKDIR}/debian/patches/${p}"
diff --git a/sci-chemistry/gromacs/Manifest b/sci-chemistry/gromacs/Manifest
index 0102ae34ad4..0788ac6bd4e 100644
--- a/sci-chemistry/gromacs/Manifest
+++ b/sci-chemistry/gromacs/Manifest
@@ -4,15 +4,21 @@ DIST gromacs-2020.4.tar.gz 29149899 BLAKE2B a07c8efd96137d58c1edf4ac9b5aafeb16d9
DIST gromacs-2020.6.tar.gz 29196621 BLAKE2B b350fc62fd8eeb3f2b042fa74a4ed42e43a7b74efd8fddb60ec086a814048a52b8625da65fa5c4cf2cb1e22f8347562bc84d38bf34441fc5ebc6abaa38b0eea0 SHA512 4ce4d6b9ae33e9cd2a1ad3313e80acf63ded21dac897b01dbf87df2e318181796ef64c8a1d3e0a6058b972d8d88d00f710cd0277db12f38fc2c9b29772c98bea
DIST gromacs-2021.2.tar.gz 37976386 BLAKE2B 8818321bbcbdee25356bbf909d9c667f9d7cf180e696a323a61017683234d1269decc8f8d72b8012a8cc207f69e5cd97e2ab48dbbff06d82bbb407bc0578854b SHA512 51b1728f41932274436ab807d569109e2b0e145abcb5cf9c9b7daf6a7396f2f8716dc28fb93cf178c97a7eaeab2a88878d0bc71dd6c6abe7e829d579e7968615
DIST gromacs-2021.3.tar.gz 37987972 BLAKE2B d71995c7d5a34978246e33dc637ac3d273e547afcf72d1a107026650f03286ecdf27e4b9a70113b3c3a01af59ad49ac5c813aa6e5d2e8eb29fd05582a7a28d34 SHA512 da420917d06de2e192dfbb4e1b9f46989ed05b5c7e641c657104ed8f2bd8b22509bffd1ecfd7c965c80544eafa6af12d6d0aba7e1e7d9d14a4a88fb3fbf394a5
+DIST gromacs-2021.4.tar.gz 38023262 BLAKE2B 4e1c9ca23f8bd89a990bac2730f846ce9fd6423aa6934866734272ac8f5ca29cdb51daec440b7ef2af56c68bdbab504c0c1b1a4d5f4af0b16666850bf286c5b2 SHA512 35b26b3df02d151373fab49022281b89e987c867257a998acc926b2b7151f5d4e46f11c398a24f4a174f668dd24a828b07d36594ac5d5506e10e40d4578427a2
+DIST gromacs-2022-beta1.tar.gz 39727355 BLAKE2B 2b17684e36f1a2746bd92e4cea2f7eedfcc1770eb127663b7d643a4e9518dc90f788c0f41dcff612d06edb05eeb06a13196810714d5cdf5a8ef5056100d75eb6 SHA512 a311a95b42647819d442be2a6106f4a3bbfa792856ac88ade9ee0793dff3a3bd0e6f2982bfa37d541b3a4673a24358fa72bf9267c3d1743bb01da673d84e0fa8
DIST manual-2018.8.pdf 10025023 BLAKE2B afb0a6e6a72d78df743fcb57e7c1716848589e571dd35167b957a9b407ca27978ccfb6cb9e0df9c9439b888f352501a00ba32281ed1e0b4193bd606f1d77152e SHA512 b1972f7ce965bfc9377542993c5943ea4868a8ed23a969d4203264746d6bea3a7a65c6379196ece37fd6d68ec7ec80f827bde87d1049284af7082759a124f1d5
DIST manual-2019.6.pdf 12702376 BLAKE2B c350127bc06a9eb3dee73da39037c84daeb89500e23cb131bd19a150bf60602d4dde7611e0c6f0f344af4093e96a899303dac71b4df56fd0c44c3a48a56606b7 SHA512 dfdff67c2c1c9ce1f1c236b7686c5331b0fe86951da6c98eddd6a3e748815e0be0a9653ae4318469fcdd913c4e7c355d64a997cc80b9d9fbe6282ef6d98e61eb
DIST manual-2020.4.pdf 11851608 BLAKE2B 7b7bdf08e8946fcc448543b08391b94a67fee60a8c810597c1f09f70443f9d7db817c99622dd0c21c6317f5fdcd6c4a88589ecac57055cb0cd8597d6021026e7 SHA512 928555663c77de36393e625c29d388d4e1c8c1298e7a993d871839e0d4d8d18d190221ad8f1d975bd072bdd6a061e9ea5b9295f2ecf45f24b6523ea5ea290fed
DIST manual-2020.6.pdf 11850850 BLAKE2B 155e4eb9c200dcd0a38e3669b26077fcf310d437b82d9a593d333dada3989c2c8a936d62c642e195f98bb474b1673b8142405c467348fc96a74d57fb12106d76 SHA512 be508ebec597b82a2c4056029f8bb731b22cb8902628a45462ed21af54c554d28e07d5381efaaa96565202b7b47d33aea67950206cd9e8936211ae721b21b3e1
DIST manual-2021.2.pdf 12252501 BLAKE2B 0dbf9024e1516076b0eeb46e41523b966d1d81f57504fe0501c7bc8575e74fb19e3452ac584757e425bcccbc737367fe83be87fd21a4287f4675cf87184b960b SHA512 14156d3b1017990e0be3ceb7ec055777a1aec4c347ac2e821a042d51c931f84ebca862f60644a90ed7ba4070cb14ff8babcde3e4351e4dbec84df8563e350984
DIST manual-2021.3.pdf 12255076 BLAKE2B 6ca516b6832507c9d4100679d1f9bc9e3ab17d226849b050764b0d0626247dc57ce49985f9a7fc0061f3df278923a83faa367ca8ab91c37e5624dc584a51a822 SHA512 5d53798f30ea00fcb4e1b35f7eaa4bebfc05dafa4f2d0c197dcf2b57a624ad3a98b74fd90722e40d0ac13a6fff4ca231f9d6340f52ba94659c827c53c2f1cb16
+DIST manual-2021.4.pdf 12253232 BLAKE2B 0b859c08a07d5a615ac7a822b61d5a4f4296ca9773d383a07960dc629d6b1df23e1dec51561a4ac26789b84e49cc98b6d7cc10d943c61d7784052664ac1bacf9 SHA512 024f17a670518fc19a2a462186ed2a74f331c5c83b8ba4bbe148a53767515ba19e6af887a1baae3a7770af2095fad5c513784cc54f9d0f881395ad8a89760cba
+DIST manual-2022_beta1.pdf 13033013 BLAKE2B dda51c931e5b124d0fbd106a73b4f04d6d58374a8590b44d1f64897a2a2c97fb4a682275d2f2bd0907de5faec74d91550642bb505a3a316d2f7e20a84f0c1308 SHA512 ea7c1362fda8a4dc5b21242154daf9d9c66bdd2462d67335c56170189ed6f75a50bf51a0cdf8654886a3c0a537dfc0d364eb57f6602ce0065e4ac8ca106f5544
DIST regressiontests-2018.8.tar.gz 67855469 BLAKE2B 34c9b339f6229f483afbb5192ee6ba8b8f72d5c26907a853af9c53dfece0d88739e48f6b44b78d1c010f988f9385d077285300522164f533a5861e9dda879275 SHA512 3642389d27bd1942cd0f091c940ae97b197b94856a387fe581dc516b0d4169480f16551d4ba357f9282b3337d605c286d51dd38112ac87c826dda634904836bb
DIST regressiontests-2019.6.tar.gz 67643195 BLAKE2B 1e054e24b187946f7ea28090d4f20cf8e1d79a26253f57ba07d130e0773d8541b8a1552a38023d31a68ce8bc62d8e0af1d98609234bb3e7d3e6d567307ebb386 SHA512 eacf1c55b982515a305c29459fe80a7cd558a8481e5689962aa956148af542568b1d1ce59c6784ecb0afd4768c2b664afa21e12af2d89ae2b06b1ba61ad72036
DIST regressiontests-2020.4.tar.gz 48542144 BLAKE2B 1dcde67525d40ababa74d9e8ba2dd3fdef1de7d1018491e102edd71d3a622925f213b5a0812e5448882b4cb5fb578317e8e5029bdc4bd53008aa8441a3d9dea1 SHA512 7c71f36a1cef22562f14dcd233e90ad2fe370ae1a7d3b5268727259b374e12d4754253735ac8745d3738bdbc1cc2067780fda5e393be2ff264f632fe4e0c1978
DIST regressiontests-2020.6.tar.gz 48541232 BLAKE2B dbb405bd9168775984de8c9fb9e3fa2398d2790e2e4de23711c51a01dc3ea570d172a35d4924742ad5eda463eb0a885e6924512801e82b241600ceaefd5db70d SHA512 497a9e7d438b0b7b0734a97cf3683baf480ecc056e96b09f1e143c362ff047a4e51e323216750501c954559579716dc024d3c51319bd2c85fa719466ce4330b2
DIST regressiontests-2021.2.tar.gz 48514312 BLAKE2B 81b007d5e5e1d054349c73dc8bc3589db328752e48a66687c0ad36be87ebe580df9cbd93b193a724669bd5765af06ec306f2e12af00a228af616de03943d6f05 SHA512 b687ddfd3dc6ec1051af2a3253633703ef1c82335d1df23379819ea47e44dfcd417e81e29610cc584d4c5fb1ee1cbc76731a3fd31b529d8cdd0b9c22f432c7ec
DIST regressiontests-2021.3.tar.gz 48515038 BLAKE2B ee79d8adddc9c68f7d59d9e568b12bf4d1fe0e44c2810fee846ad6f689bbcacf60f5c266433946329e64e3127bc2d37a3f81f69c070c636b411b38067650c2cf SHA512 e14baa22ef2902a23125bbd9143ae7a9a4810498b321794ff1989f8d044d47db5db41d5225798fda08016c05e5f7f315178b5a6e35cdf01e3b6604670a8ce7a2
+DIST regressiontests-2021.4.tar.gz 48541736 BLAKE2B 37b8e65e333dcfcfc795da631475807ffa4ecc3a85426b4de6dd2ccb50f40a78159149789da13f988340a62d21e7d6b1d4f0c6e7fe69120d4c94ab2252b4c440 SHA512 18663693cf9ce2ca3bd8df0f668e7a0c8236a7f5ae4ee02f621cbe52c139c506b61ac4cab200cc59caab41e9983ea93dfa062d7b52f6558a619096a8d439fb56
+DIST regressiontests-2022-beta1.tar.gz 48534065 BLAKE2B 4f0dd89b791fa11696460befa4a755dff14546abc10a4801ddb5f0286cee267ca983c082748b0ce9345a98b7fb98bb4a5387054a373acc543ff56b72e0ad9b64 SHA512 aa178a59bc7074e1d50d2cbe4d376f3593e0af6ad2a563627529fa4b0aa6a9bb29248caaace578150ab9e80feba3bf862ab964993eed183a79e35a189d10fecf
diff --git a/sci-chemistry/gromacs/files/gromacs-2019.6-missing-include.patch b/sci-chemistry/gromacs/files/gromacs-2019.6-missing-include.patch
new file mode 100644
index 00000000000..cf478d52cb6
--- /dev/null
+++ b/sci-chemistry/gromacs/files/gromacs-2019.6-missing-include.patch
@@ -0,0 +1,38 @@
+From 053286ff0bfb88db5c158f5f68017c4bb5d9496a Mon Sep 17 00:00:00 2001
+From: Christoph Junghans <junghans@votca.org>
+Date: Wed, 28 Apr 2021 19:44:09 -0600
+Subject: [PATCH] fix build on F34
+
+see https://gitlab.com/gromacs/gromacs/-/merge_requests/1524
+---
+ src/gromacs/awh/biasparams.cpp | 1 +
+ src/gromacs/mdrun/minimize.cpp | 1 +
+ 2 files changed, 2 insertions(+)
+
+diff --git a/src/gromacs/awh/biasparams.cpp b/src/gromacs/awh/biasparams.cpp
+index f4db497002..e762ea084a 100644
+--- a/src/gromacs/awh/biasparams.cpp
++++ b/src/gromacs/awh/biasparams.cpp
+@@ -49,6 +49,7 @@
+ #include <cmath>
+
+ #include <algorithm>
++#include <limits>
+
+ #include "gromacs/math/functions.h"
+ #include "gromacs/mdtypes/awh-params.h"
+diff --git a/src/gromacs/mdrun/minimize.cpp b/src/gromacs/mdrun/minimize.cpp
+index 8550271325..495bcfdda0 100644
+--- a/src/gromacs/mdrun/minimize.cpp
++++ b/src/gromacs/mdrun/minimize.cpp
+@@ -51,6 +51,7 @@
+ #include <ctime>
+
+ #include <algorithm>
++#include <limits>
+ #include <vector>
+
+ #include "gromacs/commandline/filenm.h"
+--
+GitLab
+
diff --git a/sci-chemistry/gromacs/gromacs-2018.8.ebuild b/sci-chemistry/gromacs/gromacs-2018.8-r1.ebuild
index 88cd8246d14..5266a60f632 100644
--- a/sci-chemistry/gromacs/gromacs-2018.8.ebuild
+++ b/sci-chemistry/gromacs/gromacs-2018.8-r1.ebuild
@@ -34,8 +34,8 @@ CDEPEND="
blas? ( virtual/blas )
cuda? ( >=dev-util/nvidia-cuda-toolkit-4.2.9-r1 )
opencl? ( virtual/opencl )
- fftw? ( sci-libs/fftw:3.0 )
- hwloc? ( <sys-apps/hwloc-2 )
+ fftw? ( sci-libs/fftw:3.0= )
+ hwloc? ( <sys-apps/hwloc-2:= )
lapack? ( virtual/lapack )
mkl? ( sci-libs/mkl )
mpi? ( virtual/mpi )
diff --git a/sci-chemistry/gromacs/gromacs-2019.6.ebuild b/sci-chemistry/gromacs/gromacs-2019.6-r1.ebuild
index b93b01a654e..0c9aa1c428a 100644
--- a/sci-chemistry/gromacs/gromacs-2019.6.ebuild
+++ b/sci-chemistry/gromacs/gromacs-2019.6-r1.ebuild
@@ -34,10 +34,10 @@ CDEPEND="
blas? ( virtual/blas )
cuda? ( >=dev-util/nvidia-cuda-toolkit-6.5.14 )
opencl? ( virtual/opencl )
- fftw? ( sci-libs/fftw:3.0 )
- hwloc? ( sys-apps/hwloc )
+ fftw? ( sci-libs/fftw:3.0= )
+ hwloc? ( sys-apps/hwloc:= )
lapack? ( virtual/lapack )
- lmfit? ( sci-libs/lmfit )
+ lmfit? ( sci-libs/lmfit:= )
mkl? ( sci-libs/mkl )
mpi? ( virtual/mpi )
${PYTHON_DEPS}
diff --git a/sci-chemistry/gromacs/gromacs-2019.6-r2.ebuild b/sci-chemistry/gromacs/gromacs-2019.6-r2.ebuild
new file mode 100644
index 00000000000..35bbc972de6
--- /dev/null
+++ b/sci-chemistry/gromacs/gromacs-2019.6-r2.ebuild
@@ -0,0 +1,255 @@
+# Copyright 1999-2021 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+CMAKE_MAKEFILE_GENERATOR="ninja"
+
+inherit bash-completion-r1 cmake cuda multilib readme.gentoo-r1 toolchain-funcs xdg-utils
+
+SRC_URI="
+ http://ftp.gromacs.org/gromacs/${PN}-${PV/_/-}.tar.gz
+ doc? ( http://ftp.gromacs.org/manual/manual-${PV/_/-}.pdf )
+ test? ( http://ftp.gromacs.org/regressiontests/regressiontests-${PV/_/-}.tar.gz )"
+KEYWORDS="~amd64 ~arm ~x86 ~amd64-linux ~x86-linux ~x64-macos"
+
+ACCE_IUSE="cpu_flags_x86_sse2 cpu_flags_x86_sse4_1 cpu_flags_x86_fma4 cpu_flags_x86_avx cpu_flags_x86_avx2"
+
+DESCRIPTION="The ultimate molecular dynamics simulation package"
+HOMEPAGE="http://www.gromacs.org/"
+
+# see COPYING for details
+# https://repo.or.cz/w/gromacs.git/blob/HEAD:/COPYING
+# base, vmd plugins, fftpack from numpy, blas/lapck from netlib, memtestG80 library, mpi_thread lib
+LICENSE="LGPL-2.1 UoI-NCSA !mkl? ( !fftw? ( BSD ) !blas? ( BSD ) !lapack? ( BSD ) ) cuda? ( LGPL-3 ) threads? ( BSD )"
+SLOT="0/${PV}"
+IUSE="X blas cuda +doc double-precision +fftw +gmxapi +hwloc lapack +lmfit mkl mpi +offensive opencl openmp +single-precision test +threads +tng ${ACCE_IUSE}"
+
+CDEPEND="
+ X? (
+ x11-libs/libX11
+ x11-libs/libSM
+ x11-libs/libICE
+ )
+ blas? ( virtual/blas )
+ cuda? ( >=dev-util/nvidia-cuda-toolkit-6.5.14 )
+ opencl? ( virtual/opencl )
+ fftw? ( sci-libs/fftw:3.0= )
+ hwloc? ( sys-apps/hwloc:= )
+ lapack? ( virtual/lapack )
+ lmfit? ( sci-libs/lmfit:= )
+ mkl? ( sci-libs/mkl )
+ mpi? ( virtual/mpi )
+ ${PYTHON_DEPS}
+ "
+BDEPEND="${CDEPEND}
+ virtual/pkgconfig
+ "
+RDEPEND="${CDEPEND}"
+
+REQUIRED_USE="
+ || ( single-precision double-precision )
+ cuda? ( single-precision )
+ cuda? ( !opencl )
+ mkl? ( !blas !fftw !lapack )
+ ${PYTHON_REQUIRED_USE}"
+
+DOCS=( AUTHORS README )
+
+RESTRICT="!test? ( test )"
+
+S="${WORKDIR}/${PN}-${PV/_/-}"
+
+PATCHES=( "${FILESDIR}/${P}-missing-include.patch" )
+
+pkg_pretend() {
+ [[ $(gcc-version) == "4.1" ]] && die "gcc 4.1 is not supported by gromacs"
+ use openmp && ! tc-has-openmp && \
+ die "Please switch to an openmp compatible compiler"
+}
+
+src_prepare() {
+ #notes/todos
+ # -on apple: there is framework support
+
+ xdg_environment_reset #591952
+
+ cmake_src_prepare
+
+ use cuda && cuda_src_prepare
+
+ GMX_DIRS=""
+ use single-precision && GMX_DIRS+=" float"
+ use double-precision && GMX_DIRS+=" double"
+
+ if use test; then
+ for x in ${GMX_DIRS}; do
+ mkdir -p "${WORKDIR}/${P}_${x}" || die
+ cp -al "${WORKDIR}/regressiontests"* "${WORKDIR}/${P}_${x}/tests" || die
+ done
+ fi
+
+ DOC_CONTENTS="Gromacs can use sci-chemistry/vmd to read additional file formats"
+}
+
+src_configure() {
+ local mycmakeargs_pre=( ) extra fft_opts=( )
+
+ #go from slowest to fastest acceleration
+ local acce="None"
+ use cpu_flags_x86_sse2 && acce="SSE2"
+ use cpu_flags_x86_sse4_1 && acce="SSE4.1"
+ use cpu_flags_x86_fma4 && acce="AVX_128_FMA"
+ use cpu_flags_x86_avx && acce="AVX_256"
+ use cpu_flags_x86_avx2 && acce="AVX2_256"
+
+ #to create man pages, build tree binaries are executed (bug #398437)
+ [[ ${CHOST} = *-darwin* ]] && \
+ extra+=" -DCMAKE_BUILD_WITH_INSTALL_RPATH=OFF"
+
+ if use fftw; then
+ fft_opts=( -DGMX_FFT_LIBRARY=fftw3 )
+ elif use mkl && has_version "=sci-libs/mkl-10*"; then
+ fft_opts=( -DGMX_FFT_LIBRARY=mkl
+ -DMKL_INCLUDE_DIR="${MKLROOT}/include"
+ -DMKL_LIBRARIES="$(echo /opt/intel/mkl/10.0.5.025/lib/*/libmkl.so);$(echo /opt/intel/mkl/10.0.5.025/lib/*/libiomp*.so)"
+ )
+ elif use mkl; then
+ local bits=$(get_libdir)
+ fft_opts=( -DGMX_FFT_LIBRARY=mkl
+ -DMKL_INCLUDE_DIR="$(echo /opt/intel/*/mkl/include)"
+ -DMKL_LIBRARIES="$(echo /opt/intel/*/mkl/lib/*${bits/lib}/libmkl_rt.so)"
+ )
+ else
+ fft_opts=( -DGMX_FFT_LIBRARY=fftpack )
+ fi
+
+ if use lmfit; then
+ local lmfit_opts=( -DGMX_USE_LMFIT=EXTERNAL )
+ else
+ local lmfit_opts=( -DGMX_USE_LMFIT=INTERNAL )
+ fi
+
+ mycmakeargs_pre+=(
+ "${fft_opts[@]}"
+ "${lmfit_opts[@]}"
+ -DGMX_X11=$(usex X)
+ -DGMX_EXTERNAL_BLAS=$(usex blas)
+ -DGMX_EXTERNAL_LAPACK=$(usex lapack)
+ -DGMX_OPENMP=$(usex openmp)
+ -DGMX_COOL_QUOTES=$(usex offensive)
+ -DGMX_USE_TNG=$(usex tng)
+ -DGMX_HWLOC=$(usex hwloc)
+ -DGMX_DEFAULT_SUFFIX=off
+ -DGMX_SIMD="$acce"
+ -DGMX_VMD_PLUGIN_PATH="${EPREFIX}/usr/$(get_libdir)/vmd/plugins/*/molfile/"
+ -DBUILD_TESTING=$(usex test)
+ -DGMX_BUILD_UNITTESTS=$(usex test)
+ -DPYTHON_EXECUTABLE="${EPREFIX}/usr/bin/${EPYTHON}"
+ ${extra}
+ )
+
+ for x in ${GMX_DIRS}; do
+ einfo "Configuring for ${x} precision"
+ local suffix=""
+ #if we build single and double - double is suffixed
+ use double-precision && use single-precision && \
+ [[ ${x} = "double" ]] && suffix="_d"
+ local p
+ [[ ${x} = "double" ]] && p="-DGMX_DOUBLE=ON" || p="-DGMX_DOUBLE=OFF"
+ local cuda=( "-DGMX_GPU=OFF" )
+ [[ ${x} = "float" ]] && use cuda && \
+ cuda=( "-DGMX_GPU=ON" )
+ local opencl=( "-DGMX_USE_OPENCL=OFF" )
+ use opencl && opencl=( "-DGMX_USE_OPENCL=ON" ) cuda=( "-DGMX_GPU=ON" )
+ mycmakeargs=(
+ ${mycmakeargs_pre[@]} ${p}
+ -DGMX_MPI=OFF
+ -DGMX_THREAD_MPI=$(usex threads)
+ -DGMXAPI=$(usex gmxapi)
+ "${opencl[@]}"
+ "${cuda[@]}"
+ "$(use test && echo -DREGRESSIONTEST_PATH="${WORKDIR}/${P}_${x}/tests")"
+ -DGMX_BINARY_SUFFIX="${suffix}"
+ -DGMX_LIBS_SUFFIX="${suffix}"
+ )
+ BUILD_DIR="${WORKDIR}/${P}_${x}" cmake_src_configure
+ [[ ${CHOST} != *-darwin* ]] || \
+ sed -i '/SET(CMAKE_INSTALL_NAME_DIR/s/^/#/' "${WORKDIR}/${P}_${x}/gentoo_rules.cmake" || die
+ use mpi || continue
+ einfo "Configuring for ${x} precision with mpi"
+ mycmakeargs=(
+ ${mycmakeargs_pre[@]} ${p}
+ -DGMX_THREAD_MPI=OFF
+ -DGMX_MPI=ON
+ -DGMX_OPENMM=OFF
+ -DGMXAPI=OFF
+ "${opencl[@]}"
+ "${cuda[@]}"
+ -DGMX_BUILD_MDRUN_ONLY=ON
+ -DBUILD_SHARED_LIBS=OFF
+ -DGMX_BUILD_MANUAL=OFF
+ -DGMX_BINARY_SUFFIX="_mpi${suffix}"
+ -DGMX_LIBS_SUFFIX="_mpi${suffix}"
+ )
+ BUILD_DIR="${WORKDIR}/${P}_${x}_mpi" CC="mpicc" cmake_src_configure
+ [[ ${CHOST} != *-darwin* ]] || \
+ sed -i '/SET(CMAKE_INSTALL_NAME_DIR/s/^/#/' "${WORKDIR}/${P}_${x}_mpi/gentoo_rules.cmake" || die
+ done
+}
+
+src_compile() {
+ for x in ${GMX_DIRS}; do
+ einfo "Compiling for ${x} precision"
+ BUILD_DIR="${WORKDIR}/${P}_${x}"\
+ cmake_src_compile
+ use mpi || continue
+ einfo "Compiling for ${x} precision with mpi"
+ BUILD_DIR="${WORKDIR}/${P}_${x}_mpi"\
+ cmake_src_compile
+ done
+}
+
+src_test() {
+ for x in ${GMX_DIRS}; do
+ BUILD_DIR="${WORKDIR}/${P}_${x}"\
+ cmake_src_compile check
+ done
+}
+
+src_install() {
+ for x in ${GMX_DIRS}; do
+ BUILD_DIR="${WORKDIR}/${P}_${x}" \
+ cmake_src_install
+ if use doc; then
+ newdoc "${DISTDIR}/manual-${PV/_/-}.pdf" "${PN}-manual-${PV}.pdf"
+ fi
+ use mpi || continue
+ BUILD_DIR="${WORKDIR}/${P}_${x}_mpi" \
+ cmake_src_install
+ done
+
+ if use tng; then
+ insinto /usr/include/tng
+ doins src/external/tng_io/include/tng/*h
+ fi
+ # drop unneeded stuff
+ rm "${ED}"/usr/bin/GMXRC* || die
+ for x in "${ED}"/usr/bin/gmx-completion-*.bash ; do
+ local n=${x##*/gmx-completion-}
+ n="${n%.bash}"
+ cat "${ED}"/usr/bin/gmx-completion.bash "$x" > "${T}/${n}" || die
+ newbashcomp "${T}"/"${n}" "${n}"
+ done
+ rm "${ED}"/usr/bin/gmx-completion*.bash || die
+ readme.gentoo_create_doc
+}
+
+pkg_postinst() {
+ einfo
+ einfo "Please read and cite:"
+ einfo "Gromacs 4, J. Chem. Theory Comput. 4, 435 (2008). "
+ einfo "https://dx.doi.org/10.1021/ct700301q"
+ einfo
+ readme.gentoo_print_elog
+}
diff --git a/sci-chemistry/gromacs/gromacs-2020.4.ebuild b/sci-chemistry/gromacs/gromacs-2020.4-r1.ebuild
index 4acfbb38511..b12df9964c0 100644
--- a/sci-chemistry/gromacs/gromacs-2020.4.ebuild
+++ b/sci-chemistry/gromacs/gromacs-2020.4-r1.ebuild
@@ -48,10 +48,10 @@ CDEPEND="
blas? ( virtual/blas )
cuda? ( >=dev-util/nvidia-cuda-toolkit-6.5.14 )
opencl? ( virtual/opencl )
- fftw? ( sci-libs/fftw:3.0 )
- hwloc? ( sys-apps/hwloc )
+ fftw? ( sci-libs/fftw:3.0= )
+ hwloc? ( sys-apps/hwloc:= )
lapack? ( virtual/lapack )
- lmfit? ( sci-libs/lmfit )
+ lmfit? ( sci-libs/lmfit:= )
mkl? ( sci-libs/mkl )
mpi? ( virtual/mpi )
${PYTHON_DEPS}
diff --git a/sci-chemistry/gromacs/gromacs-2020.6.ebuild b/sci-chemistry/gromacs/gromacs-2020.6-r1.ebuild
index ffd92a1f1d7..125ab033266 100644
--- a/sci-chemistry/gromacs/gromacs-2020.6.ebuild
+++ b/sci-chemistry/gromacs/gromacs-2020.6-r1.ebuild
@@ -48,10 +48,10 @@ CDEPEND="
blas? ( virtual/blas )
cuda? ( >=dev-util/nvidia-cuda-toolkit-6.5.14 )
opencl? ( virtual/opencl )
- fftw? ( sci-libs/fftw:3.0 )
- hwloc? ( sys-apps/hwloc )
+ fftw? ( sci-libs/fftw:3.0= )
+ hwloc? ( sys-apps/hwloc:= )
lapack? ( virtual/lapack )
- lmfit? ( sci-libs/lmfit )
+ lmfit? ( sci-libs/lmfit:= )
mkl? ( sci-libs/mkl )
mpi? ( virtual/mpi )
${PYTHON_DEPS}
diff --git a/sci-chemistry/gromacs/gromacs-2021.2.ebuild b/sci-chemistry/gromacs/gromacs-2021.2-r1.ebuild
index c9f47113b4e..5067010bc65 100644
--- a/sci-chemistry/gromacs/gromacs-2021.2.ebuild
+++ b/sci-chemistry/gromacs/gromacs-2021.2-r1.ebuild
@@ -48,10 +48,10 @@ CDEPEND="
blas? ( virtual/blas )
cuda? ( >=dev-util/nvidia-cuda-toolkit-6.5.14[profiler] )
opencl? ( virtual/opencl )
- fftw? ( sci-libs/fftw:3.0 )
+ fftw? ( sci-libs/fftw:3.0= )
hwloc? ( sys-apps/hwloc:= )
lapack? ( virtual/lapack )
- lmfit? ( sci-libs/lmfit )
+ lmfit? ( sci-libs/lmfit:= )
mkl? ( sci-libs/mkl )
mpi? ( virtual/mpi )
${PYTHON_DEPS}
diff --git a/sci-chemistry/gromacs/gromacs-2021.3.ebuild b/sci-chemistry/gromacs/gromacs-2021.3-r1.ebuild
index 12b437ed37e..ade6f56115a 100644
--- a/sci-chemistry/gromacs/gromacs-2021.3.ebuild
+++ b/sci-chemistry/gromacs/gromacs-2021.3-r1.ebuild
@@ -48,10 +48,10 @@ CDEPEND="
blas? ( virtual/blas )
cuda? ( >=dev-util/nvidia-cuda-toolkit-6.5.14[profiler] )
opencl? ( virtual/opencl )
- fftw? ( sci-libs/fftw:3.0 )
+ fftw? ( sci-libs/fftw:3.0= )
hwloc? ( sys-apps/hwloc:= )
lapack? ( virtual/lapack )
- lmfit? ( sci-libs/lmfit )
+ lmfit? ( sci-libs/lmfit:= )
mkl? ( sci-libs/mkl )
mpi? ( virtual/mpi )
${PYTHON_DEPS}
diff --git a/sci-chemistry/gromacs/gromacs-2021.4.ebuild b/sci-chemistry/gromacs/gromacs-2021.4.ebuild
new file mode 100644
index 00000000000..ab6c1d40dd0
--- /dev/null
+++ b/sci-chemistry/gromacs/gromacs-2021.4.ebuild
@@ -0,0 +1,356 @@
+# Copyright 1999-2021 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+CMAKE_MAKEFILE_GENERATOR="ninja"
+
+PYTHON_COMPAT=( python3_{8,9} )
+
+DISTUTILS_USE_SETUPTOOLS=no
+DISTUTILS_SINGLE_IMPL=1
+
+inherit bash-completion-r1 cmake cuda distutils-r1 flag-o-matic multilib readme.gentoo-r1 toolchain-funcs xdg-utils
+
+if [[ ${PV} = *9999* ]]; then
+ EGIT_REPO_URI="
+ https://gitlab.com/gromacs/gromacs.git
+ https://github.com/gromacs/gromacs.git
+ git://git.gromacs.org/gromacs.git"
+ [[ ${PV} = 9999 ]] && EGIT_BRANCH="master" || EGIT_BRANCH="release-${PV:0:4}"
+ inherit git-r3
+else
+ SRC_URI="
+ http://ftp.gromacs.org/gromacs/${PN}-${PV/_/-}.tar.gz
+ doc? ( https://ftp.gromacs.org/manual/manual-${PV/_/-}.pdf )
+ test? ( http://ftp.gromacs.org/regressiontests/regressiontests-${PV/_/-}.tar.gz )"
+ KEYWORDS="~amd64 ~arm ~x86 ~amd64-linux ~x86-linux ~x64-macos"
+fi
+
+ACCE_IUSE="cpu_flags_x86_sse2 cpu_flags_x86_sse4_1 cpu_flags_x86_fma4 cpu_flags_x86_avx cpu_flags_x86_avx2 cpu_flags_x86_avx512f cpu_flags_arm_neon"
+
+DESCRIPTION="The ultimate molecular dynamics simulation package"
+HOMEPAGE="http://www.gromacs.org/"
+
+# see COPYING for details
+# https://repo.or.cz/w/gromacs.git/blob/HEAD:/COPYING
+# base, vmd plugins, fftpack from numpy, blas/lapck from netlib, memtestG80 library, mpi_thread lib
+LICENSE="LGPL-2.1 UoI-NCSA !mkl? ( !fftw? ( BSD ) !blas? ( BSD ) !lapack? ( BSD ) ) cuda? ( LGPL-3 ) threads? ( BSD )"
+SLOT="0/${PV}"
+IUSE="X blas cuda +custom-cflags +doc build-manual double-precision +fftw +gmxapi +gmxapi-legacy +hwloc lapack +lmfit mkl mpi +offensive opencl openmp +python +single-precision test +threads +tng ${ACCE_IUSE}"
+
+CDEPEND="
+ X? (
+ x11-libs/libX11
+ x11-libs/libSM
+ x11-libs/libICE
+ )
+ blas? ( virtual/blas )
+ cuda? ( >=dev-util/nvidia-cuda-toolkit-6.5.14[profiler] )
+ opencl? ( virtual/opencl )
+ fftw? ( sci-libs/fftw:3.0= )
+ hwloc? ( sys-apps/hwloc:= )
+ lapack? ( virtual/lapack )
+ lmfit? ( sci-libs/lmfit:= )
+ mkl? ( sci-libs/mkl )
+ mpi? ( virtual/mpi )
+ ${PYTHON_DEPS}
+ !sci-chemistry/gmxapi
+ "
+BDEPEND="${CDEPEND}
+ virtual/pkgconfig
+ build-manual? (
+ app-doc/doxygen
+ $(python_gen_cond_dep '
+ dev-python/sphinx[${PYTHON_USEDEP}]
+ ')
+ media-gfx/mscgen
+ media-gfx/graphviz
+ dev-texlive/texlive-latex
+ dev-texlive/texlive-latexextra
+ media-gfx/imagemagick
+ )"
+RDEPEND="${CDEPEND}"
+
+REQUIRED_USE="
+ || ( single-precision double-precision )
+ doc? ( !build-manual )
+ cuda? ( single-precision )
+ cuda? ( !opencl )
+ mkl? ( !blas !fftw !lapack )
+ ${PYTHON_REQUIRED_USE}"
+
+DOCS=( AUTHORS README )
+
+RESTRICT="!test? ( test )"
+
+if [[ ${PV} != *9999 ]]; then
+ S="${WORKDIR}/${PN}-${PV/_/-}"
+fi
+
+pkg_pretend() {
+ [[ $(gcc-version) == "4.1" ]] && die "gcc 4.1 is not supported by gromacs"
+ use openmp && ! tc-has-openmp && \
+ die "Please switch to an openmp compatible compiler"
+}
+
+pkg_setup() {
+ python-single-r1_pkg_setup
+}
+
+src_unpack() {
+ if [[ ${PV} != *9999 ]]; then
+ default
+ else
+ git-r3_src_unpack
+ if use test; then
+ EGIT_REPO_URI="git://git.gromacs.org/regressiontests.git" \
+ EGIT_BRANCH="${EGIT_BRANCH}" \
+ EGIT_CHECKOUT_DIR="${WORKDIR}/regressiontests"\
+ git-r3_src_unpack
+ fi
+ fi
+}
+
+src_prepare() {
+ #notes/todos
+ # -on apple: there is framework support
+
+ xdg_environment_reset #591952
+
+ cmake_src_prepare
+
+ use cuda && cuda_src_prepare
+
+ GMX_DIRS=""
+ use single-precision && GMX_DIRS+=" float"
+ use double-precision && GMX_DIRS+=" double"
+
+ if use test; then
+ for x in ${GMX_DIRS}; do
+ mkdir -p "${WORKDIR}/${P}_${x}" || die
+ cp -al "${WORKDIR}/regressiontests"* "${WORKDIR}/${P}_${x}/tests" || die
+ done
+ fi
+
+ DOC_CONTENTS="Gromacs can use sci-chemistry/vmd to read additional file formats"
+ if use build-manual; then
+ # try to create policy for imagemagik
+ mkdir -p ${HOME}/.config/ImageMagick
+ cat >> ${HOME}/.config/ImageMagick/policy.xml <<- EOF
+ <?xml version="1.0" encoding="UTF-8"?>
+ <!DOCTYPE policymap [
+ <!ELEMENT policymap (policy)+>
+ !ATTLIST policymap xmlns CDATA #FIXED ''>
+ <!ELEMENT policy EMPTY>
+ <!ATTLIST policy xmlns CDATA #FIXED '' domain NMTOKEN #REQUIRED
+ name NMTOKEN #IMPLIED pattern CDATA #IMPLIED rights NMTOKEN #IMPLIED
+ stealth NMTOKEN #IMPLIED value CDATA #IMPLIED>
+ ]>
+ <policymap>
+ <policy domain="coder" rights="read | write" pattern="PS" />
+ <policy domain="coder" rights="read | write" pattern="PS2" />
+ <policy domain="coder" rights="read | write" pattern="PS3" />
+ <policy domain="coder" rights="read | write" pattern="EPS" />
+ <policy domain="coder" rights="read | write" pattern="PDF" />
+ <policy domain="coder" rights="read | write" pattern="XPS" />
+ </policymap>
+ EOF
+ fi
+}
+
+src_configure() {
+ local mycmakeargs_pre=( ) extra fft_opts=( )
+ local acce="AUTO"
+
+ if use custom-cflags; then
+ #go from slowest to fastest acceleration
+ acce="None"
+ if (use amd64 || use x86); then
+ use cpu_flags_x86_sse2 && acce="SSE2"
+ use cpu_flags_x86_sse4_1 && acce="SSE4.1"
+ use cpu_flags_x86_fma4 && acce="AVX_128_FMA"
+ use cpu_flags_x86_avx && acce="AVX_256"
+ use cpu_flags_x86_avx2 && acce="AVX2_256"
+ use cpu_flags_x86_avx512f && acce="AVX_512"
+ elif (use arm); then
+ use cpu_flags_arm_neon && acce="ARM_NEON"
+ elif (use arm64); then
+ use cpu_flags_arm_neon && acce="ARM_NEON_ASIMD"
+ fi
+ else
+ strip-flags
+ fi
+
+ #to create man pages, build tree binaries are executed (bug #398437)
+ [[ ${CHOST} = *-darwin* ]] && \
+ extra+=" -DCMAKE_BUILD_WITH_INSTALL_RPATH=OFF"
+
+ if use fftw; then
+ fft_opts=( -DGMX_FFT_LIBRARY=fftw3 )
+ elif use mkl && has_version "=sci-libs/mkl-10*"; then
+ fft_opts=( -DGMX_FFT_LIBRARY=mkl
+ -DMKL_INCLUDE_DIR="${MKLROOT}/include"
+ -DMKL_LIBRARIES="$(echo /opt/intel/mkl/10.0.5.025/lib/*/libmkl.so);$(echo /opt/intel/mkl/10.0.5.025/lib/*/libiomp*.so)"
+ )
+ elif use mkl; then
+ local bits=$(get_libdir)
+ fft_opts=( -DGMX_FFT_LIBRARY=mkl
+ -DMKL_INCLUDE_DIR="$(echo /opt/intel/*/mkl/include)"
+ -DMKL_LIBRARIES="$(echo /opt/intel/*/mkl/lib/*${bits/lib}/libmkl_rt.so)"
+ )
+ else
+ fft_opts=( -DGMX_FFT_LIBRARY=fftpack )
+ fi
+
+ if use lmfit; then
+ local lmfit_opts=( -DGMX_USE_LMFIT=EXTERNAL )
+ else
+ local lmfit_opts=( -DGMX_USE_LMFIT=INTERNAL )
+ fi
+
+ mycmakeargs_pre+=(
+ "${fft_opts[@]}"
+ "${lmfit_opts[@]}"
+ -DGMX_X11=$(usex X)
+ -DGMX_EXTERNAL_BLAS=$(usex blas)
+ -DGMX_EXTERNAL_LAPACK=$(usex lapack)
+ -DGMX_OPENMP=$(usex openmp)
+ -DGMX_COOL_QUOTES=$(usex offensive)
+ -DGMX_USE_TNG=$(usex tng)
+ -DGMX_BUILD_MANUAL=$(usex build-manual)
+ -DGMX_HWLOC=$(usex hwloc)
+ -DGMX_DEFAULT_SUFFIX=off
+ -DGMX_SIMD="$acce"
+ -DGMX_VMD_PLUGIN_PATH="${EPREFIX}/usr/$(get_libdir)/vmd/plugins/*/molfile/"
+ -DBUILD_TESTING=$(usex test)
+ -DGMX_BUILD_UNITTESTS=$(usex test)
+ -DPYTHON_EXECUTABLE="${EPREFIX}/usr/bin/${EPYTHON}"
+ ${extra}
+ )
+
+ for x in ${GMX_DIRS}; do
+ einfo "Configuring for ${x} precision"
+ local suffix=""
+ #if we build single and double - double is suffixed
+ use double-precision && use single-precision && \
+ [[ ${x} = "double" ]] && suffix="_d"
+ local p
+ [[ ${x} = "double" ]] && p="-DGMX_DOUBLE=ON" || p="-DGMX_DOUBLE=OFF"
+ local gpu=( "-DGMX_GPU=OFF" )
+ [[ ${x} = "float" ]] && use cuda && gpu=( "-DGMX_GPU=CUDA" )
+ use opencl && gpu=( "-DGMX_GPU=OPENCL" )
+ mycmakeargs=(
+ ${mycmakeargs_pre[@]} ${p}
+ -DGMX_MPI=OFF
+ -DGMX_THREAD_MPI=$(usex threads)
+ -DGMXAPI=$(usex gmxapi)
+ -DGMX_INSTALL_LEGACY_API=$(usex gmxapi-legacy)
+ "${gpu[@]}"
+ "$(use test && echo -DREGRESSIONTEST_PATH="${WORKDIR}/${P}_${x}/tests")"
+ -DGMX_BINARY_SUFFIX="${suffix}"
+ -DGMX_LIBS_SUFFIX="${suffix}"
+ -DGMX_PYTHON_PACKAGE=$(usex python)
+ )
+ BUILD_DIR="${WORKDIR}/${P}_${x}" cmake_src_configure
+ [[ ${CHOST} != *-darwin* ]] || \
+ sed -i '/SET(CMAKE_INSTALL_NAME_DIR/s/^/#/' "${WORKDIR}/${P}_${x}/gentoo_rules.cmake" || die
+ use mpi || continue
+ einfo "Configuring for ${x} precision with mpi"
+ mycmakeargs=(
+ ${mycmakeargs_pre[@]} ${p}
+ -DGMX_THREAD_MPI=OFF
+ -DGMX_MPI=ON
+ -DGMX_OPENMM=OFF
+ -DGMXAPI=OFF
+ "${opencl[@]}"
+ "${cuda[@]}"
+ -DGMX_BUILD_MDRUN_ONLY=ON
+ -DBUILD_SHARED_LIBS=OFF
+ -DGMX_BUILD_MANUAL=OFF
+ -DGMX_BINARY_SUFFIX="_mpi${suffix}"
+ -DGMX_LIBS_SUFFIX="_mpi${suffix}"
+ )
+ BUILD_DIR="${WORKDIR}/${P}_${x}_mpi" CC="mpicc" cmake_src_configure
+ [[ ${CHOST} != *-darwin* ]] || \
+ sed -i '/SET(CMAKE_INSTALL_NAME_DIR/s/^/#/' "${WORKDIR}/${P}_${x}_mpi/gentoo_rules.cmake" || die
+ done
+}
+
+src_compile() {
+ for x in ${GMX_DIRS}; do
+ einfo "Compiling for ${x} precision"
+ BUILD_DIR="${WORKDIR}/${P}_${x}"\
+ cmake_src_compile
+ if use python; then
+ BUILD_DIR="${WORKDIR}/${P}_${x}"\
+ cmake_src_compile python_packaging/all
+ BUILD_DIR="${WORKDIR}/${P}" \
+ distutils-r1_src_compile
+ fi
+ # not 100% necessary for rel ebuilds as available from website
+ if use build-manual; then
+ BUILD_DIR="${WORKDIR}/${P}_${x}"\
+ cmake_src_compile manual
+ fi
+ use mpi || continue
+ einfo "Compiling for ${x} precision with mpi"
+ BUILD_DIR="${WORKDIR}/${P}_${x}_mpi"\
+ cmake_src_compile
+ done
+}
+
+src_test() {
+ for x in ${GMX_DIRS}; do
+ BUILD_DIR="${WORKDIR}/${P}_${x}"\
+ cmake_src_compile check
+ done
+}
+
+src_install() {
+ for x in ${GMX_DIRS}; do
+ BUILD_DIR="${WORKDIR}/${P}_${x}" \
+ cmake_src_install
+ if use python; then
+ BUILD_DIR="${WORKDIR}/${P}_${x}" \
+ cmake_src_install python_packaging/install
+ fi
+ if use build-manual; then
+ newdoc "${WORKDIR}/${P}_${x}"/docs/manual/gromacs.pdf "${PN}-manual-${PV}.pdf"
+ fi
+
+ if use doc; then
+ if [[ ${PV} != *9999* ]]; then
+ newdoc "${DISTDIR}/manual-${PV}.pdf" "${PN}-manual-${PV}.pdf"
+ fi
+ fi
+
+ use mpi || continue
+ BUILD_DIR="${WORKDIR}/${P}_${x}_mpi" \
+ cmake_src_install
+ done
+
+ if use tng; then
+ insinto /usr/include/tng
+ doins src/external/tng_io/include/tng/*h
+ fi
+ # drop unneeded stuff
+ rm "${ED}"/usr/bin/GMXRC* || die
+ for x in "${ED}"/usr/bin/gmx-completion-*.bash ; do
+ local n=${x##*/gmx-completion-}
+ n="${n%.bash}"
+ cat "${ED}"/usr/bin/gmx-completion.bash "$x" > "${T}/${n}" || die
+ newbashcomp "${T}"/"${n}" "${n}"
+ done
+ rm "${ED}"/usr/bin/gmx-completion*.bash || die
+ readme.gentoo_create_doc
+}
+
+pkg_postinst() {
+ einfo
+ einfo "Please read and cite:"
+ einfo "Gromacs 4, J. Chem. Theory Comput. 4, 435 (2008). "
+ einfo "https://dx.doi.org/10.1021/ct700301q"
+ einfo
+ readme.gentoo_print_elog
+}
diff --git a/sci-chemistry/gromacs/gromacs-2021.9999.ebuild b/sci-chemistry/gromacs/gromacs-2021.9999.ebuild
index ac7420b8135..c135dc43d74 100644
--- a/sci-chemistry/gromacs/gromacs-2021.9999.ebuild
+++ b/sci-chemistry/gromacs/gromacs-2021.9999.ebuild
@@ -48,10 +48,10 @@ CDEPEND="
blas? ( virtual/blas )
cuda? ( >=dev-util/nvidia-cuda-toolkit-6.5.14[profiler] )
opencl? ( virtual/opencl )
- fftw? ( sci-libs/fftw:3.0 )
+ fftw? ( sci-libs/fftw:3.0= )
hwloc? ( sys-apps/hwloc:= )
lapack? ( virtual/lapack )
- lmfit? ( sci-libs/lmfit )
+ lmfit? ( sci-libs/lmfit:= )
mkl? ( sci-libs/mkl )
mpi? ( virtual/mpi )
${PYTHON_DEPS}
diff --git a/sci-chemistry/gromacs/gromacs-2022.9999.ebuild b/sci-chemistry/gromacs/gromacs-2022.9999.ebuild
new file mode 100644
index 00000000000..8b7107ecad9
--- /dev/null
+++ b/sci-chemistry/gromacs/gromacs-2022.9999.ebuild
@@ -0,0 +1,349 @@
+# Copyright 1999-2021 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+CMAKE_MAKEFILE_GENERATOR="ninja"
+
+PYTHON_COMPAT=( python3_{8,9,10} )
+
+DISTUTILS_USE_SETUPTOOLS=no
+DISTUTILS_SINGLE_IMPL=1
+
+inherit bash-completion-r1 cmake cuda distutils-r1 flag-o-matic readme.gentoo-r1 toolchain-funcs xdg-utils
+
+if [[ ${PV} = *9999* ]]; then
+ EGIT_REPO_URI="
+ https://gitlab.com/gromacs/gromacs.git
+ https://github.com/gromacs/gromacs.git
+ git://git.gromacs.org/gromacs.git"
+ [[ ${PV} = 9999 ]] && EGIT_BRANCH="master" || EGIT_BRANCH="release-${PV:0:4}"
+ inherit git-r3
+else
+ SRC_URI="
+ http://ftp.gromacs.org/gromacs/${PN}-${PV/_/-}.tar.gz
+ doc? ( https://ftp.gromacs.org/manual/manual-${PV/_/-}.pdf -> manual-${PV}.pdf )
+ test? ( http://ftp.gromacs.org/regressiontests/regressiontests-${PV/_/-}.tar.gz )"
+ KEYWORDS="~amd64 ~x86 ~amd64-linux ~x86-linux ~x64-macos"
+fi
+
+ACCE_IUSE="cpu_flags_x86_sse2 cpu_flags_x86_sse4_1 cpu_flags_x86_fma4 cpu_flags_x86_avx cpu_flags_x86_avx2 cpu_flags_x86_avx512f cpu_flags_arm_neon"
+
+DESCRIPTION="The ultimate molecular dynamics simulation package"
+HOMEPAGE="http://www.gromacs.org/"
+
+# see COPYING for details
+# https://repo.or.cz/w/gromacs.git/blob/HEAD:/COPYING
+# base, vmd plugins, fftpack from numpy, blas/lapck from netlib, memtestG80 library, mpi_thread lib
+LICENSE="LGPL-2.1 UoI-NCSA !mkl? ( !fftw? ( BSD ) !blas? ( BSD ) !lapack? ( BSD ) ) cuda? ( LGPL-3 ) threads? ( BSD )"
+SLOT="0/${PV}"
+IUSE="blas cuda +custom-cflags +doc build-manual double-precision +fftw +gmxapi +gmxapi-legacy +hwloc lapack mkl mpi +offensive opencl openmp +python +single-precision test +threads +tng ${ACCE_IUSE}"
+
+CDEPEND="
+ blas? ( virtual/blas )
+ cuda? ( >=dev-util/nvidia-cuda-toolkit-6.5.14[profiler] )
+ opencl? ( virtual/opencl )
+ fftw? ( sci-libs/fftw:3.0= )
+ hwloc? ( sys-apps/hwloc:= )
+ lapack? ( virtual/lapack )
+ mkl? ( sci-libs/mkl )
+ mpi? ( virtual/mpi[cxx] )
+ sci-libs/lmfit:=
+ >=dev-cpp/muParser-2.3:=
+ ${PYTHON_DEPS}
+ !sci-chemistry/gmxapi
+ "
+BDEPEND="${CDEPEND}
+ virtual/pkgconfig
+ build-manual? (
+ app-doc/doxygen
+ $(python_gen_cond_dep '
+ dev-python/sphinx[${PYTHON_USEDEP}]
+ ')
+ media-gfx/mscgen
+ media-gfx/graphviz
+ dev-texlive/texlive-latex
+ dev-texlive/texlive-latexextra
+ media-gfx/imagemagick
+ )"
+RDEPEND="${CDEPEND}
+ <sci-chemistry/dssp-4"
+
+REQUIRED_USE="
+ || ( single-precision double-precision )
+ doc? ( !build-manual )
+ cuda? ( single-precision )
+ cuda? ( !opencl )
+ mkl? ( !blas !fftw !lapack )
+ ${PYTHON_REQUIRED_USE}"
+
+DOCS=( AUTHORS README )
+
+RESTRICT="!test? ( test )"
+
+if [[ ${PV} != *9999 ]]; then
+ S="${WORKDIR}/${PN}-${PV/_/-}"
+fi
+
+pkg_pretend() {
+ [[ $(gcc-version) == "4.1" ]] && die "gcc 4.1 is not supported by gromacs"
+ use openmp && ! tc-has-openmp && \
+ die "Please switch to an openmp compatible compiler"
+}
+
+pkg_setup() {
+ python-single-r1_pkg_setup
+}
+
+src_unpack() {
+ if [[ ${PV} != *9999 ]]; then
+ default
+ else
+ git-r3_src_unpack
+ if use test; then
+ EGIT_REPO_URI="git://git.gromacs.org/regressiontests.git" \
+ EGIT_BRANCH="${EGIT_BRANCH}" \
+ EGIT_CHECKOUT_DIR="${WORKDIR}/regressiontests"\
+ git-r3_src_unpack
+ fi
+ fi
+}
+
+src_prepare() {
+ #notes/todos
+ # -on apple: there is framework support
+
+ xdg_environment_reset #591952
+
+ cmake_src_prepare
+
+ use cuda && cuda_src_prepare
+
+ GMX_DIRS=""
+ use single-precision && GMX_DIRS+=" float"
+ use double-precision && GMX_DIRS+=" double"
+
+ if use test; then
+ for x in ${GMX_DIRS}; do
+ mkdir -p "${WORKDIR}/${P}_${x}" || die
+ cp -al "${WORKDIR}/regressiontests"* "${WORKDIR}/${P}_${x}/tests" || die
+ done
+ fi
+
+ DOC_CONTENTS="Gromacs can use sci-chemistry/vmd to read additional file formats"
+ if use build-manual; then
+ # try to create policy for imagemagik
+ mkdir -p ${HOME}/.config/ImageMagick
+ cat >> ${HOME}/.config/ImageMagick/policy.xml <<- EOF
+ <?xml version="1.0" encoding="UTF-8"?>
+ <!DOCTYPE policymap [
+ <!ELEMENT policymap (policy)+>
+ !ATTLIST policymap xmlns CDATA #FIXED ''>
+ <!ELEMENT policy EMPTY>
+ <!ATTLIST policy xmlns CDATA #FIXED '' domain NMTOKEN #REQUIRED
+ name NMTOKEN #IMPLIED pattern CDATA #IMPLIED rights NMTOKEN #IMPLIED
+ stealth NMTOKEN #IMPLIED value CDATA #IMPLIED>
+ ]>
+ <policymap>
+ <policy domain="coder" rights="read | write" pattern="PS" />
+ <policy domain="coder" rights="read | write" pattern="PS2" />
+ <policy domain="coder" rights="read | write" pattern="PS3" />
+ <policy domain="coder" rights="read | write" pattern="EPS" />
+ <policy domain="coder" rights="read | write" pattern="PDF" />
+ <policy domain="coder" rights="read | write" pattern="XPS" />
+ </policymap>
+ EOF
+ fi
+}
+
+src_configure() {
+ local mycmakeargs_pre=( ) extra fft_opts=( )
+ local acce="AUTO"
+
+ if use custom-cflags; then
+ #go from slowest to fastest acceleration
+ acce="None"
+ if (use amd64 || use x86); then
+ use cpu_flags_x86_sse2 && acce="SSE2"
+ use cpu_flags_x86_sse4_1 && acce="SSE4.1"
+ use cpu_flags_x86_fma4 && acce="AVX_128_FMA"
+ use cpu_flags_x86_avx && acce="AVX_256"
+ use cpu_flags_x86_avx2 && acce="AVX2_256"
+ use cpu_flags_x86_avx512f && acce="AVX_512"
+ elif (use arm); then
+ use cpu_flags_arm_neon && acce="ARM_NEON"
+ elif (use arm64); then
+ use cpu_flags_arm_neon && acce="ARM_NEON_ASIMD"
+ fi
+ else
+ strip-flags
+ fi
+
+ #to create man pages, build tree binaries are executed (bug #398437)
+ [[ ${CHOST} = *-darwin* ]] && \
+ extra+=" -DCMAKE_BUILD_WITH_INSTALL_RPATH=OFF"
+
+ if use fftw; then
+ fft_opts=( -DGMX_FFT_LIBRARY=fftw3 )
+ elif use mkl && has_version "=sci-libs/mkl-10*"; then
+ fft_opts=( -DGMX_FFT_LIBRARY=mkl
+ -DMKL_INCLUDE_DIR="${MKLROOT}/include"
+ -DMKL_LIBRARIES="$(echo /opt/intel/mkl/10.0.5.025/lib/*/libmkl.so);$(echo /opt/intel/mkl/10.0.5.025/lib/*/libiomp*.so)"
+ )
+ elif use mkl; then
+ local bits=$(get_libdir)
+ fft_opts=( -DGMX_FFT_LIBRARY=mkl
+ -DMKL_INCLUDE_DIR="$(echo /opt/intel/*/mkl/include)"
+ -DMKL_LIBRARIES="$(echo /opt/intel/*/mkl/lib/*${bits/lib}/libmkl_rt.so)"
+ )
+ else
+ fft_opts=( -DGMX_FFT_LIBRARY=fftpack )
+ fi
+
+ mycmakeargs_pre+=(
+ "${fft_opts[@]}"
+ "${lmfit_opts[@]}"
+ -DGMX_USE_LMFIT=EXTERNAL
+ -DGMX_USE_MUPARSER=EXTERNAL
+ -DGMX_EXTERNAL_BLAS=$(usex blas)
+ -DGMX_EXTERNAL_LAPACK=$(usex lapack)
+ -DGMX_OPENMP=$(usex openmp)
+ -DGMX_COOL_QUOTES=$(usex offensive)
+ -DGMX_USE_TNG=$(usex tng)
+ -DGMX_BUILD_MANUAL=$(usex build-manual)
+ -DGMX_HWLOC=$(usex hwloc)
+ -DGMX_DEFAULT_SUFFIX=off
+ -DGMX_SIMD="$acce"
+ -DGMX_VMD_PLUGIN_PATH="${EPREFIX}/usr/$(get_libdir)/vmd/plugins/*/molfile/"
+ -DGMX_DSSP_PROGRAM_PATH="${EPREFIX}/usr/bin/dssp"
+ -DBUILD_TESTING=$(usex test)
+ -DGMX_BUILD_UNITTESTS=$(usex test)
+ -DPYTHON_EXECUTABLE="${EPREFIX}/usr/bin/${EPYTHON}"
+ ${extra}
+ )
+
+ for x in ${GMX_DIRS}; do
+ einfo "Configuring for ${x} precision"
+ local suffix=""
+ #if we build single and double - double is suffixed
+ use double-precision && use single-precision && \
+ [[ ${x} = "double" ]] && suffix="_d"
+ local p
+ [[ ${x} = "double" ]] && p="-DGMX_DOUBLE=ON" || p="-DGMX_DOUBLE=OFF"
+ local gpu=( "-DGMX_GPU=OFF" )
+ [[ ${x} = "float" ]] && use cuda && gpu=( "-DGMX_GPU=CUDA" )
+ use opencl && gpu=( "-DGMX_GPU=OPENCL" )
+ mycmakeargs=(
+ ${mycmakeargs_pre[@]} ${p}
+ -DGMX_MPI=OFF
+ -DGMX_THREAD_MPI=$(usex threads)
+ -DGMXAPI=$(usex gmxapi)
+ -DGMX_INSTALL_LEGACY_API=$(usex gmxapi-legacy)
+ "${gpu[@]}"
+ "$(use test && echo -DREGRESSIONTEST_PATH="${WORKDIR}/${P}_${x}/tests")"
+ -DGMX_BINARY_SUFFIX="${suffix}"
+ -DGMX_LIBS_SUFFIX="${suffix}"
+ -DGMX_PYTHON_PACKAGE=$(usex python)
+ )
+ BUILD_DIR="${WORKDIR}/${P}_${x}" cmake_src_configure
+ [[ ${CHOST} != *-darwin* ]] || \
+ sed -i '/SET(CMAKE_INSTALL_NAME_DIR/s/^/#/' "${WORKDIR}/${P}_${x}/gentoo_rules.cmake" || die
+ use mpi || continue
+ einfo "Configuring for ${x} precision with mpi"
+ mycmakeargs=(
+ ${mycmakeargs_pre[@]} ${p}
+ -DGMX_THREAD_MPI=OFF
+ -DGMX_MPI=ON
+ -DGMX_OPENMM=OFF
+ -DGMXAPI=OFF
+ "${opencl[@]}"
+ "${cuda[@]}"
+ -DGMX_BUILD_MDRUN_ONLY=ON
+ -DBUILD_SHARED_LIBS=OFF
+ -DGMX_BUILD_MANUAL=OFF
+ -DGMX_BINARY_SUFFIX="_mpi${suffix}"
+ -DGMX_LIBS_SUFFIX="_mpi${suffix}"
+ )
+ BUILD_DIR="${WORKDIR}/${P}_${x}_mpi" CC="mpicc" cmake_src_configure
+ [[ ${CHOST} != *-darwin* ]] || \
+ sed -i '/SET(CMAKE_INSTALL_NAME_DIR/s/^/#/' "${WORKDIR}/${P}_${x}_mpi/gentoo_rules.cmake" || die
+ done
+}
+
+src_compile() {
+ for x in ${GMX_DIRS}; do
+ einfo "Compiling for ${x} precision"
+ BUILD_DIR="${WORKDIR}/${P}_${x}"\
+ cmake_src_compile
+ if use python; then
+ BUILD_DIR="${WORKDIR}/${P}_${x}"\
+ cmake_src_compile python_packaging/all
+ BUILD_DIR="${WORKDIR}/${P}" \
+ distutils-r1_src_compile
+ fi
+ # not 100% necessary for rel ebuilds as available from website
+ if use build-manual; then
+ BUILD_DIR="${WORKDIR}/${P}_${x}"\
+ cmake_src_compile manual
+ fi
+ use mpi || continue
+ einfo "Compiling for ${x} precision with mpi"
+ BUILD_DIR="${WORKDIR}/${P}_${x}_mpi"\
+ cmake_src_compile
+ done
+}
+
+src_test() {
+ for x in ${GMX_DIRS}; do
+ BUILD_DIR="${WORKDIR}/${P}_${x}"\
+ cmake_src_compile check
+ done
+}
+
+src_install() {
+ for x in ${GMX_DIRS}; do
+ BUILD_DIR="${WORKDIR}/${P}_${x}" \
+ cmake_src_install
+ if use python; then
+ BUILD_DIR="${WORKDIR}/${P}_${x}" \
+ cmake_src_install python_packaging/install
+ fi
+ if use build-manual; then
+ newdoc "${WORKDIR}/${P}_${x}"/docs/manual/gromacs.pdf "${PN}-manual-${PV}.pdf"
+ fi
+
+ if use doc; then
+ if [[ ${PV} != *9999* ]]; then
+ newdoc "${DISTDIR}/manual-${PV}.pdf" "${PN}-manual-${PV}.pdf"
+ fi
+ fi
+
+ use mpi || continue
+ BUILD_DIR="${WORKDIR}/${P}_${x}_mpi" \
+ cmake_src_install
+ done
+
+ if use tng; then
+ insinto /usr/include/tng
+ doins src/external/tng_io/include/tng/*h
+ fi
+ # drop unneeded stuff
+ rm "${ED}"/usr/bin/GMXRC* || die
+ for x in "${ED}"/usr/bin/gmx-completion-*.bash ; do
+ local n=${x##*/gmx-completion-}
+ n="${n%.bash}"
+ cat "${ED}"/usr/bin/gmx-completion.bash "$x" > "${T}/${n}" || die
+ newbashcomp "${T}"/"${n}" "${n}"
+ done
+ rm "${ED}"/usr/bin/gmx-completion*.bash || die
+ readme.gentoo_create_doc
+}
+
+pkg_postinst() {
+ einfo
+ einfo "Please read and cite:"
+ einfo "Gromacs 4, J. Chem. Theory Comput. 4, 435 (2008). "
+ einfo "https://dx.doi.org/10.1021/ct700301q"
+ einfo
+ readme.gentoo_print_elog
+}
diff --git a/sci-chemistry/gromacs/gromacs-2022_beta1-r2.ebuild b/sci-chemistry/gromacs/gromacs-2022_beta1-r2.ebuild
new file mode 100644
index 00000000000..8b7107ecad9
--- /dev/null
+++ b/sci-chemistry/gromacs/gromacs-2022_beta1-r2.ebuild
@@ -0,0 +1,349 @@
+# Copyright 1999-2021 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+CMAKE_MAKEFILE_GENERATOR="ninja"
+
+PYTHON_COMPAT=( python3_{8,9,10} )
+
+DISTUTILS_USE_SETUPTOOLS=no
+DISTUTILS_SINGLE_IMPL=1
+
+inherit bash-completion-r1 cmake cuda distutils-r1 flag-o-matic readme.gentoo-r1 toolchain-funcs xdg-utils
+
+if [[ ${PV} = *9999* ]]; then
+ EGIT_REPO_URI="
+ https://gitlab.com/gromacs/gromacs.git
+ https://github.com/gromacs/gromacs.git
+ git://git.gromacs.org/gromacs.git"
+ [[ ${PV} = 9999 ]] && EGIT_BRANCH="master" || EGIT_BRANCH="release-${PV:0:4}"
+ inherit git-r3
+else
+ SRC_URI="
+ http://ftp.gromacs.org/gromacs/${PN}-${PV/_/-}.tar.gz
+ doc? ( https://ftp.gromacs.org/manual/manual-${PV/_/-}.pdf -> manual-${PV}.pdf )
+ test? ( http://ftp.gromacs.org/regressiontests/regressiontests-${PV/_/-}.tar.gz )"
+ KEYWORDS="~amd64 ~x86 ~amd64-linux ~x86-linux ~x64-macos"
+fi
+
+ACCE_IUSE="cpu_flags_x86_sse2 cpu_flags_x86_sse4_1 cpu_flags_x86_fma4 cpu_flags_x86_avx cpu_flags_x86_avx2 cpu_flags_x86_avx512f cpu_flags_arm_neon"
+
+DESCRIPTION="The ultimate molecular dynamics simulation package"
+HOMEPAGE="http://www.gromacs.org/"
+
+# see COPYING for details
+# https://repo.or.cz/w/gromacs.git/blob/HEAD:/COPYING
+# base, vmd plugins, fftpack from numpy, blas/lapck from netlib, memtestG80 library, mpi_thread lib
+LICENSE="LGPL-2.1 UoI-NCSA !mkl? ( !fftw? ( BSD ) !blas? ( BSD ) !lapack? ( BSD ) ) cuda? ( LGPL-3 ) threads? ( BSD )"
+SLOT="0/${PV}"
+IUSE="blas cuda +custom-cflags +doc build-manual double-precision +fftw +gmxapi +gmxapi-legacy +hwloc lapack mkl mpi +offensive opencl openmp +python +single-precision test +threads +tng ${ACCE_IUSE}"
+
+CDEPEND="
+ blas? ( virtual/blas )
+ cuda? ( >=dev-util/nvidia-cuda-toolkit-6.5.14[profiler] )
+ opencl? ( virtual/opencl )
+ fftw? ( sci-libs/fftw:3.0= )
+ hwloc? ( sys-apps/hwloc:= )
+ lapack? ( virtual/lapack )
+ mkl? ( sci-libs/mkl )
+ mpi? ( virtual/mpi[cxx] )
+ sci-libs/lmfit:=
+ >=dev-cpp/muParser-2.3:=
+ ${PYTHON_DEPS}
+ !sci-chemistry/gmxapi
+ "
+BDEPEND="${CDEPEND}
+ virtual/pkgconfig
+ build-manual? (
+ app-doc/doxygen
+ $(python_gen_cond_dep '
+ dev-python/sphinx[${PYTHON_USEDEP}]
+ ')
+ media-gfx/mscgen
+ media-gfx/graphviz
+ dev-texlive/texlive-latex
+ dev-texlive/texlive-latexextra
+ media-gfx/imagemagick
+ )"
+RDEPEND="${CDEPEND}
+ <sci-chemistry/dssp-4"
+
+REQUIRED_USE="
+ || ( single-precision double-precision )
+ doc? ( !build-manual )
+ cuda? ( single-precision )
+ cuda? ( !opencl )
+ mkl? ( !blas !fftw !lapack )
+ ${PYTHON_REQUIRED_USE}"
+
+DOCS=( AUTHORS README )
+
+RESTRICT="!test? ( test )"
+
+if [[ ${PV} != *9999 ]]; then
+ S="${WORKDIR}/${PN}-${PV/_/-}"
+fi
+
+pkg_pretend() {
+ [[ $(gcc-version) == "4.1" ]] && die "gcc 4.1 is not supported by gromacs"
+ use openmp && ! tc-has-openmp && \
+ die "Please switch to an openmp compatible compiler"
+}
+
+pkg_setup() {
+ python-single-r1_pkg_setup
+}
+
+src_unpack() {
+ if [[ ${PV} != *9999 ]]; then
+ default
+ else
+ git-r3_src_unpack
+ if use test; then
+ EGIT_REPO_URI="git://git.gromacs.org/regressiontests.git" \
+ EGIT_BRANCH="${EGIT_BRANCH}" \
+ EGIT_CHECKOUT_DIR="${WORKDIR}/regressiontests"\
+ git-r3_src_unpack
+ fi
+ fi
+}
+
+src_prepare() {
+ #notes/todos
+ # -on apple: there is framework support
+
+ xdg_environment_reset #591952
+
+ cmake_src_prepare
+
+ use cuda && cuda_src_prepare
+
+ GMX_DIRS=""
+ use single-precision && GMX_DIRS+=" float"
+ use double-precision && GMX_DIRS+=" double"
+
+ if use test; then
+ for x in ${GMX_DIRS}; do
+ mkdir -p "${WORKDIR}/${P}_${x}" || die
+ cp -al "${WORKDIR}/regressiontests"* "${WORKDIR}/${P}_${x}/tests" || die
+ done
+ fi
+
+ DOC_CONTENTS="Gromacs can use sci-chemistry/vmd to read additional file formats"
+ if use build-manual; then
+ # try to create policy for imagemagik
+ mkdir -p ${HOME}/.config/ImageMagick
+ cat >> ${HOME}/.config/ImageMagick/policy.xml <<- EOF
+ <?xml version="1.0" encoding="UTF-8"?>
+ <!DOCTYPE policymap [
+ <!ELEMENT policymap (policy)+>
+ !ATTLIST policymap xmlns CDATA #FIXED ''>
+ <!ELEMENT policy EMPTY>
+ <!ATTLIST policy xmlns CDATA #FIXED '' domain NMTOKEN #REQUIRED
+ name NMTOKEN #IMPLIED pattern CDATA #IMPLIED rights NMTOKEN #IMPLIED
+ stealth NMTOKEN #IMPLIED value CDATA #IMPLIED>
+ ]>
+ <policymap>
+ <policy domain="coder" rights="read | write" pattern="PS" />
+ <policy domain="coder" rights="read | write" pattern="PS2" />
+ <policy domain="coder" rights="read | write" pattern="PS3" />
+ <policy domain="coder" rights="read | write" pattern="EPS" />
+ <policy domain="coder" rights="read | write" pattern="PDF" />
+ <policy domain="coder" rights="read | write" pattern="XPS" />
+ </policymap>
+ EOF
+ fi
+}
+
+src_configure() {
+ local mycmakeargs_pre=( ) extra fft_opts=( )
+ local acce="AUTO"
+
+ if use custom-cflags; then
+ #go from slowest to fastest acceleration
+ acce="None"
+ if (use amd64 || use x86); then
+ use cpu_flags_x86_sse2 && acce="SSE2"
+ use cpu_flags_x86_sse4_1 && acce="SSE4.1"
+ use cpu_flags_x86_fma4 && acce="AVX_128_FMA"
+ use cpu_flags_x86_avx && acce="AVX_256"
+ use cpu_flags_x86_avx2 && acce="AVX2_256"
+ use cpu_flags_x86_avx512f && acce="AVX_512"
+ elif (use arm); then
+ use cpu_flags_arm_neon && acce="ARM_NEON"
+ elif (use arm64); then
+ use cpu_flags_arm_neon && acce="ARM_NEON_ASIMD"
+ fi
+ else
+ strip-flags
+ fi
+
+ #to create man pages, build tree binaries are executed (bug #398437)
+ [[ ${CHOST} = *-darwin* ]] && \
+ extra+=" -DCMAKE_BUILD_WITH_INSTALL_RPATH=OFF"
+
+ if use fftw; then
+ fft_opts=( -DGMX_FFT_LIBRARY=fftw3 )
+ elif use mkl && has_version "=sci-libs/mkl-10*"; then
+ fft_opts=( -DGMX_FFT_LIBRARY=mkl
+ -DMKL_INCLUDE_DIR="${MKLROOT}/include"
+ -DMKL_LIBRARIES="$(echo /opt/intel/mkl/10.0.5.025/lib/*/libmkl.so);$(echo /opt/intel/mkl/10.0.5.025/lib/*/libiomp*.so)"
+ )
+ elif use mkl; then
+ local bits=$(get_libdir)
+ fft_opts=( -DGMX_FFT_LIBRARY=mkl
+ -DMKL_INCLUDE_DIR="$(echo /opt/intel/*/mkl/include)"
+ -DMKL_LIBRARIES="$(echo /opt/intel/*/mkl/lib/*${bits/lib}/libmkl_rt.so)"
+ )
+ else
+ fft_opts=( -DGMX_FFT_LIBRARY=fftpack )
+ fi
+
+ mycmakeargs_pre+=(
+ "${fft_opts[@]}"
+ "${lmfit_opts[@]}"
+ -DGMX_USE_LMFIT=EXTERNAL
+ -DGMX_USE_MUPARSER=EXTERNAL
+ -DGMX_EXTERNAL_BLAS=$(usex blas)
+ -DGMX_EXTERNAL_LAPACK=$(usex lapack)
+ -DGMX_OPENMP=$(usex openmp)
+ -DGMX_COOL_QUOTES=$(usex offensive)
+ -DGMX_USE_TNG=$(usex tng)
+ -DGMX_BUILD_MANUAL=$(usex build-manual)
+ -DGMX_HWLOC=$(usex hwloc)
+ -DGMX_DEFAULT_SUFFIX=off
+ -DGMX_SIMD="$acce"
+ -DGMX_VMD_PLUGIN_PATH="${EPREFIX}/usr/$(get_libdir)/vmd/plugins/*/molfile/"
+ -DGMX_DSSP_PROGRAM_PATH="${EPREFIX}/usr/bin/dssp"
+ -DBUILD_TESTING=$(usex test)
+ -DGMX_BUILD_UNITTESTS=$(usex test)
+ -DPYTHON_EXECUTABLE="${EPREFIX}/usr/bin/${EPYTHON}"
+ ${extra}
+ )
+
+ for x in ${GMX_DIRS}; do
+ einfo "Configuring for ${x} precision"
+ local suffix=""
+ #if we build single and double - double is suffixed
+ use double-precision && use single-precision && \
+ [[ ${x} = "double" ]] && suffix="_d"
+ local p
+ [[ ${x} = "double" ]] && p="-DGMX_DOUBLE=ON" || p="-DGMX_DOUBLE=OFF"
+ local gpu=( "-DGMX_GPU=OFF" )
+ [[ ${x} = "float" ]] && use cuda && gpu=( "-DGMX_GPU=CUDA" )
+ use opencl && gpu=( "-DGMX_GPU=OPENCL" )
+ mycmakeargs=(
+ ${mycmakeargs_pre[@]} ${p}
+ -DGMX_MPI=OFF
+ -DGMX_THREAD_MPI=$(usex threads)
+ -DGMXAPI=$(usex gmxapi)
+ -DGMX_INSTALL_LEGACY_API=$(usex gmxapi-legacy)
+ "${gpu[@]}"
+ "$(use test && echo -DREGRESSIONTEST_PATH="${WORKDIR}/${P}_${x}/tests")"
+ -DGMX_BINARY_SUFFIX="${suffix}"
+ -DGMX_LIBS_SUFFIX="${suffix}"
+ -DGMX_PYTHON_PACKAGE=$(usex python)
+ )
+ BUILD_DIR="${WORKDIR}/${P}_${x}" cmake_src_configure
+ [[ ${CHOST} != *-darwin* ]] || \
+ sed -i '/SET(CMAKE_INSTALL_NAME_DIR/s/^/#/' "${WORKDIR}/${P}_${x}/gentoo_rules.cmake" || die
+ use mpi || continue
+ einfo "Configuring for ${x} precision with mpi"
+ mycmakeargs=(
+ ${mycmakeargs_pre[@]} ${p}
+ -DGMX_THREAD_MPI=OFF
+ -DGMX_MPI=ON
+ -DGMX_OPENMM=OFF
+ -DGMXAPI=OFF
+ "${opencl[@]}"
+ "${cuda[@]}"
+ -DGMX_BUILD_MDRUN_ONLY=ON
+ -DBUILD_SHARED_LIBS=OFF
+ -DGMX_BUILD_MANUAL=OFF
+ -DGMX_BINARY_SUFFIX="_mpi${suffix}"
+ -DGMX_LIBS_SUFFIX="_mpi${suffix}"
+ )
+ BUILD_DIR="${WORKDIR}/${P}_${x}_mpi" CC="mpicc" cmake_src_configure
+ [[ ${CHOST} != *-darwin* ]] || \
+ sed -i '/SET(CMAKE_INSTALL_NAME_DIR/s/^/#/' "${WORKDIR}/${P}_${x}_mpi/gentoo_rules.cmake" || die
+ done
+}
+
+src_compile() {
+ for x in ${GMX_DIRS}; do
+ einfo "Compiling for ${x} precision"
+ BUILD_DIR="${WORKDIR}/${P}_${x}"\
+ cmake_src_compile
+ if use python; then
+ BUILD_DIR="${WORKDIR}/${P}_${x}"\
+ cmake_src_compile python_packaging/all
+ BUILD_DIR="${WORKDIR}/${P}" \
+ distutils-r1_src_compile
+ fi
+ # not 100% necessary for rel ebuilds as available from website
+ if use build-manual; then
+ BUILD_DIR="${WORKDIR}/${P}_${x}"\
+ cmake_src_compile manual
+ fi
+ use mpi || continue
+ einfo "Compiling for ${x} precision with mpi"
+ BUILD_DIR="${WORKDIR}/${P}_${x}_mpi"\
+ cmake_src_compile
+ done
+}
+
+src_test() {
+ for x in ${GMX_DIRS}; do
+ BUILD_DIR="${WORKDIR}/${P}_${x}"\
+ cmake_src_compile check
+ done
+}
+
+src_install() {
+ for x in ${GMX_DIRS}; do
+ BUILD_DIR="${WORKDIR}/${P}_${x}" \
+ cmake_src_install
+ if use python; then
+ BUILD_DIR="${WORKDIR}/${P}_${x}" \
+ cmake_src_install python_packaging/install
+ fi
+ if use build-manual; then
+ newdoc "${WORKDIR}/${P}_${x}"/docs/manual/gromacs.pdf "${PN}-manual-${PV}.pdf"
+ fi
+
+ if use doc; then
+ if [[ ${PV} != *9999* ]]; then
+ newdoc "${DISTDIR}/manual-${PV}.pdf" "${PN}-manual-${PV}.pdf"
+ fi
+ fi
+
+ use mpi || continue
+ BUILD_DIR="${WORKDIR}/${P}_${x}_mpi" \
+ cmake_src_install
+ done
+
+ if use tng; then
+ insinto /usr/include/tng
+ doins src/external/tng_io/include/tng/*h
+ fi
+ # drop unneeded stuff
+ rm "${ED}"/usr/bin/GMXRC* || die
+ for x in "${ED}"/usr/bin/gmx-completion-*.bash ; do
+ local n=${x##*/gmx-completion-}
+ n="${n%.bash}"
+ cat "${ED}"/usr/bin/gmx-completion.bash "$x" > "${T}/${n}" || die
+ newbashcomp "${T}"/"${n}" "${n}"
+ done
+ rm "${ED}"/usr/bin/gmx-completion*.bash || die
+ readme.gentoo_create_doc
+}
+
+pkg_postinst() {
+ einfo
+ einfo "Please read and cite:"
+ einfo "Gromacs 4, J. Chem. Theory Comput. 4, 435 (2008). "
+ einfo "https://dx.doi.org/10.1021/ct700301q"
+ einfo
+ readme.gentoo_print_elog
+}
diff --git a/sci-chemistry/gromacs/gromacs-9999.ebuild b/sci-chemistry/gromacs/gromacs-9999.ebuild
index ac7420b8135..8b7107ecad9 100644
--- a/sci-chemistry/gromacs/gromacs-9999.ebuild
+++ b/sci-chemistry/gromacs/gromacs-9999.ebuild
@@ -1,16 +1,16 @@
# Copyright 1999-2021 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
-EAPI=7
+EAPI=8
CMAKE_MAKEFILE_GENERATOR="ninja"
-PYTHON_COMPAT=( python3_{8,9} )
+PYTHON_COMPAT=( python3_{8,9,10} )
DISTUTILS_USE_SETUPTOOLS=no
DISTUTILS_SINGLE_IMPL=1
-inherit bash-completion-r1 cmake cuda distutils-r1 flag-o-matic multilib readme.gentoo-r1 toolchain-funcs xdg-utils
+inherit bash-completion-r1 cmake cuda distutils-r1 flag-o-matic readme.gentoo-r1 toolchain-funcs xdg-utils
if [[ ${PV} = *9999* ]]; then
EGIT_REPO_URI="
@@ -22,9 +22,9 @@ if [[ ${PV} = *9999* ]]; then
else
SRC_URI="
http://ftp.gromacs.org/gromacs/${PN}-${PV/_/-}.tar.gz
- doc? ( https://ftp.gromacs.org/manual/manual-${PV/_/-}.pdf )
+ doc? ( https://ftp.gromacs.org/manual/manual-${PV/_/-}.pdf -> manual-${PV}.pdf )
test? ( http://ftp.gromacs.org/regressiontests/regressiontests-${PV/_/-}.tar.gz )"
- KEYWORDS="~amd64 ~arm ~x86 ~amd64-linux ~x86-linux ~x64-macos"
+ KEYWORDS="~amd64 ~x86 ~amd64-linux ~x86-linux ~x64-macos"
fi
ACCE_IUSE="cpu_flags_x86_sse2 cpu_flags_x86_sse4_1 cpu_flags_x86_fma4 cpu_flags_x86_avx cpu_flags_x86_avx2 cpu_flags_x86_avx512f cpu_flags_arm_neon"
@@ -37,23 +37,19 @@ HOMEPAGE="http://www.gromacs.org/"
# base, vmd plugins, fftpack from numpy, blas/lapck from netlib, memtestG80 library, mpi_thread lib
LICENSE="LGPL-2.1 UoI-NCSA !mkl? ( !fftw? ( BSD ) !blas? ( BSD ) !lapack? ( BSD ) ) cuda? ( LGPL-3 ) threads? ( BSD )"
SLOT="0/${PV}"
-IUSE="X blas cuda +custom-cflags +doc build-manual double-precision +fftw +gmxapi +gmxapi-legacy +hwloc lapack +lmfit mkl mpi +offensive opencl openmp +python +single-precision test +threads +tng ${ACCE_IUSE}"
+IUSE="blas cuda +custom-cflags +doc build-manual double-precision +fftw +gmxapi +gmxapi-legacy +hwloc lapack mkl mpi +offensive opencl openmp +python +single-precision test +threads +tng ${ACCE_IUSE}"
CDEPEND="
- X? (
- x11-libs/libX11
- x11-libs/libSM
- x11-libs/libICE
- )
blas? ( virtual/blas )
cuda? ( >=dev-util/nvidia-cuda-toolkit-6.5.14[profiler] )
opencl? ( virtual/opencl )
- fftw? ( sci-libs/fftw:3.0 )
+ fftw? ( sci-libs/fftw:3.0= )
hwloc? ( sys-apps/hwloc:= )
lapack? ( virtual/lapack )
- lmfit? ( sci-libs/lmfit )
mkl? ( sci-libs/mkl )
- mpi? ( virtual/mpi )
+ mpi? ( virtual/mpi[cxx] )
+ sci-libs/lmfit:=
+ >=dev-cpp/muParser-2.3:=
${PYTHON_DEPS}
!sci-chemistry/gmxapi
"
@@ -70,7 +66,8 @@ BDEPEND="${CDEPEND}
dev-texlive/texlive-latexextra
media-gfx/imagemagick
)"
-RDEPEND="${CDEPEND}"
+RDEPEND="${CDEPEND}
+ <sci-chemistry/dssp-4"
REQUIRED_USE="
|| ( single-precision double-precision )
@@ -203,16 +200,11 @@ src_configure() {
fft_opts=( -DGMX_FFT_LIBRARY=fftpack )
fi
- if use lmfit; then
- local lmfit_opts=( -DGMX_USE_LMFIT=EXTERNAL )
- else
- local lmfit_opts=( -DGMX_USE_LMFIT=INTERNAL )
- fi
-
mycmakeargs_pre+=(
"${fft_opts[@]}"
"${lmfit_opts[@]}"
- -DGMX_X11=$(usex X)
+ -DGMX_USE_LMFIT=EXTERNAL
+ -DGMX_USE_MUPARSER=EXTERNAL
-DGMX_EXTERNAL_BLAS=$(usex blas)
-DGMX_EXTERNAL_LAPACK=$(usex lapack)
-DGMX_OPENMP=$(usex openmp)
@@ -223,6 +215,7 @@ src_configure() {
-DGMX_DEFAULT_SUFFIX=off
-DGMX_SIMD="$acce"
-DGMX_VMD_PLUGIN_PATH="${EPREFIX}/usr/$(get_libdir)/vmd/plugins/*/molfile/"
+ -DGMX_DSSP_PROGRAM_PATH="${EPREFIX}/usr/bin/dssp"
-DBUILD_TESTING=$(usex test)
-DGMX_BUILD_UNITTESTS=$(usex test)
-DPYTHON_EXECUTABLE="${EPREFIX}/usr/bin/${EPYTHON}"
diff --git a/sci-chemistry/mdtraj/Manifest b/sci-chemistry/mdtraj/Manifest
index 369fb48765a..353f6958a59 100644
--- a/sci-chemistry/mdtraj/Manifest
+++ b/sci-chemistry/mdtraj/Manifest
@@ -1 +1,2 @@
DIST mdtraj-1.9.4.tar.gz 2133297 BLAKE2B c1507246bf0c8d7f6753f3d505f940e6f2f001361e42f10c9775647a7e6b58edf2d3953a8e48932f6bf9ad90b27e1baf30df6a7c1a590e49a860175822a25360 SHA512 55f67546db20ce63da3af2231df459e9983e15a65da960784613f746dcce820fe6b0deffbb21b528e93fc6cf674dc7a25ee11110894d2a89e5504e20d200ca38
+DIST mdtraj-1.9.7.tar.gz 2087085 BLAKE2B 430b42eddee0be8beba47994efd16515727970ac7acb36007c9b153cdb474551e5ea228f78a194fa9672d5b169753a9db3c090412bf749b3f1e9323bad9f52de SHA512 5dc9d474909a160e0b1d7989325e8190d1c593087f0130854094eb9c49bc00fd631ea19142d396d49aa7a3dadddaf535b5e811f7574ffff36f0cd22f14691067
diff --git a/sci-chemistry/mdtraj/mdtraj-1.9.7.ebuild b/sci-chemistry/mdtraj/mdtraj-1.9.7.ebuild
new file mode 100644
index 00000000000..0dcd8ceb970
--- /dev/null
+++ b/sci-chemistry/mdtraj/mdtraj-1.9.7.ebuild
@@ -0,0 +1,42 @@
+# Copyright 1999-2021 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+PYTHON_COMPAT=( python3_{8..10} )
+
+inherit distutils-r1
+
+DESCRIPTION="Read, write and analyze MD trajectories with only a few lines of Python code"
+HOMEPAGE="http://mdtraj.org"
+SRC_URI="mirror://pypi/${PN:0:1}/${PN}/${P}.tar.gz"
+
+SLOT="0"
+LICENSE="GPL-2"
+KEYWORDS="~amd64 ~x86 ~amd64-linux ~x86-linux"
+
+RDEPEND="
+ dev-python/astunparse[${PYTHON_USEDEP}]
+ dev-python/astor[${PYTHON_USEDEP}]
+ dev-python/numpy[${PYTHON_USEDEP}]
+ dev-python/pandas[${PYTHON_USEDEP}]
+ dev-python/pytables[${PYTHON_USEDEP}]
+ dev-python/pyparsing[${PYTHON_USEDEP}]
+ dev-python/networkx[${PYTHON_USEDEP}]
+ dev-python/scipy[${PYTHON_USEDEP}]
+"
+DEPEND="${RDEPEND}
+ test? (
+ dev-python/ipykernel[${PYTHON_USEDEP}]
+ dev-python/jupyter_client[${PYTHON_USEDEP}]
+ dev-python/nbformat[${PYTHON_USEDEP}]
+ sci-libs/scikit-learn[${PYTHON_USEDEP}]
+ )
+"
+
+distutils_enable_tests --install pytest
+
+python_prepare_all() {
+ sed -e "s:re.match('build.*(mdtraj.*)', output_dir).group(1):'.':g" \
+ -i basesetup.py || die
+ distutils-r1_python_prepare_all
+}
diff --git a/sci-chemistry/moldy/moldy-2.16e-r2.ebuild b/sci-chemistry/moldy/moldy-2.16e-r2.ebuild
index 81b2d5bf314..2d49fa32d42 100644
--- a/sci-chemistry/moldy/moldy-2.16e-r2.ebuild
+++ b/sci-chemistry/moldy/moldy-2.16e-r2.ebuild
@@ -1,4 +1,4 @@
-# Copyright 1999-2020 Gentoo Authors
+# Copyright 1999-2021 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
@@ -11,7 +11,7 @@ SRC_URI="ftp://ftp.earth.ox.ac.uk/pub/keith/${P}.tar.gz"
LICENSE="GPL-2"
SLOT="0"
-KEYWORDS="amd64 ppc x86 ~amd64-linux ~x86-linux ~ppc-macos"
+KEYWORDS="amd64 ~ppc x86 ~amd64-linux ~x86-linux ~ppc-macos"
IUSE="doc"
BDEPEND="doc? ( virtual/latex-base )"
diff --git a/sci-chemistry/molmol/molmol-2k_p2-r5.ebuild b/sci-chemistry/molmol/molmol-2k_p2-r5.ebuild
index 074130cf13d..5d2719c05a3 100644
--- a/sci-chemistry/molmol/molmol-2k_p2-r5.ebuild
+++ b/sci-chemistry/molmol/molmol-2k_p2-r5.ebuild
@@ -1,4 +1,4 @@
-# Copyright 1999-2019 Gentoo Authors
+# Copyright 1999-2021 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
@@ -24,7 +24,7 @@ SRC_URI="
LICENSE="molmol"
SLOT="0"
-KEYWORDS="amd64 ppc x86 ~amd64-linux ~x86-linux"
+KEYWORDS="amd64 ~ppc x86 ~amd64-linux ~x86-linux"
IUSE=""
RDEPEND="
diff --git a/sci-chemistry/molscript/molscript-2.1.2-r2.ebuild b/sci-chemistry/molscript/molscript-2.1.2-r2.ebuild
index 7196e6fbf7f..eb714581787 100644
--- a/sci-chemistry/molscript/molscript-2.1.2-r2.ebuild
+++ b/sci-chemistry/molscript/molscript-2.1.2-r2.ebuild
@@ -11,7 +11,7 @@ SRC_URI="${P}.tar.gz"
LICENSE="glut molscript"
SLOT="0"
-KEYWORDS="amd64 ppc x86 ~amd64-linux ~x86-linux"
+KEYWORDS="amd64 ~ppc x86 ~amd64-linux ~x86-linux"
IUSE=""
DEPEND="
diff --git a/sci-chemistry/mopac7/mopac7-1.15-r1.ebuild b/sci-chemistry/mopac7/mopac7-1.15-r1.ebuild
index aaf87bceee5..972a4304361 100644
--- a/sci-chemistry/mopac7/mopac7-1.15-r1.ebuild
+++ b/sci-chemistry/mopac7/mopac7-1.15-r1.ebuild
@@ -14,7 +14,7 @@ SRC_URI="
LICENSE="public-domain"
SLOT="0"
-KEYWORDS="amd64 ppc x86 ~amd64-linux"
+KEYWORDS="amd64 ~ppc x86 ~amd64-linux"
IUSE="gmxmopac7"
DEPEND="dev-libs/libf2c"
diff --git a/sci-chemistry/openbabel/Manifest b/sci-chemistry/openbabel/Manifest
index b22751d4a86..11fe53f8f9d 100644
--- a/sci-chemistry/openbabel/Manifest
+++ b/sci-chemistry/openbabel/Manifest
@@ -1,2 +1,4 @@
DIST openbabel-2.4.1.tar.gz 11618304 BLAKE2B 8fc051e83add9be6456e281a109bd6bbec282a64ffc83309819f0decbf167b4914fbb7f1966e95e103f268754045b804317f51c79a952ace707c6af2bd320125 SHA512 427e678f0a911bd27b9a8a05e60b6e09f113be4e5dd180daaf80c28d06368e52b57501261755ab3817a8d31f2754db24471fd0ceee706d029386d6f70800e9c6
+DIST openbabel-3.1.1_p20210225.tar.gz 36674527 BLAKE2B bb82fc96f704249d211bd86c73de0cf4e7cfe5e2ba5c745aa8b4f6f19583837e2181d85101377810095f6b71fc3b91bf2f6f5636726fc8271c6905f1f8c59e7b SHA512 9ff7cb4acbfad7a9c5c8d0dd8930ac0390d0d0f2758d1a6120009071f47ffe718f92ad620d37f26f196babb14649c52b5eb7bb161c342ef36aec655e0a172de4
+DIST openbabel.jpg 12159 BLAKE2B b701df2b8c29df607dc2bd3997a282aa9a726d56c789ff2db900d33234dc691f76b6af12a4c9ccda4f09984504b863c40c39e8bf91058939996714ede2dd37c7 SHA512 998ea526c8c92f87dd203527fdd9f4e001357e951409209f41ab68e0b730fe12d97f9079c12ca289be413854ea2abcf8bb691ae5af823a6f29d6a590e1a3e2b0
DIST openbabel.png 29060 BLAKE2B 8d217d92125cc73462437411dd4e0cc05179cb0934f5ed15a307acc6b549b8ebab250a48a05ef7657f48c6df394f37da9b659de61efb1477b79b573a5b393ad3 SHA512 bbcaaa37663b526c9038ccb9edaf05ccc3ad1a861739a737f05f363098d8402a10b36e341fcc0aca636e809c6c32db99bf987b41719a0c756bf5e31444d3eb70
diff --git a/sci-chemistry/openbabel/files/openbabel-2.3.2-gcc-6_and_7-backport.patch b/sci-chemistry/openbabel/files/openbabel-2.3.2-gcc-6_and_7-backport.patch
deleted file mode 100644
index e23dc6020ee..00000000000
--- a/sci-chemistry/openbabel/files/openbabel-2.3.2-gcc-6_and_7-backport.patch
+++ /dev/null
@@ -1,13 +0,0 @@
-diff --git a/CMakeLists.txt b/CMakeLists.txt
-index 0ee545cf..7f4b944e 100755
---- a/CMakeLists.txt
-+++ b/CMakeLists.txt
-@@ -239,7 +239,7 @@ check_type_size(clock_t CLOCK_T)
- # Get the GCC version - from KDE4 cmake files
- if(CMAKE_COMPILER_IS_GNUCXX)
- exec_program(${CMAKE_C_COMPILER} ARGS --version OUTPUT_VARIABLE _gcc_version_info)
-- string(REGEX MATCH "[345]\\.[0-9]\\.[0-9]" _gcc_version "${_gcc_version_info}")
-+ string(REGEX MATCH "[34567]\\.[0-9]\\.[0-9]" _gcc_version "${_gcc_version_info}")
- # gcc on mac just reports: "gcc (GCC) 3.3 20030304 ..." without the
- # patch level, handle this here:
- if (NOT _gcc_version)
diff --git a/sci-chemistry/openbabel/files/openbabel-2.4.1-gcc-8.patch b/sci-chemistry/openbabel/files/openbabel-2.4.1-gcc-8.patch
deleted file mode 100644
index a4aa3947f2e..00000000000
--- a/sci-chemistry/openbabel/files/openbabel-2.4.1-gcc-8.patch
+++ /dev/null
@@ -1,15 +0,0 @@
-https://bugs.gentoo.org/654800
-Fixed-by: milan hodoscek
-diff --git a/../old/CMakeLists.txt b/CMakeLists.txt
-index dc38d1b..801207e 100644
---- a/../old/CMakeLists.txt
-+++ b/CMakeLists.txt
-@@ -239,7 +239,7 @@ check_type_size(clock_t CLOCK_T)
- # Get the GCC version - from KDE4 cmake files
- if(CMAKE_COMPILER_IS_GNUCXX)
- exec_program(${CMAKE_C_COMPILER} ARGS --version OUTPUT_VARIABLE _gcc_version_info)
-- string(REGEX MATCH "[34567]\\.[0-9]\\.[0-9]" _gcc_version "${_gcc_version_info}")
-+ string(REGEX MATCH "[3456789]\\.[0-9]\\.[0-9]" _gcc_version "${_gcc_version_info}")
- # gcc on mac just reports: "gcc (GCC) 3.3 20030304 ..." without the
- # patch level, handle this here:
- if (NOT _gcc_version)
diff --git a/sci-chemistry/openbabel/files/openbabel-python.cmake b/sci-chemistry/openbabel/files/openbabel-python.cmake
new file mode 100644
index 00000000000..425b4656a9d
--- /dev/null
+++ b/sci-chemistry/openbabel/files/openbabel-python.cmake
@@ -0,0 +1,104 @@
+# The following is a cmake fragment taken from scripts/CMakeLists.txt and
+# edited for Gentoo python multibuild compatibility.
+
+if (PYTHON_BINDINGS)
+ # Tags should be edited to reflect the active python implementation
+ set(EPYTHON @@EPYTHON@@)
+ set(PYTHON_INCUDE_DIR @@PYTHON_INCUDE_DIR@@)
+ set(PYTHON_LIBS @@PYTHON_LIBS@@)
+ set(PYTHON_SITEDIR @@PYTHON_SITEDIR@@)
+
+ include_directories(${PYTHON_INCUDE_DIR})
+
+ add_custom_command(
+ OUTPUT ${CMAKE_SOURCE_DIR}/scripts/${EPYTHON}/openbabel-python.cpp ${CMAKE_SOURCE_DIR}/scripts/${EPYTHON}/openbabel.py
+ COMMAND ${SWIG_EXECUTABLE} -python -c++ -small -O -templatereduce -naturalvar -I${CMAKE_SOURCE_DIR}/include -I${CMAKE_BINARY_DIR}/include -o ${CMAKE_SOURCE_DIR}/scripts/${EPYTHON}/openbabel-python.cpp ${eigen_define} -outdir ${CMAKE_SOURCE_DIR}/scripts/${EPYTHON} ${CMAKE_SOURCE_DIR}/scripts/openbabel-python.i
+ MAIN_DEPENDENCY openbabel-python.i
+ VERBATIM
+ )
+
+ configure_file(${CMAKE_SOURCE_DIR}/scripts/python/openbabel/__init__.py.in
+ ${CMAKE_BINARY_DIR}/scripts/${EPYTHON}/openbabel/__init__.py)
+
+ add_library(bindings_python_${EPYTHON} MODULE ${CMAKE_SOURCE_DIR}/scripts/${EPYTHON}/openbabel-python.cpp)
+ target_link_libraries(bindings_python_${EPYTHON} ${PYTHON_LIBS} ${BABEL_LIBRARY})
+
+ set_target_properties(bindings_python_${EPYTHON}
+ PROPERTIES
+ OUTPUT_NAME _openbabel
+ LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/scripts/${EPYTHON}/openbabel
+ PREFIX ""
+ SUFFIX .so )
+
+ add_dependencies(bindings_python_${EPYTHON} openbabel)
+
+ install(TARGETS bindings_python_${EPYTHON}
+ LIBRARY DESTINATION ${PYTHON_SITEDIR}/openbabel
+ COMPONENT bindings_python)
+ install(FILES ${CMAKE_BINARY_DIR}/scripts/${EPYTHON}/openbabel/__init__.py
+ DESTINATION ${PYTHON_SITEDIR}/openbabel
+ COMPONENT bindings_python)
+ install(FILES ${CMAKE_SOURCE_DIR}/scripts/${EPYTHON}/openbabel.py
+ DESTINATION ${PYTHON_SITEDIR}/openbabel
+ COMPONENT bindings_python)
+ install(FILES ${CMAKE_SOURCE_DIR}/scripts/python/openbabel/pybel.py
+ DESTINATION ${PYTHON_SITEDIR}/openbabel
+ COMPONENT bindings_python)
+
+ if (ENABLE_TESTS)
+ # Make sure all module files are together in the same directory for testing
+ add_custom_command(TARGET bindings_python_${EPYTHON} POST_BUILD
+ COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_SOURCE_DIR}/scripts/${EPYTHON}/openbabel.py ${CMAKE_BINARY_DIR}/scripts/${EPYTHON}/openbabel/
+ COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_SOURCE_DIR}/scripts/python/openbabel/pybel.py ${CMAKE_BINARY_DIR}/scripts/${EPYTHON}/openbabel/)
+ set(TEST_SOURCE_DIR ${CMAKE_SOURCE_DIR}/test)
+ # define TESTDATADIR for tests that need input files
+ add_definitions(-DTESTDATADIR="${TEST_SOURCE_DIR}/files/")
+ # define FORMATDIR for location of format plugin binaries
+ set(FORMATDIR "${CMAKE_BINARY_DIR}/lib${LIB_SUFFIX}/")
+ add_definitions(-DFORMATDIR="${FORMATDIR}/")
+ include_directories(${TEST_SOURCE_DIR})
+
+ # The macro is modified from cmake/modules/UsePythonTest.cmake
+ MACRO(ADD_PYTHON_TEST TESTNAME FILENAME)
+ GET_SOURCE_FILE_PROPERTY(loc ${FILENAME} LOCATION)
+ STRING(REGEX REPLACE ";" " " wo_semicolumn "${ARGN}")
+ FILE(WRITE ${CMAKE_BINARY_DIR}/test/${TESTNAME}.cmake
+"
+ MESSAGE(\"${PYTHONPATH}\")
+ EXECUTE_PROCESS(
+ COMMAND ${EPYTHON} ${loc} ${wo_semicolumn}
+ RESULT_VARIABLE import_res
+ OUTPUT_VARIABLE import_output
+ ERROR_VARIABLE import_output
+ )
+
+ # Pass the output back to ctest
+ IF(import_output)
+ MESSAGE(\${import_output})
+ ENDIF(import_output)
+ IF(import_res)
+ MESSAGE(SEND_ERROR \${import_res})
+ ENDIF(import_res)
+"
+ )
+ ADD_TEST(${TESTNAME} ${CMAKE_COMMAND} -P ${CMAKE_BINARY_DIR}/test/${TESTNAME}.cmake)
+ ENDMACRO(ADD_PYTHON_TEST)
+
+ set(pybindtests
+ bindings
+ _pybel
+ example
+ obconv_writers
+ cdjsonformat
+ pcjsonformat
+ roundtrip
+ )
+ foreach(pybindtest ${pybindtests})
+ ADD_PYTHON_TEST(pybindtest_${pybindtest}_${EPYTHON} ${TEST_SOURCE_DIR}/test${pybindtest}.py)
+ set_tests_properties(pybindtest_${pybindtest}_${EPYTHON} PROPERTIES
+ ENVIRONMENT "PYTHONPATH=${CMAKE_BINARY_DIR}/scripts/${EPYTHON}:${CMAKE_BINARY_DIR}/lib${LIB_SUFFIX};LD_LIBRARY_PATH=${CMAKE_BINARY_DIR}/scripts/${EPYTHON}:${CMAKE_BINARY_DIR}/lib${LIB_SUFFIX}:\$ENV{LD_LIBRARY_PATH};BABEL_LIBDIR=${CMAKE_BINARY_DIR}/lib${LIB_SUFFIX}/;BABEL_DATADIR=${CMAKE_SOURCE_DIR}/data"
+ FAIL_REGULAR_EXPRESSION "ERROR;FAIL;Test failed"
+ )
+ endforeach(pybindtest ${pybindtests})
+ endif (ENABLE_TESTS)
+endif(PYTHON_BINDINGS)
diff --git a/sci-chemistry/openbabel/metadata.xml b/sci-chemistry/openbabel/metadata.xml
index 88ffa5eb106..f31c73d435a 100644
--- a/sci-chemistry/openbabel/metadata.xml
+++ b/sci-chemistry/openbabel/metadata.xml
@@ -14,4 +14,8 @@
<upstream>
<remote-id type="sourceforge">openbabel</remote-id>
</upstream>
+ <use>
+ <flag name="inchi">Build support for IUPAC International Chemical Identifier format</flag>
+ <flag name="json">Build support for JSON formats (ChemDoodle, PubChem, etc...)</flag>
+ </use>
</pkgmetadata>
diff --git a/sci-chemistry/openbabel/openbabel-2.4.1-r1.ebuild b/sci-chemistry/openbabel/openbabel-2.4.1-r1.ebuild
deleted file mode 100644
index db8203212fa..00000000000
--- a/sci-chemistry/openbabel/openbabel-2.4.1-r1.ebuild
+++ /dev/null
@@ -1,102 +0,0 @@
-# Copyright 1999-2020 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=7
-WX_GTK_VER="3.0"
-
-inherit cmake-utils desktop optfeature toolchain-funcs wxwidgets
-
-DESCRIPTION="Interconverts file formats used in molecular modeling"
-HOMEPAGE="http://openbabel.org/wiki/Main_Page"
-SRC_URI="
- mirror://sourceforge/openbabel/${P}.tar.gz
- https://openbabel.org/docs/dev/_static/babel130.png -> ${PN}.png
-"
-
-# See src/CMakeLists.txt for LIBRARY_VERSION
-SLOT="0/5.0.0"
-LICENSE="GPL-2"
-KEYWORDS="amd64 ~arm x86 ~amd64-linux ~x86-linux ~ppc-macos"
-IUSE="doc openmp test wxwidgets"
-RESTRICT="!test? ( test )"
-
-RDEPEND="
- dev-cpp/eigen:3
- dev-libs/libxml2:2
- sci-libs/inchi
- sys-libs/zlib
- wxwidgets? ( x11-libs/wxGTK:${WX_GTK_VER}[X] )
-"
-DEPEND="${RDEPEND}"
-BDEPEND="
- >=dev-util/cmake-2.4.8
- doc? ( app-doc/doxygen )
-"
-
-DOCS=( AUTHORS NEWS.md README.md THANKS doc/dioxin.{inc,mol2} doc/README.{dioxin.pov,povray} )
-
-PATCHES=(
- "${FILESDIR}"/${PN}-2.3.2-gcc-6_and_7-backport.patch
- "${FILESDIR}"/${P}-gcc-8.patch
-)
-
-pkg_setup() {
- if use openmp; then
- if [[ $(tc-getCC) == *gcc ]] && ! tc-has-openmp; then
- ewarn "OpenMP is not available in your current selected gcc"
- die "need openmp capable gcc"
- fi
- FORTRAN_NEED_OPENMP=1
- fi
-}
-
-src_prepare() {
- sed \
- -e '/__GNUC__/s:== 4:>= 4:g' \
- -i include/openbabel/shared_ptr.h || die
- cmake-utils_src_prepare
-}
-
-src_configure() {
- use wxwidgets && setup-wxwidgets
- local mycmakeargs=(
- -DOPENBABEL_USE_SYSTEM_INCHI=ON
- -DENABLE_OPENMP=$(usex openmp)
- -DBUILD_GUI=$(usex wxwidgets)
- )
-
- cmake-utils_src_configure
-}
-
-src_install() {
- docinto html
- dodoc doc/{*.html,*.png}
- if use doc ; then
- docinto html/API
- dodoc -r doc/API/html/*
- fi
-
- make_desktop_entry obgui "Open Babel" "${PN}"
- doicon "${DISTDIR}/${PN}.png"
-
- cmake-utils_src_install
-}
-
-src_test() {
- local mycmakeargs=(
- -DOPENBABEL_USE_SYSTEM_INCHI=ON
- -DPYTHON_EXECUTABLE=false
- -DOPENMP=$(usex openmp)
- -DBUILD_GUI=$(usex wxwidgets)
- -DTESTS=$(usex test)
- )
-
- cmake-utils_src_configure
- cmake-utils_src_compile
- cmake-utils_src_test -E py
-}
-
-pkg_postinst() {
- optfeature "perl support" sci-chemistry/openbabel-perl
- optfeature "python support" sci-chemistry/openbabel-python
-}
diff --git a/sci-chemistry/openbabel/openbabel-3.1.1_p20210225.ebuild b/sci-chemistry/openbabel/openbabel-3.1.1_p20210225.ebuild
new file mode 100644
index 00000000000..67ac61c1741
--- /dev/null
+++ b/sci-chemistry/openbabel/openbabel-3.1.1_p20210225.ebuild
@@ -0,0 +1,272 @@
+# Copyright 1999-2021 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+PYTHON_COMPAT=( python3_{8..10} )
+WX_GTK_VER=3.0-gtk3
+
+inherit cmake desktop flag-o-matic perl-functions python-r1 toolchain-funcs wxwidgets xdg-utils
+
+DESCRIPTION="Interconverts file formats used in molecular modeling"
+HOMEPAGE="https://openbabel.org/"
+
+if [[ "${PV}" == *9999* ]]; then
+ inherit git-r3
+ EGIT_REPO_URI="https://github.com/openbabel/${PN}.git"
+else
+ if [[ "${PV}" == *_p* ]]; then # eg., openbabel-3.1.1_p20210325
+ # Set to commit hash
+ OPENBABEL_COMMIT=08e23f39b0cc39b4eebd937a5a2ffc1a7bac3e1b
+ SRC_URI="https://github.com/${PN}/${PN}/archive/${OPENBABEL_COMMIT}.tar.gz -> ${P}.tar.gz"
+ S="${WORKDIR}/${PN}-${OPENBABEL_COMMIT}"
+ else
+ MY_P="${PN}-$(ver_rs 1- -)"
+ SRC_URI="https://github.com/${PN}/${PN}/archive/${MY_P}.tar.gz -> ${P}.tar.gz"
+ S="${WORKDIR}/${PN}-${MY_P}"
+ fi
+ KEYWORDS="~amd64 ~arm ~x86 ~amd64-linux ~x86-linux ~ppc-macos"
+fi
+
+SRC_URI="${SRC_URI}
+ https://openbabel.org/docs/dev/_static/babel130.png -> ${PN}.png
+ http://openbabel.org/OBTitle.jpg -> ${PN}.jpg"
+
+# See src/CMakeLists.txt for LIBRARY_VERSION
+SLOT="0/7.0.0"
+LICENSE="GPL-2"
+IUSE="cpu_flags_arm_neon cpu_flags_x86_sse2 cpu_flags_x86_sse4_2 doc examples +inchi json minimal openmp perl png python test wxwidgets"
+
+RESTRICT="!test? ( test )"
+
+# Inaccurate dependency logic upstream
+REQUIRED_USE="
+ python? ( ${PYTHON_REQUIRED_USE} )
+ test? ( inchi json !minimal wxwidgets )
+"
+
+BDEPEND="
+ dev-lang/perl
+ doc? (
+ app-doc/doxygen
+ dev-texlive/texlive-latex
+ )
+ perl? ( >=dev-lang/swig-2 )
+ python? ( >=dev-lang/swig-2 )
+ test? ( dev-lang/python )
+"
+
+COMMON_DEPEND="
+ dev-cpp/eigen:3
+ dev-libs/libxml2:2
+ sys-libs/zlib:=
+ inchi? ( sci-libs/inchi )
+ json? ( >=dev-libs/rapidjson-1.1.0 )
+ png? ( x11-libs/cairo )
+ python? ( ${PYTHON_DEPS} )
+ wxwidgets? ( x11-libs/wxGTK:${WX_GTK_VER}[X] )
+"
+
+DEPEND="
+ ${COMMON_DEPEND}
+ perl? ( dev-lang/perl )
+"
+
+RDEPEND="
+ ${COMMON_DEPEND}
+ perl? (
+ dev-lang/perl:=
+ !sci-chemistry/openbabel-perl
+ )
+"
+
+pkg_setup() {
+ use openmp && tc-check-openmp
+}
+
+prepare_python_bindings() {
+ mkdir -p scripts/${EPYTHON} || die
+ # Appends to scripts/CMakeLists.txt, substituting the correct tags, for
+ # each valid python implementation,
+ cat "${FILESDIR}"/${PN}-python.cmake | \
+ sed -e "s|@@EPYTHON@@|${EPYTHON}|" \
+ -e "s|@@PYTHON_INCUDE_DIR@@|$(python_get_includedir)|" \
+ -e "s|@@PYTHON_LIBS@@|$(python_get_LIBS)|" \
+ -e "s|@@PYTHON_SITEDIR@@|$(python_get_sitedir)|" >> \
+ scripts/CMakeLists.txt || die
+}
+
+src_prepare() {
+ cmake_src_prepare
+
+ if use perl; then
+ perl_set_version
+
+ sed -e "/\${LIB_INSTALL_DIR}\/auto/s|\${LIB_INSTALL_DIR}|${VENDOR_ARCH}|" \
+ -e "/\${LIB_INSTALL_DIR}\/Chemistry/s|\${LIB_INSTALL_DIR}|${VENDOR_ARCH}|" \
+ -i scripts/CMakeLists.txt || die
+ fi
+
+ if use python; then
+ # Skip the python bindings sections as we'll append our own
+ sed -e '/^if (PYTHON_BINDINGS)$/s|PYTHON_BINDINGS|false|' \
+ -i {scripts,test}/CMakeLists.txt || die
+ if use test; then
+ # Problems with testbindings built with -O2
+ local test_skip="@unittest.skip('Similar to Issue #2138')"
+ sed -e "/def testTemplates/s|^| ${test_skip}\\n|" \
+ -i test/testbindings.py || die
+ test_skip="@unittest.skip('Similar to Issue #2246')"
+ sed -e "/^def test_write_string/s|^|${test_skip}\\n|" \
+ -i test/testobconv_writers.py || die
+ fi
+ python_foreach_impl prepare_python_bindings
+ fi
+
+ # Remove dependency automagic
+ if ! use png; then
+ sed -e '/^find_package(Cairo/d' -i CMakeLists.txt || die
+ fi
+ if ! use wxwidgets; then
+ sed -e '/^find_package(wxWidgets/d' -i CMakeLists.txt || die
+ fi
+ if ! use inchi; then
+ sed -e '/^else()$/s|else\(\)|elseif\(false\)|' \
+ -i cmake/modules/FindInchi.cmake || die
+ fi
+
+ # Don't install example bins to /usr/bin
+ if use examples; then
+ sed -e "/RUNTIME DESTINATION/s|bin|share/doc/${PF}/examples|" \
+ -i doc/examples/CMakeLists.txt || die
+ fi
+
+ # boost is only used if building with gcc-3.x, which isn't supported in
+ # Gentoo. Still, it shouldn't look for, and include, its headers
+ sed -e '/find_package(Boost/d' -i {{tools,src}/,}CMakeLists.txt || die
+}
+
+src_configure() {
+ if use json; then
+ # -DOPTIMIZE_NATIVE=ON also forces -march=native so use
+ # cpu_flags to set defines instead
+ use cpu_flags_x86_sse2 && append-cppflags -DRAPIDJSON_SSE2
+ use cpu_flags_x86_sse4_2 && append-cppflags -DRAPIDJSON_SSE42
+ use cpu_flags_arm_neon && append-cppflags -DRAPIDJSON_NEON
+ fi
+
+ use wxwidgets && setup-wxwidgets
+
+ use_bindings() {
+ (use perl || use python) && (echo 'yes' || die) || (echo 'no' || die)
+ }
+
+ local mycmakeargs=(
+ -DBUILD_DOCS=$(usex doc)
+ -DBUILD_EXAMPLES=$(usex examples)
+ -DBUILD_GUI=$(usex wxwidgets)
+ -DENABLE_OPENMP=$(usex openmp)
+ -DENABLE_TESTS=$(usex test)
+ -DMINIMAL_BUILD=$(usex minimal)
+ # Set this, otherwise it defaults to true and forces WITH_INCHI=true
+ -DOPENBABEL_USE_SYSTEM_INCHI=$(usex inchi)
+ -DOPTIMIZE_NATIVE=OFF
+ -DPERL_BINDINGS=$(usex perl)
+ -DPYTHON_BINDINGS=$(usex python)
+ -DRUN_SWIG=$(use_bindings)
+ -DWITH_COORDGEN=false
+ -DWITH_INCHI=$(usex inchi)
+ -DWITH_JSON=$(usex json)
+ -DWITH_MAEPARSER=false
+ )
+
+ if use test; then
+ # Help cmake find the python interpreter when dev-lang/python-exec is built
+ # without native-symlinks support.
+ python_setup
+ mycmakeargs+=( -DPYTHON_EXECUTABLE="${PYTHON}" )
+ fi
+
+ cmake_src_configure
+}
+
+src_test() {
+ # Wierd deadlock causes system_load to keep rising
+ cmake_src_test -j1
+}
+
+openbabel-optimize() {
+ python_optimize "${D}/$(python_get_sitedir)"/openbabel || die
+}
+
+src_install() {
+ cmake_src_install
+
+ docinto html
+ for x in doc/*.html; do
+ [[ ${x} != doc/api*.html ]] && dodoc ${x}
+ done
+ # Rendered in some html pages
+ newdoc "${DISTDIR}"/${PN}.png babel130.png
+ newdoc "${DISTDIR}"/${PN}.jpg OBTitle.jpg
+
+ if use doc; then
+ cmake_src_install docs
+ docinto html/API
+ dodoc -r doc/API/html/.
+ fi
+
+ if use examples; then
+ # no compression since we want ready-to-run scripts
+ docompress -x /usr/share/doc/${PF}/examples
+
+ # ${PV} doesn't correspond to the internal BABEL_VERSION for
+ # live or patch release builds so we grep it
+ local babel_ver=$(
+ grep '^#define BABEL_VERSION' < \
+ "${BUILD_DIR}"/include/openbabel/babelconfig.h | \
+ cut -d \" -f 2 || die
+ )
+ docinto examples/povray
+ dodoc doc/dioxin.* doc/README*.pov*
+ # Needed by the povray example
+ dosym ../../../../${PN}/${babel_ver}/babel_povray3.inc \
+ /usr/share/doc/${PF}/examples/povray/babel31.inc
+
+ fi
+
+ if use perl; then
+ docinto /
+ newdoc scripts/perl/Changes Changes.perl
+ newdoc scripts/perl/README README.perl
+ if use examples; then
+ docinto examples/perl
+ dodoc -r scripts/perl/examples/.
+ fi
+ fi
+
+ if use python; then
+ python_foreach_impl openbabel-optimize
+ docinto /
+ newdoc scripts/python/README.rst README.python.rst
+ docinto html
+ dodoc scripts/python/*.html
+ if use examples; then
+ docinto examples/python
+ dodoc -r scripts/python/examples/.
+ fi
+ fi
+
+ if use wxwidgets; then
+ make_desktop_entry obgui "Open Babel" ${PN}
+ doicon "${DISTDIR}"/${PN}.png
+ fi
+}
+
+pkg_postinst() {
+ use wxwidgets && xdg_desktop_database_update
+}
+
+pkg_postrm() {
+ use wxwidgets && xdg_desktop_database_update
+}
diff --git a/sci-chemistry/openbabel/openbabel-9999.ebuild b/sci-chemistry/openbabel/openbabel-9999.ebuild
new file mode 100644
index 00000000000..baf793cb651
--- /dev/null
+++ b/sci-chemistry/openbabel/openbabel-9999.ebuild
@@ -0,0 +1,272 @@
+# Copyright 1999-2021 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+PYTHON_COMPAT=( python3_{8..10} )
+WX_GTK_VER=3.0-gtk3
+
+inherit cmake desktop flag-o-matic perl-functions python-r1 toolchain-funcs wxwidgets xdg-utils
+
+DESCRIPTION="Interconverts file formats used in molecular modeling"
+HOMEPAGE="https://openbabel.org/"
+
+if [[ "${PV}" == *9999* ]]; then
+ inherit git-r3
+ EGIT_REPO_URI="https://github.com/openbabel/${PN}.git"
+else
+ if [[ "${PV}" == *_p* ]]; then # eg., openbabel-3.1.1_p20210325
+ # Set to commit hash
+ OPENBABEL_COMMIT=
+ SRC_URI="https://github.com/${PN}/${PN}/archive/${OPENBABEL_COMMIT}.tar.gz -> ${P}.tar.gz"
+ S="${WORKDIR}/${PN}-${OPENBABEL_COMMIT}"
+ else
+ MY_P="${PN}-$(ver_rs 1- -)"
+ SRC_URI="https://github.com/${PN}/${PN}/archive/${MY_P}.tar.gz -> ${P}.tar.gz"
+ S="${WORKDIR}/${PN}-${MY_P}"
+ fi
+ KEYWORDS="~amd64 ~arm ~x86 ~amd64-linux ~x86-linux ~ppc-macos"
+fi
+
+SRC_URI="${SRC_URI}
+ https://openbabel.org/docs/dev/_static/babel130.png -> ${PN}.png
+ http://openbabel.org/OBTitle.jpg -> ${PN}.jpg"
+
+# See src/CMakeLists.txt for LIBRARY_VERSION
+SLOT="0/7.0.0"
+LICENSE="GPL-2"
+IUSE="cpu_flags_arm_neon cpu_flags_x86_sse2 cpu_flags_x86_sse4_2 doc examples +inchi json minimal openmp perl png python test wxwidgets"
+
+RESTRICT="!test? ( test )"
+
+# Inaccurate dependency logic upstream
+REQUIRED_USE="
+ python? ( ${PYTHON_REQUIRED_USE} )
+ test? ( inchi json !minimal wxwidgets )
+"
+
+BDEPEND="
+ dev-lang/perl
+ doc? (
+ app-doc/doxygen
+ dev-texlive/texlive-latex
+ )
+ perl? ( >=dev-lang/swig-2 )
+ python? ( >=dev-lang/swig-2 )
+ test? ( dev-lang/python )
+"
+
+COMMON_DEPEND="
+ dev-cpp/eigen:3
+ dev-libs/libxml2:2
+ sys-libs/zlib:=
+ inchi? ( sci-libs/inchi )
+ json? ( >=dev-libs/rapidjson-1.1.0 )
+ png? ( x11-libs/cairo )
+ python? ( ${PYTHON_DEPS} )
+ wxwidgets? ( x11-libs/wxGTK:${WX_GTK_VER}[X] )
+"
+
+DEPEND="
+ ${COMMON_DEPEND}
+ perl? ( dev-lang/perl )
+"
+
+RDEPEND="
+ ${COMMON_DEPEND}
+ perl? (
+ dev-lang/perl:=
+ !sci-chemistry/openbabel-perl
+ )
+"
+
+pkg_setup() {
+ use openmp && tc-check-openmp
+}
+
+prepare_python_bindings() {
+ mkdir -p scripts/${EPYTHON} || die
+ # Appends to scripts/CMakeLists.txt, substituting the correct tags, for
+ # each valid python implementation,
+ cat "${FILESDIR}"/${PN}-python.cmake | \
+ sed -e "s|@@EPYTHON@@|${EPYTHON}|" \
+ -e "s|@@PYTHON_INCUDE_DIR@@|$(python_get_includedir)|" \
+ -e "s|@@PYTHON_LIBS@@|$(python_get_LIBS)|" \
+ -e "s|@@PYTHON_SITEDIR@@|$(python_get_sitedir)|" >> \
+ scripts/CMakeLists.txt || die
+}
+
+src_prepare() {
+ cmake_src_prepare
+
+ if use perl; then
+ perl_set_version
+
+ sed -e "/\${LIB_INSTALL_DIR}\/auto/s|\${LIB_INSTALL_DIR}|${VENDOR_ARCH}|" \
+ -e "/\${LIB_INSTALL_DIR}\/Chemistry/s|\${LIB_INSTALL_DIR}|${VENDOR_ARCH}|" \
+ -i scripts/CMakeLists.txt || die
+ fi
+
+ if use python; then
+ # Skip the python bindings sections as we'll append our own
+ sed -e '/^if (PYTHON_BINDINGS)$/s|PYTHON_BINDINGS|false|' \
+ -i {scripts,test}/CMakeLists.txt || die
+ if use test; then
+ # Problems with testbindings built with -O2
+ local test_skip="@unittest.skip('Similar to Issue #2138')"
+ sed -e "/def testTemplates/s|^| ${test_skip}\\n|" \
+ -i test/testbindings.py || die
+ test_skip="@unittest.skip('Similar to Issue #2246')"
+ sed -e "/^def test_write_string/s|^|${test_skip}\\n|" \
+ -i test/testobconv_writers.py || die
+ fi
+ python_foreach_impl prepare_python_bindings
+ fi
+
+ # Remove dependency automagic
+ if ! use png; then
+ sed -e '/^find_package(Cairo/d' -i CMakeLists.txt || die
+ fi
+ if ! use wxwidgets; then
+ sed -e '/^find_package(wxWidgets/d' -i CMakeLists.txt || die
+ fi
+ if ! use inchi; then
+ sed -e '/^else()$/s|else\(\)|elseif\(false\)|' \
+ -i cmake/modules/FindInchi.cmake || die
+ fi
+
+ # Don't install example bins to /usr/bin
+ if use examples; then
+ sed -e "/RUNTIME DESTINATION/s|bin|share/doc/${PF}/examples|" \
+ -i doc/examples/CMakeLists.txt || die
+ fi
+
+ # boost is only used if building with gcc-3.x, which isn't supported in
+ # Gentoo. Still, it shouldn't look for, and include, its headers
+ sed -e '/find_package(Boost/d' -i {{tools,src}/,}CMakeLists.txt || die
+}
+
+src_configure() {
+ if use json; then
+ # -DOPTIMIZE_NATIVE=ON also forces -march=native so use
+ # cpu_flags to set defines instead
+ use cpu_flags_x86_sse2 && append-cppflags -DRAPIDJSON_SSE2
+ use cpu_flags_x86_sse4_2 && append-cppflags -DRAPIDJSON_SSE42
+ use cpu_flags_arm_neon && append-cppflags -DRAPIDJSON_NEON
+ fi
+
+ use wxwidgets && setup-wxwidgets
+
+ use_bindings() {
+ (use perl || use python) && (echo 'yes' || die) || (echo 'no' || die)
+ }
+
+ local mycmakeargs=(
+ -DBUILD_DOCS=$(usex doc)
+ -DBUILD_EXAMPLES=$(usex examples)
+ -DBUILD_GUI=$(usex wxwidgets)
+ -DENABLE_OPENMP=$(usex openmp)
+ -DENABLE_TESTS=$(usex test)
+ -DMINIMAL_BUILD=$(usex minimal)
+ # Set this, otherwise it defaults to true and forces WITH_INCHI=true
+ -DOPENBABEL_USE_SYSTEM_INCHI=$(usex inchi)
+ -DOPTIMIZE_NATIVE=OFF
+ -DPERL_BINDINGS=$(usex perl)
+ -DPYTHON_BINDINGS=$(usex python)
+ -DRUN_SWIG=$(use_bindings)
+ -DWITH_COORDGEN=false
+ -DWITH_INCHI=$(usex inchi)
+ -DWITH_JSON=$(usex json)
+ -DWITH_MAEPARSER=false
+ )
+
+ if use test; then
+ # Help cmake find the python interpreter when dev-lang/python-exec is built
+ # without native-symlinks support.
+ python_setup
+ mycmakeargs+=( -DPYTHON_EXECUTABLE="${PYTHON}" )
+ fi
+
+ cmake_src_configure
+}
+
+src_test() {
+ # Wierd deadlock causes system_load to keep rising
+ cmake_src_test -j1
+}
+
+openbabel-optimize() {
+ python_optimize "${D}/$(python_get_sitedir)"/openbabel || die
+}
+
+src_install() {
+ cmake_src_install
+
+ docinto html
+ for x in doc/*.html; do
+ [[ ${x} != doc/api*.html ]] && dodoc ${x}
+ done
+ # Rendered in some html pages
+ newdoc "${DISTDIR}"/${PN}.png babel130.png
+ newdoc "${DISTDIR}"/${PN}.jpg OBTitle.jpg
+
+ if use doc; then
+ cmake_src_install docs
+ docinto html/API
+ dodoc -r doc/API/html/.
+ fi
+
+ if use examples; then
+ # no compression since we want ready-to-run scripts
+ docompress -x /usr/share/doc/${PF}/examples
+
+ # ${PV} doesn't correspond to the internal BABEL_VERSION for
+ # live or patch release builds so we grep it
+ local babel_ver=$(
+ grep '^#define BABEL_VERSION' < \
+ "${BUILD_DIR}"/include/openbabel/babelconfig.h | \
+ cut -d \" -f 2 || die
+ )
+ docinto examples/povray
+ dodoc doc/dioxin.* doc/README*.pov*
+ # Needed by the povray example
+ dosym ../../../../${PN}/${babel_ver}/babel_povray3.inc \
+ /usr/share/doc/${PF}/examples/povray/babel31.inc
+
+ fi
+
+ if use perl; then
+ docinto /
+ newdoc scripts/perl/Changes Changes.perl
+ newdoc scripts/perl/README README.perl
+ if use examples; then
+ docinto examples/perl
+ dodoc -r scripts/perl/examples/.
+ fi
+ fi
+
+ if use python; then
+ python_foreach_impl openbabel-optimize
+ docinto /
+ newdoc scripts/python/README.rst README.python.rst
+ docinto html
+ dodoc scripts/python/*.html
+ if use examples; then
+ docinto examples/python
+ dodoc -r scripts/python/examples/.
+ fi
+ fi
+
+ if use wxwidgets; then
+ make_desktop_entry obgui "Open Babel" ${PN}
+ doicon "${DISTDIR}"/${PN}.png
+ fi
+}
+
+pkg_postinst() {
+ use wxwidgets && xdg_desktop_database_update
+}
+
+pkg_postrm() {
+ use wxwidgets && xdg_desktop_database_update
+}
diff --git a/sci-chemistry/probe/probe-2.13.110909.ebuild b/sci-chemistry/probe/probe-2.13.110909.ebuild
index 53b196426ae..cffb72dff83 100644
--- a/sci-chemistry/probe/probe-2.13.110909.ebuild
+++ b/sci-chemistry/probe/probe-2.13.110909.ebuild
@@ -13,7 +13,7 @@ SRC_URI="http://kinemage.biochem.duke.edu/downloads/software/probe/${MY_P}.src.z
LICENSE="richardson"
SLOT="0"
-KEYWORDS="amd64 ppc x86 ~amd64-linux ~x86-linux ~x64-macos"
+KEYWORDS="amd64 ~ppc x86 ~amd64-linux ~x86-linux ~x64-macos"
BDEPEND="app-arch/unzip"
diff --git a/sci-chemistry/pymol/Manifest b/sci-chemistry/pymol/Manifest
index dec8f0b1525..2c6723b71c2 100644
--- a/sci-chemistry/pymol/Manifest
+++ b/sci-chemistry/pymol/Manifest
@@ -1,3 +1,2 @@
DIST pymol-1.8.4.0.png.xz 19528 BLAKE2B f3d23d4cedca3d8bb96b20646a548da4be570697e3346a11b01c5c3599b536ba4697be08472dfa8a4f6533167defc1a37a1de332931a73857319cb28fd42cd2b SHA512 40bb0d3f226476f6e047b5361956aad955232a97641474765eaa5204f0539aee3810e0266213618a45364f9f31f6eb18380b17e0c79f64065f7b62a9016caa7c
-DIST pymol-2.4.0.tar.gz 10552539 BLAKE2B 34e31dce99c1e838b00389c3d7c29657534dd037349769bd6c8cb17028cfaaa856d5729760d3768fd43f61086cac30749a864fb4156c14eda07f9027430f0523 SHA512 2b19294197d58a808bf7bb7fa9f829c2ec582ba47a4380783a2b1eedda2ce4118cd398e01885db8c449e7fd5e4c08a1c40508e679ef42d8e183a6a52b031c02a
DIST pymol-2.5.0.tar.gz 10470268 BLAKE2B ad3721432001053be93afe755f531ae47348213b042e84dae33cd79580428c9ac3d00629afa0222e4081807dc80e2dd69c3963a457666b5975b6263b988d02d9 SHA512 19f21b8f735fda5314abf202d56f3c81c7251bf6ef0df73ccee534d9c08035f4ef6155ffb68e09d7717a0fb5ba7289bbfa440691bea4cec0de7199c9e858ea91
diff --git a/sci-chemistry/pymol/files/pymol-2.4.0-fix_bug119.patch b/sci-chemistry/pymol/files/pymol-2.4.0-fix_bug119.patch
deleted file mode 100644
index 62512053fd7..00000000000
--- a/sci-chemistry/pymol/files/pymol-2.4.0-fix_bug119.patch
+++ /dev/null
@@ -1,34 +0,0 @@
-From 885891cf60371674406cdff16b395e25cc13d8ae Mon Sep 17 00:00:00 2001
-From: Sebastian Keller <sebastian-keller@gmx.de>
-Date: Tue, 28 Jul 2020 22:50:53 +0200
-Subject: [PATCH] Don't drop the last model when updating the selector table
-
-The last assigned model in the Obj vector was at position modelCnt.
-Resizing the vector to modelCnt removes the last model, which later
-results in a crash when trying to access it.
-
-See https://github.com/schrodinger/pymol-open-source/issues/119
----
- layer3/Selector.cpp | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/layer3/Selector.cpp b/layer3/Selector.cpp
-index 546725b..637cd60 100644
---- a/layer3/Selector.cpp
-+++ b/layer3/Selector.cpp
-@@ -7284,11 +7284,11 @@ static sele_array_t SelectorUpdateTableSingleObject(PyMOLGlobals * G, ObjectMole
- result[obj->SeleBase + at] = tag;
- }
- }
- }
- }
-- I->Obj.resize(modelCnt);
-+ I->Obj.resize(modelCnt + 1);
- I->Table.resize(c);
-
- PRINTFD(G, FB_Selector)
- "SelectorUpdateTableSingleObject-Debug: leaving...\n" ENDFD;
-
---
-libgit2 1.0.1
-
diff --git a/sci-chemistry/pymol/pymol-2.4.0-r1.ebuild b/sci-chemistry/pymol/pymol-2.4.0-r1.ebuild
deleted file mode 100644
index c710896747d..00000000000
--- a/sci-chemistry/pymol/pymol-2.4.0-r1.ebuild
+++ /dev/null
@@ -1,116 +0,0 @@
-# Copyright 1999-2021 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=7
-
-PYTHON_COMPAT=( python3_{7..9} )
-DISTUTILS_USE_SETUPTOOLS=no
-
-inherit desktop optfeature flag-o-matic xdg distutils-r1
-
-DESCRIPTION="A Python-extensible molecular graphics system"
-HOMEPAGE="https://www.pymol.org/"
-SRC_URI="
- https://dev.gentoo.org/~pacho/${PN}/${PN}-1.8.4.0.png.xz
- https://github.com/schrodinger/pymol-open-source/archive/v${PV}.tar.gz -> ${P}.tar.gz
- "
-RESTRICT="mirror"
-LICENSE="PSF-2.2"
-SLOT="0"
-KEYWORDS="~amd64 ~x86 ~amd64-linux ~x86-linux ~x64-macos"
-IUSE="+netcdf web"
-
-DEPEND="
- dev-libs/msgpack[cxx]
- dev-libs/mmtf-cpp
- dev-python/pyopengl[${PYTHON_USEDEP}]
- dev-python/PyQt5[opengl,${PYTHON_USEDEP}]
- dev-python/numpy[${PYTHON_USEDEP}]
- dev-python/pmw[${PYTHON_USEDEP}]
- media-libs/freetype:2
- media-libs/glew:0=
- media-libs/glm
- media-libs/libpng:0=
- media-video/mpeg-tools
- sys-libs/zlib
- netcdf? ( sci-libs/netcdf:0= )
-"
-RDEPEND="${DEPEND}
- sci-chemistry/chemical-mime-data
-"
-
-S="${WORKDIR}"/${PN}-open-source-${PV}
-
-PATCHES=(
- # https://github.com/schrodinger/pymol-open-source/issues/119
- "${FILESDIR}/${P}-fix_bug119.patch"
-)
-
-python_prepare_all() {
- sed \
- -e "s:\"/usr:\"${EPREFIX}/usr:g" \
- -e "/ext_comp_args.*+=/s:\[.*\]$:\[\]:g" \
- -i setup.py || die
-
- sed \
- -e "s:/opt/local:${EPREFIX}/usr:g" \
- -e '/ext_comp_args/s:\[.*\]:[]:g' \
- -i setup.py || die
- sed \
- -e "s:\['msgpackc'\]:\['msgpack'\]:g" \
- -i setup.py || die
-
- append-cxxflags -std=c++0x
-
- use !netcdf && mydistutilsargs=( --no-vmd-plugins )
-
- distutils-r1_python_prepare_all
-}
-
-python_install() {
- distutils-r1_python_install \
- --pymol-path="${EPREFIX}/usr/share/pymol"
-
- sed \
- -e '1d' \
- -e "/APBS_BINARY_LOCATION/s:None:\"${EPREFIX}/usr/bin/apbs\":g" \
- -e "/APBS_PSIZE_LOCATION/s:None:\"$(python_get_sitedir)/pdb2pqr/src/\":g" \
- -e "/APBS_PDB2PQR_LOCATION/s:None:\"$(python_get_sitedir)/pdb2pqr/\":g" \
- -i "${D}/$(python_get_sitedir)"/pmg_tk/startup/apbs_tools.py || die
-}
-
-python_install_all() {
- distutils-r1_python_install_all
-
- sed \
- -e '1i#!/usr/bin/env python' \
- "${D}/$(python_get_sitedir)"/pymol/__init__.py > "${T}"/${PN} || die
-
- python_foreach_impl python_doscript "${T}"/${PN}
-
- # These environment variables should not go in the wrapper script, or else
- # it will be impossible to use the PyMOL libraries from Python.
- cat >> "${T}"/20pymol <<- EOF || die
- PYMOL_PATH="${EPREFIX}/usr/share/pymol"
- PYMOL_DATA="${EPREFIX}/usr/share/pymol/data"
- PYMOL_SCRIPTS="${EPREFIX}/usr/share/pymol/scripts"
- EOF
-
- doenvd "${T}"/20pymol
-
- newicon "${WORKDIR}"/${PN}-1.8.4.0.png ${PN}.png
- make_desktop_entry ${PN} PyMol ${PN} \
- "Graphics;Education;Science;Chemistry;" \
- "MimeType=chemical/x-pdb;chemical/x-mdl-molfile;chemical/x-mol2;chemical/seq-aa-fasta;chemical/seq-na-fasta;chemical/x-xyz;chemical/x-mdl-sdf;"
-
- if ! use web; then
- rm -rf "${D}/$(python_get_sitedir)/web" || die
- fi
-
- rm -f "${ED}"/usr/share/${PN}/LICENSE || die
-}
-
-pkg_postinst() {
- xdg_pkg_postinst
- optfeature "Electrostatic calculations" sci-chemistry/apbs sci-chemistry/pdb2pqr
-}
diff --git a/sci-chemistry/tm-align/tm-align-20150914.ebuild b/sci-chemistry/tm-align/tm-align-20150914.ebuild
index 26eb0fd6597..54a8bacf58f 100644
--- a/sci-chemistry/tm-align/tm-align-20150914.ebuild
+++ b/sci-chemistry/tm-align/tm-align-20150914.ebuild
@@ -1,4 +1,4 @@
-# Copyright 1999-2018 Gentoo Authors
+# Copyright 1999-2021 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=6
@@ -11,7 +11,7 @@ SRC_URI="http://zhanglab.ccmb.med.umich.edu/TM-align/TMtools${PV}.tar.gz"
LICENSE="tm-align"
SLOT="0"
-KEYWORDS="amd64 ppc ppc64 x86 ~amd64-linux ~x86-linux"
+KEYWORDS="amd64 ~ppc ppc64 x86 ~amd64-linux ~x86-linux"
IUSE="custom-cflags static"
S="${WORKDIR}"
diff --git a/sci-chemistry/vmd/Manifest b/sci-chemistry/vmd/Manifest
index dbb4249c928..584d38bd84a 100644
--- a/sci-chemistry/vmd/Manifest
+++ b/sci-chemistry/vmd/Manifest
@@ -1,2 +1,3 @@
DIST vmd-1.9.4_alpha51-gentoo-patches.tar.xz 14604 BLAKE2B f8621956785d365cc056ba53373120d8f99da1476ab9789af6bb8ef00b8dd8c2a4c3599d75e13eba2fc5630b291aed966ce64f7f408504b079e3e994e45da243 SHA512 c57fd81e667e405ab1208a4e4a1d63710e593c07f554420c32980becd3547c2df98fbf6e439a53a626121fc361559f1ba53ab7b7235c97422bba61ece59d23bc
DIST vmd-1.9.4a51.src.tar.gz 42826371 BLAKE2B 239d87f975c41a71096083028c1db8bf40cc058fc687fd9fff3c14c97c9b12bd68818d4c2eaeefd8c95c661409f1f056bce42178d0ba9271aa344fdce6f81ea9 SHA512 b42af6a4a7b1d2f0d242f89bff3a1c25a608ff59b9902b90154ba82a40439afb802a2d319363fa388a5211420fdaf0ee9bfd1f0a0e6e85d89d1dd506b373ba40
+DIST vmd-1.9.4a55.src.tar.gz 43049895 BLAKE2B 311fdbf8742647d1dbba8346e8559d26b19ec445bb5df4b23f684c5769997e2261e200b8118668d296654f59ab340fc150f5aa33fc808ad55f2e78ce7030960b SHA512 1be5f50555423120fd8c5c335a346a40253fb80cc352f08907d864f6b34d3debe28d9a3fbf821c3a6c7c86c615fd09735c05aadf1b4503722075e9ab0b946378
diff --git a/sci-chemistry/vmd/vmd-1.9.4_alpha55.ebuild b/sci-chemistry/vmd/vmd-1.9.4_alpha55.ebuild
new file mode 100644
index 00000000000..28638554552
--- /dev/null
+++ b/sci-chemistry/vmd/vmd-1.9.4_alpha55.ebuild
@@ -0,0 +1,269 @@
+# Copyright 1999-2021 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+PYTHON_COMPAT=( python3_{8..10} )
+
+inherit cuda desktop flag-o-matic prefix python-single-r1 toolchain-funcs xdg
+
+DESCRIPTION="Visual Molecular Dynamics"
+HOMEPAGE="http://www.ks.uiuc.edu/Research/vmd/"
+
+MY_PV="${PV/_alpha/a}"
+MY_P="${PN}-${MY_PV}"
+SRC_URI="
+ ${MY_P}.src.tar.gz
+ fetch+https://dev.gentoo.org/~pacho/${PN}/${PN}-1.9.4_alpha51-gentoo-patches.tar.xz
+"
+
+SLOT="0"
+LICENSE="vmd"
+KEYWORDS="~amd64 ~x86 ~amd64-linux ~x86-linux"
+
+IUSE="cuda gromacs msms povray sqlite tachyon xinerama"
+REQUIRED_USE="${PYTHON_REQUIRED_USE}"
+
+RESTRICT="fetch"
+
+CDEPEND="${PYTHON_DEPS}
+ $(python_gen_cond_dep '
+ dev-python/numpy[${PYTHON_USEDEP}]
+ ')
+ >=dev-lang/tk-8.6.1:0=
+ dev-lang/perl
+ dev-libs/expat
+ sci-libs/netcdf:0=
+ virtual/opengl
+ >=x11-libs/fltk-1.1.10-r2:1
+ x11-libs/libXft
+ x11-libs/libXi
+ cuda? ( >=dev-util/nvidia-cuda-toolkit-4.2.9-r1:= )
+ gromacs? ( >=sci-chemistry/gromacs-5.0.4-r1:0=[tng] )
+ sqlite? ( dev-db/sqlite:3= )
+ tachyon? ( >=media-gfx/tachyon-0.99_beta6 )
+ xinerama? ( x11-libs/libXinerama )
+"
+DEPEND="${CDEPEND}"
+BDEPEND="
+ virtual/pkgconfig
+ dev-lang/swig
+"
+RDEPEND="${CDEPEND}
+ sci-biology/stride
+ sci-chemistry/chemical-mime-data
+ sci-chemistry/surf
+ x11-misc/xdg-utils
+ x11-terms/xterm
+ msms? ( sci-chemistry/msms-bin )
+ povray? ( media-gfx/povray )
+"
+
+S="${WORKDIR}/${MY_P}"
+
+VMD_DOWNLOAD="http://www.ks.uiuc.edu/Development/Download/download.cgi?PackageName=VMD"
+
+# Binary only plugin!!
+QA_PREBUILT="usr/lib*/vmd/plugins/LINUX/tcl/intersurf/bin/intersurf.so"
+QA_FLAGS_IGNORED_amd64=" usr/lib64/vmd/plugins/LINUX/tcl/volutil/volutil"
+QA_FLAGS_IGNORED_x86=" usr/lib/vmd/plugins/LINUX/tcl/volutil/volutil"
+
+pkg_nofetch() {
+ elog "Please download ${MY_P}.src.tar.gz from"
+ elog "${VMD_DOWNLOAD}"
+ elog "after agreeing to the license."
+ elog "Place it into your DISTDIR directory."
+}
+
+src_prepare() {
+ # Apply user patches from ${WORKDIR} to allow patching on patches
+ # subdir too
+ cd "${WORKDIR}"
+ default
+
+ # https://www.ks.uiuc.edu/Research/vmd/mailing_list/vmd-l/32121.html
+ # https://www.ks.uiuc.edu/Research/vmd/mailing_list/vmd-l/32116.html
+ eapply "${WORKDIR}"/${PN}-patches/${PN}-1.9.4a51-gentoo-plugins.patch
+
+ use cuda && cuda_sanitize
+
+ # Prepare plugins
+ cd plugins || die
+
+ sed '/^.SILENT/d' -i $(find -name Makefile)
+
+ sed \
+ -e "s:CC = gcc:CC = $(tc-getCC):" \
+ -e "s:CXX = g++:CXX = $(tc-getCXX):" \
+ -e "s:COPTO =.*\":COPTO = -fPIC -o \":" \
+ -e "s:LOPTO = .*\":LOPTO = ${LDFLAGS} -fPIC -o \":" \
+ -e "s:CCFLAGS =.*\":CCFLAGS = ${CFLAGS}\":" \
+ -e "s:CXXFLAGS =.*\":CXXFLAGS = ${CXXFLAGS}\":" \
+ -e "s:SHLD = gcc:SHLD = $(tc-getCC) -shared:" \
+ -e "s:SHXXLD = g++:SHXXLD = $(tc-getCXX) -shared:" \
+ -e "s:-ltcl8.5:-ltcl:" \
+ -i Make-arch || die "Failed to set up plugins Makefile"
+
+ sed \
+ -e '/^AR /s:=:?=:g' \
+ -e '/^RANLIB /s:=:?=:g' \
+ -i ../plugins/*/Makefile || die
+
+ tc-export AR RANLIB
+
+ sed \
+ -e "s:\$(CXXFLAGS)::g" \
+ -i hesstrans/Makefile || die
+
+ # prepare vmd itself
+ cd "${S}" || die
+
+ eapply "${WORKDIR}"/${PN}-patches/${PN}-1.9.4a51-gentoo-paths.patch
+
+ # https://www.ks.uiuc.edu/Research/vmd/mailing_list/vmd-l/32122.html
+ eapply "${WORKDIR}"/${PN}-patches/${PN}-1.9.4-tmpdir.patch
+
+ # PREFIX
+ sed \
+ -e "s:/usr/include/:${EPREFIX}/usr/include:g" \
+ -i configure || die
+
+ sed \
+ -e "s:gentoo-bindir:${ED}/usr/bin:g" \
+ -e "s:gentoo-libdir:${ED}/usr/$(get_libdir):g" \
+ -e "s:gentoo-opengl-include:${EPREFIX}/usr/include/GL:g" \
+ -e "s:gentoo-opengl-libs:${EPREFIX}/usr/$(get_libdir):g" \
+ -e "s:gentoo-gcc:$(tc-getCC):g" \
+ -e "s:gentoo-g++:$(tc-getCXX):g" \
+ -e "s:gentoo-nvcc:${EPREFIX}/opt/cuda/bin/nvcc:g" \
+ -e "s:gentoo-cflags:${CFLAGS}:g" \
+ -e "s:gentoo-cxxflags:${CXXFLAGS}:g" \
+ -e "s:gentoo-nvflags::g" \
+ -e "s:gentoo-ldflags:${LDFLAGS}:g" \
+ -e "s:gentoo-plugindir:${WORKDIR}/plugins:g" \
+ -e "s:gentoo-fltk-include:$(fltk-config --includedir):g" \
+ -e "s:gentoo-fltk-libs:$(dirname $(fltk-config --libs)) -Wl,-rpath,$(dirname $(fltk-config --libs)):g" \
+ -e "s:gentoo-libtachyon-include:${EPREFIX}/usr/include/tachyon:g" \
+ -e "s:gentoo-libtachyon-libs:${EPREFIX}/usr/$(get_libdir):g" \
+ -e "s:gentoo-netcdf-include:${EPREFIX}/usr/include:g" \
+ -e "s:gentoo-netcdf-libs:${EPREFIX}/usr/$(get_libdir):g" \
+ -i configure || die
+
+ if use cuda; then
+ sed \
+ -e "s:gentoo-cuda-lib:${EPREFIX}/opt/cuda/$(get_libdir):g" \
+ -e "/NVCCFLAGS/s:=:= ${NVCCFLAGS}:g" \
+ -i configure src/Makefile || die
+ sed \
+ -e '/compute_/d' \
+ -i configure || die
+ sed \
+ -e 's:-gencode .*code=sm_..::' \
+ -i src/Makefile || die
+ fi
+
+ sed \
+ -e "s:LINUXPPC:LINUX:g" \
+ -e "s:LINUXALPHA:LINUX:g" \
+ -e "s:LINUXAMD64:LINUX:g" \
+ -e "s:gentoo-stride:${EPREFIX}/usr/bin/stride:g" \
+ -e "s:gentoo-surf:${EPREFIX}/usr/bin/surf:g" \
+ -e "s:gentoo-tachyon:${EPREFIX}/usr/bin/tachyon:g" \
+ -i "${S}"/bin/vmd.sh || die "failed setting up vmd wrapper script"
+
+ EMAKEOPTS=(
+ TCLINC="-I${EPREFIX}/usr/include"
+ TCLLIB="-L${EPREFIX}/usr/$(get_libdir)"
+ TCLLDFLAGS="-shared"
+ NETCDFLIB="$($(tc-getPKG_CONFIG) --libs-only-L netcdf)${EPREFIX}/usr/$(get_libdir)/libnetcdf.so"
+ NETCDFINC="$($(tc-getPKG_CONFIG) --cflags-only-I netcdf)${EPREFIX}/usr/include"
+ NETCDFLDFLAGS="$($(tc-getPKG_CONFIG) --libs netcdf)"
+ NETCDFDYNAMIC=1
+ EXPATINC="-I${EPREFIX}/usr/include"
+ EXPATLIB="$($(tc-getPKG_CONFIG) --libs expat)"
+ EXPATLDFLAGS="-shared"
+ EXPATDYNAMIC=1
+ )
+ if use gromacs; then
+ EMAKEOPTS+=(
+ TNGLIB="$($(tc-getPKG_CONFIG) --libs libgromacs)"
+ TNGINC="-I${EPREFIX}/usr/include"
+ TNGLDFLAGS="-shared"
+ TNGDYNAMIC=1
+ )
+ fi
+ if use sqlite; then
+ EMAKEOPTS+=(
+ SQLITELIB="$($(tc-getPKG_CONFIG) --libs sqlite3)"
+ SQLITEINC="-I${EPREFIX}/usr/include"
+ SQLITELDFLAGS="-shared"
+ SQLITEDYNAMIC=1
+ )
+ fi
+}
+
+src_configure() {
+ local myconf="OPENGL OPENGLPBUFFER COLVARS FLTK TK TCL PTHREADS PYTHON IMD NETCDF NUMPY NOSILENT XINPUT"
+ rm -f configure.options && echo $myconf >> configure.options
+
+ use cuda && myconf+=" CUDA"
+# use mpi && myconf+=" MPI"
+ use tachyon && myconf+=" LIBTACHYON"
+ use xinerama && myconf+=" XINERAMA"
+
+ export \
+ PYTHON_INCLUDE_DIR="$(python_get_includedir)" \
+ PYTHON_LIBRARY_DIR="$(python_get_library_path)" \
+ PYTHON_LIBRARY="$(python_get_LIBS)" \
+ NUMPY_INCLUDE_DIR="$(python_get_sitedir)/numpy/core/include" \
+ NUMPY_LIBRARY_DIR="$(python_get_sitedir)/numpy/core/include"
+
+ perl ./configure LINUX \
+ ${myconf} || die
+}
+
+src_compile() {
+ # build plugins
+ cd "${WORKDIR}"/plugins || die
+
+ emake \
+ ${EMAKEOPTS[@]} \
+ LINUX
+
+ # build vmd
+ cd "${S}"/src || die
+ emake
+}
+
+src_install() {
+ # install plugins
+ cd "${WORKDIR}"/plugins || die
+ emake \
+ PLUGINDIR="${ED}/usr/$(get_libdir)/${PN}/plugins" \
+ distrib
+
+ # install vmd
+ cd "${S}"/src || die
+ emake install
+
+ # install docs
+ cd "${S}" || die
+ dodoc Announcement README doc/ig.pdf doc/ug.pdf
+
+ # remove some of the things we don't want and need in
+ # /usr/lib
+ cd "${ED}"/usr/$(get_libdir)/vmd || die
+ rm -fr doc README Announcement LICENSE || \
+ die "failed to clean up /usr/lib/vmd directory"
+
+ # adjust path in vmd wrapper
+ sed \
+ -e "s:${ED}::" -i "${ED}"/usr/bin/${PN} \
+ -e "/^defaultvmddir/s:^.*$:defaultvmddir=\"${EPREFIX}/usr/$(get_libdir)/${PN}\":g" \
+ || die "failed to set up vmd wrapper script"
+
+ # install icon and generate desktop entry
+ insinto /usr/share/pixmaps
+ doins "${WORKDIR}"/vmd-patches/vmd.png
+ eprefixify "${WORKDIR}"/vmd-patches/vmd.desktop
+ domenu "${WORKDIR}"/vmd-patches/vmd.desktop
+}
diff --git a/sci-chemistry/votca/Manifest b/sci-chemistry/votca/Manifest
new file mode 100644
index 00000000000..21dca30b58d
--- /dev/null
+++ b/sci-chemistry/votca/Manifest
@@ -0,0 +1,2 @@
+DIST votca-2022.tar.gz 61688862 BLAKE2B a6a8d1c34e2cd992d032730b2669c9ac5489b988fc334f730eaf1a40b275cc2fad8b24f03419510fe9fee7b0ad0bedf43f9b22b44ca1ae0178b16c9b255da53c SHA512 ea5b7405872a2c0c8d6b4b86148a605b5e83207f1953f0b7393dabbb106ac785c50b45462f6271fbfad04c0246704a92199943acc65eb30d7f1a0a6d6ee4ab83
+DIST votca-2022_rc2.tar.gz 61692061 BLAKE2B 9fdf016267ff6657bfbbd51c79c2c38cb7064635d26e80b905eeeb8326ca1780f7a9c711802491f3ec7a216dbd53b86fe08da2c969a6a10db110168a02ac0d0f SHA512 3bfd108df7499c21ad290955672ab042b9a11b7a868f0eb49fdbd94365e35ed7ffc8b8b44c9b7dd74b7504b8fd30cc6bacfed443068f2bb3702e272aad26c961
diff --git a/sci-chemistry/votca/metadata.xml b/sci-chemistry/votca/metadata.xml
new file mode 100644
index 00000000000..137114c8f25
--- /dev/null
+++ b/sci-chemistry/votca/metadata.xml
@@ -0,0 +1,18 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "https://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <maintainer type="person">
+ <email>junghans@gentoo.org</email>
+ <name>Christoph Junghans</name>
+ </maintainer>
+ <maintainer type="project">
+ <email>sci-chemistry@gentoo.org</email>
+ <name>Gentoo Chemistry Project</name>
+ </maintainer>
+ <use>
+ <flag name="gromacs">Add support for gromacs file formats through <pkg>sci-chemistry/gromacs</pkg></flag>
+ </use>
+ <upstream>
+ <remote-id type="github">votca/votca</remote-id>
+ </upstream>
+</pkgmetadata>
diff --git a/sci-chemistry/votca/votca-2022.ebuild b/sci-chemistry/votca/votca-2022.ebuild
new file mode 100644
index 00000000000..f59f5347f3d
--- /dev/null
+++ b/sci-chemistry/votca/votca-2022.ebuild
@@ -0,0 +1,70 @@
+# Copyright 1999-2022 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+inherit bash-completion-r1 cmake
+
+if [[ ${PV} == *9999 ]]; then
+ inherit git-r3
+ EGIT_REPO_URI="https://github.com/votca/votca.git"
+else
+ if [[ ${PV} = *_rc[1-9] ]]; then
+ MY_PV="${PV%%_rc*}-rc.${PV##*_rc}"
+ else
+ MY_PV="${PV}"
+ fi
+ SRC_URI="https://github.com/votca/votca/archive/v${MY_PV}.tar.gz -> ${P}.tar.gz"
+ KEYWORDS="~amd64 ~x86 ~amd64-linux"
+ S="${WORKDIR}/votca-${MY_PV}"
+fi
+
+DESCRIPTION="Versatile Object-oriented Toolkit for Coarse-graining Applications"
+HOMEPAGE="https://www.votca.org/"
+
+LICENSE="Apache-2.0"
+SLOT="0"
+IUSE="+gromacs test"
+RESTRICT="!test? ( test )"
+
+RDEPEND="
+ !sci-libs/votca-tools
+ !sci-chemistry/votca-csg
+ !sci-chemistry/votca-xtp
+ app-shells/bash:*
+ >=dev-cpp/eigen-3.3
+ dev-libs/boost:=
+ dev-libs/expat
+ sci-libs/fftw:3.0=
+ dev-lang/perl
+ gromacs? ( sci-chemistry/gromacs:= )
+ sci-libs/hdf5[cxx]
+ sci-libs/libxc
+ sci-libs/libint:2
+"
+DEPEND="${RDEPEND}"
+BDEPEND="virtual/pkgconfig"
+
+DOCS=( README.rst NOTICE.rst CHANGELOG.rst )
+
+src_configure() {
+ local mycmakeargs=(
+ -DENABLE_TESTING=$(usex test)
+ -DCMAKE_DISABLE_FIND_PACKAGE_GROMACS=$(usex !gromacs)
+ -DBUILD_CSGAPPS=ON
+ -DINSTALL_RC_FILES=OFF
+ -DCMAKE_DISABLE_FIND_PACKAGE_MKL=ON
+ )
+ cmake_src_configure
+}
+
+pkg_postinst() {
+ einfo
+ einfo "Please read and cite:"
+ einfo "VOTCA-XTP, J. Chem. Theo. Comp. 14, 6353 (2018)"
+ einfo "https://doi.org/10.1021/acs.jctc.8b00617"
+ einfo
+ einfo "VOTCA, J. Chem. Theory Comput. 5, 3211 (2009). "
+ einfo "https://dx.doi.org/10.1021/ct900369w"
+ einfo
+}
diff --git a/sci-chemistry/votca/votca-2022_rc2.ebuild b/sci-chemistry/votca/votca-2022_rc2.ebuild
new file mode 100644
index 00000000000..6a1ae090460
--- /dev/null
+++ b/sci-chemistry/votca/votca-2022_rc2.ebuild
@@ -0,0 +1,70 @@
+# Copyright 1999-2021 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+inherit bash-completion-r1 cmake
+
+if [[ ${PV} == *9999 ]]; then
+ inherit git-r3
+ EGIT_REPO_URI="https://github.com/votca/votca.git"
+else
+ if [[ ${PV} = *_rc[1-9] ]]; then
+ MY_PV="${PV%%_rc*}-rc.${PV##*_rc}"
+ else
+ MY_PV="${PV}"
+ fi
+ SRC_URI="https://github.com/votca/votca/archive/v${MY_PV}.tar.gz -> ${P}.tar.gz"
+ KEYWORDS="~amd64 ~x86 ~amd64-linux"
+ S="${WORKDIR}/votca-${MY_PV}"
+fi
+
+DESCRIPTION="Versatile Object-oriented Toolkit for Coarse-graining Applications"
+HOMEPAGE="https://www.votca.org/"
+
+LICENSE="Apache-2.0"
+SLOT="0"
+IUSE="+gromacs test"
+RESTRICT="!test? ( test )"
+
+RDEPEND="
+ !sci-libs/votca-tools
+ !sci-chemistry/votca-csg
+ !sci-chemistry/votca-xtp
+ app-shells/bash:*
+ >=dev-cpp/eigen-3.3
+ dev-libs/boost:=
+ dev-libs/expat
+ sci-libs/fftw:3.0=
+ dev-lang/perl
+ gromacs? ( sci-chemistry/gromacs:= )
+ sci-libs/hdf5[cxx]
+ sci-libs/libxc
+ sci-libs/libint:2
+"
+DEPEND="${RDEPEND}"
+BDEPEND="virtual/pkgconfig"
+
+DOCS=( README.rst NOTICE.rst CHANGELOG.rst )
+
+src_configure() {
+ local mycmakeargs=(
+ -DENABLE_TESTING=$(usex test)
+ -DCMAKE_DISABLE_FIND_PACKAGE_GROMACS=$(usex !gromacs)
+ -DBUILD_CSGAPPS=ON
+ -DINSTALL_RC_FILES=OFF
+ -DCMAKE_DISABLE_FIND_PACKAGE_MKL=ON
+ )
+ cmake_src_configure
+}
+
+pkg_postinst() {
+ einfo
+ einfo "Please read and cite:"
+ einfo "VOTCA-XTP, J. Chem. Theo. Comp. 14, 6353 (2018)"
+ einfo "https://doi.org/10.1021/acs.jctc.8b00617"
+ einfo
+ einfo "VOTCA, J. Chem. Theory Comput. 5, 3211 (2009). "
+ einfo "https://dx.doi.org/10.1021/ct900369w"
+ einfo
+}
diff --git a/sci-chemistry/votca/votca-9999.ebuild b/sci-chemistry/votca/votca-9999.ebuild
new file mode 100644
index 00000000000..6a1ae090460
--- /dev/null
+++ b/sci-chemistry/votca/votca-9999.ebuild
@@ -0,0 +1,70 @@
+# Copyright 1999-2021 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+inherit bash-completion-r1 cmake
+
+if [[ ${PV} == *9999 ]]; then
+ inherit git-r3
+ EGIT_REPO_URI="https://github.com/votca/votca.git"
+else
+ if [[ ${PV} = *_rc[1-9] ]]; then
+ MY_PV="${PV%%_rc*}-rc.${PV##*_rc}"
+ else
+ MY_PV="${PV}"
+ fi
+ SRC_URI="https://github.com/votca/votca/archive/v${MY_PV}.tar.gz -> ${P}.tar.gz"
+ KEYWORDS="~amd64 ~x86 ~amd64-linux"
+ S="${WORKDIR}/votca-${MY_PV}"
+fi
+
+DESCRIPTION="Versatile Object-oriented Toolkit for Coarse-graining Applications"
+HOMEPAGE="https://www.votca.org/"
+
+LICENSE="Apache-2.0"
+SLOT="0"
+IUSE="+gromacs test"
+RESTRICT="!test? ( test )"
+
+RDEPEND="
+ !sci-libs/votca-tools
+ !sci-chemistry/votca-csg
+ !sci-chemistry/votca-xtp
+ app-shells/bash:*
+ >=dev-cpp/eigen-3.3
+ dev-libs/boost:=
+ dev-libs/expat
+ sci-libs/fftw:3.0=
+ dev-lang/perl
+ gromacs? ( sci-chemistry/gromacs:= )
+ sci-libs/hdf5[cxx]
+ sci-libs/libxc
+ sci-libs/libint:2
+"
+DEPEND="${RDEPEND}"
+BDEPEND="virtual/pkgconfig"
+
+DOCS=( README.rst NOTICE.rst CHANGELOG.rst )
+
+src_configure() {
+ local mycmakeargs=(
+ -DENABLE_TESTING=$(usex test)
+ -DCMAKE_DISABLE_FIND_PACKAGE_GROMACS=$(usex !gromacs)
+ -DBUILD_CSGAPPS=ON
+ -DINSTALL_RC_FILES=OFF
+ -DCMAKE_DISABLE_FIND_PACKAGE_MKL=ON
+ )
+ cmake_src_configure
+}
+
+pkg_postinst() {
+ einfo
+ einfo "Please read and cite:"
+ einfo "VOTCA-XTP, J. Chem. Theo. Comp. 14, 6353 (2018)"
+ einfo "https://doi.org/10.1021/acs.jctc.8b00617"
+ einfo
+ einfo "VOTCA, J. Chem. Theory Comput. 5, 3211 (2009). "
+ einfo "https://dx.doi.org/10.1021/ct900369w"
+ einfo
+}