mmtk-2.7.9.ebuild 1.2 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455
  1. # Copyright 1999-2015 Gentoo Foundation
  2. # Distributed under the terms of the GNU General Public License v2
  3. EAPI=5
  4. PYTHON_COMPAT=( python2_7 )
  5. inherit distutils-r1
  6. # This number identifies each release on the CRU website.
  7. # Can't figure out how to avoid hardcoding it.
  8. NUMBER="4324"
  9. MY_PN=${PN/mmtk/MMTK}
  10. MY_P=${MY_PN}-${PV}
  11. DESCRIPTION="Molecular Modeling ToolKit for Python"
  12. HOMEPAGE="http://dirac.cnrs-orleans.fr/MMTK/"
  13. SRC_URI="http://sourcesup.cru.fr/frs/download.php/${NUMBER}/${MY_P}.tar.gz"
  14. SLOT="0"
  15. LICENSE="CeCILL-2"
  16. KEYWORDS="~amd64 ~x86 ~ppc ~amd64-linux ~x86-linux"
  17. IUSE="examples"
  18. RDEPEND="
  19. dev-python/cython[${PYTHON_USEDEP}]
  20. <dev-python/numpy-1.9[${PYTHON_USEDEP}]
  21. dev-python/scientificpython[${PYTHON_USEDEP}]"
  22. DEPEND="${RDEPEND}"
  23. S="${WORKDIR}"/${MY_P}
  24. python_prepare_all() {
  25. export MMTK_USE_CYTHON="1"
  26. sed \
  27. -e "/ext_package/d" \
  28. -e "/^if sphinx/s|:| == 3:|g" \
  29. -e "s:import sphinx:sphinx = None:g" \
  30. -i "${S}"/setup.py || die
  31. distutils-r1_python_prepare_all
  32. }
  33. python_install_all() {
  34. DOCS=( README* Doc/CHANGELOG )
  35. HTML_DOCS=( Doc/HTML/. )
  36. distutils-r1_python_install_all
  37. if use examples; then
  38. insinto /usr/share/${P}
  39. doins -r Examples
  40. fi
  41. }