betna-0.9.7.ebuild 1014 B

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647
  1. # Copyright 1999-2015 Gentoo Foundation
  2. # Distributed under the terms of the GNU General Public License v2
  3. EAPI=5
  4. inherit eutils games
  5. DESCRIPTION="Defend your volcano from the attacking ants by firing rocks/bullets at them"
  6. HOMEPAGE="http://koti.mbnet.fi/makegho/c/betna/"
  7. SRC_URI="http://koti.mbnet.fi/makegho/c/betna/${P}.tgz"
  8. LICENSE="GPL-2"
  9. SLOT="0"
  10. KEYWORDS="amd64 ~ppc ~sparc x86 ~x86-fbsd"
  11. IUSE=""
  12. DEPEND="media-libs/libsdl[video]"
  13. RDEPEND="${DEPEND}"
  14. src_prepare() {
  15. sed -i \
  16. -e '/blobprintf.*char msg/s/char msg/const char msg/' \
  17. -e "s:images/:${GAMES_DATADIR}/${PN}/:" \
  18. src/main.cpp || die
  19. sed -i \
  20. -e '/^LDFLAGS/d' \
  21. -e '/--libs/s/-o/$(LDFLAGS) -o/' \
  22. -e 's:-O2:$(CXXFLAGS):g' \
  23. -e 's/g++/$(CXX)/' \
  24. Makefile || die
  25. }
  26. src_compile() {
  27. emake clean
  28. emake
  29. }
  30. src_install() {
  31. dogamesbin betna
  32. insinto "${GAMES_DATADIR}"/${PN}
  33. doins images/*
  34. newicon images/target.bmp ${PN}.bmp
  35. make_desktop_entry ${PN} Betna /usr/share/pixmaps/${PN}.bmp
  36. dodoc README Q\&A
  37. prepgamesdirs
  38. }