# Copyright 1999-2005 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 # $Header: $ inherit games DESCRIPTION="A multi-player game of strategy and coordination" HOMEPAGE="http://www.lysator.liu.se/~mbrx/XBattleAI/index.html" SRC_URI="http://www.lysator.liu.se/~mbrx/XBattleAI/${P}.tgz" LICENSE="xbattle" SLOT="0" KEYWORDS="~x86" IUSE="" # Since this uses similar code and the same binary name as the original XBattle, # we want to make sure you can't install both at the same time DEPEND="virtual/x11 !games-strategy/xbattle" src_unpack() { unpack ${A} cd "${S}" sed -i -e "/TARGET/s:/usr/bin/:${GAMES_BINDIR}:" Makefile || die "sed Makefile failed" } src_compile() { egamesconf || die "egamesconf failed" emake || die "emake failed" } src_install() { dogamesbin "xbattle" || die "installing the binary failed" dodir "${GAMES_DATADIR}/${PN}" || die "creating data dir failed" cp -r xbas/ xbos/ xbts/ "${D}/${GAMES_DATADIR}/${PN}" || die "installing data failed" newman xbattle.man xbattle.6 dodoc README xbattle.dot prepgamesdirs } pkg_postinst() { games_pkg_postinst }