singularity-0.30c-r1.ebuild 1.3 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849
  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 eutils python-single-r1 games
  6. MUSIC=endgame-${PN}-music-006
  7. DESCRIPTION="A simulation of a true AI. Go from computer to computer, pursued by the entire world"
  8. HOMEPAGE="http://www.emhsoft.com/singularity/"
  9. SRC_URI="https://endgame-singularity.googlecode.com/files/${P}-src.tar.gz
  10. music? ( https://endgame-singularity.googlecode.com/files/${MUSIC}.zip )"
  11. LICENSE="GPL-2 CC-BY-SA-2.5"
  12. SLOT="0"
  13. KEYWORDS="amd64 x86"
  14. IUSE="+music"
  15. REQUIRED_USE="${PYTHON_REQUIRED_USE}"
  16. DEPEND="${PYTHON_DEPS}"
  17. RDEPEND="${DEPEND}
  18. dev-python/pygame[${PYTHON_USEDEP}]
  19. dev-python/numpy[${PYTHON_USEDEP}]
  20. media-libs/sdl-mixer[vorbis]"
  21. DEPEND="${DEPEND}
  22. app-arch/unzip"
  23. pkg_setup() {
  24. python-single-r1_pkg_setup
  25. games_pkg_setup
  26. }
  27. src_prepare() {
  28. rm -f code/{,*}/*.pyc data/*.html || die # Remove unecessary files
  29. }
  30. src_install() {
  31. insinto "${GAMES_DATADIR}/${PN}"
  32. doins -r code data ${PN}.py || die
  33. python_optimize "${ED%/}/${GAMES_DATADIR}"/${PN}
  34. if use music ; then
  35. doins -r ../${MUSIC}/music || die
  36. fi
  37. games_make_wrapper ${PN} "${EPYTHON} ${PN}.py" "${GAMES_DATADIR}/${PN}"
  38. dodoc README.txt TODO Changelog AUTHORS
  39. prepgamesdirs
  40. }