dev-cpp/pangomm: stable 2.42.1 for hppa, bug #717144
[gentoo.git] / sci-chemistry / votca-xtp / votca-xtp-1.5.1.ebuild
1 # Copyright 1999-2019 Gentoo Authors
2 # Distributed under the terms of the GNU General Public License v2
3
4 EAPI=6
5
6 CMAKE_MAKEFILE_GENERATOR="ninja"
7
8 inherit bash-completion-r1 cmake-utils multilib
9
10 IUSE="doc"
11 if [ "${PV}" != "9999" ]; then
12         SRC_URI="https://github.com/${PN/-//}/archive/v${PV}.tar.gz -> ${P}.tar.gz
13                 doc? ( https://github.com/${PN/-//}/releases/download/v${PV}/${PN}-manual-${PV}.pdf )"
14         KEYWORDS="~amd64 ~x86 ~amd64-linux ~x86-macos"
15         S="${WORKDIR}/${P#votca-}"
16 else
17         inherit git-r3
18         EGIT_REPO_URI="https://github.com/${PN/-//}.git"
19         KEYWORDS="~amd64"
20 fi
21
22 DESCRIPTION="Votca excitation and charge properties module"
23 HOMEPAGE="http://www.votca.org"
24
25 LICENSE="Apache-2.0"
26 SLOT="0"
27
28 RDEPEND="
29         ~sci-libs/votca-tools-${PV}[sqlite]
30         >=dev-cpp/eigen-3.3
31         ~sci-chemistry/votca-csg-${PV}
32         sci-libs/ceres-solver
33         sci-libs/libxc"
34
35 DEPEND="${RDEPEND}
36         >=app-text/txt2tags-2.5
37         virtual/pkgconfig"
38
39 if [ "${PV}" != "9999" ]; then
40         DEPEND="${DEPEND}
41         doc? (
42                 app-doc/doxygen[dot]
43                 dev-texlive/texlive-latexextra
44                 virtual/latex-base
45                 dev-tex/pgf
46         )"
47 fi
48
49 DOCS=( README.md NOTICE CHANGELOG.md )
50
51 src_configure() {
52         [[ ${PV} = *9999* ]] && mycmakeargs=(
53                 -DBUILD_XTP_MANUAL=$(usex doc)
54         )
55         cmake-utils_src_configure
56 }
57
58 src_install() {
59         cmake-utils_src_install
60         if use doc; then
61                 [[ ${PV} != *9999* ]] && dodoc "${DISTDIR}/${PN}-manual-${PV}.pdf"
62                 cmake-utils_src_make -C "${CMAKE_BUILD_DIR}" html
63                 dodoc -r "${CMAKE_BUILD_DIR}"/share/doc/html
64         fi
65 }
66
67 pkg_postinst() {
68         einfo
69         einfo "Please read and cite:"
70         einfo "VOTCA-XTP, J. Chem. Theo. Comp. 14, 6353 (2018)"
71         einfo "https://doi.org/10.1021/acs.jctc.8b00617"
72         einfo
73 }