# Copyright 1999-2007 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 # $Header: $ inherit eutils games DESCRIPTION="A free and portable roguelike molded in the tradition of the \ early greats of the genre." HOMEPAGE="http://crawl-ref.sourceforge.net/" SRC_URI="http://umn.dl.sourceforge.net/sourceforge/crawl-ref/stone_soup-${PV}-src.tbz2" LICENSE="crawl" SLOT="0" KEYWORDS="~x86 ~amd64" IUSE="" DEPEND="sys-libs/ncurses" RDEPEND="sys-libs/ncurses" S="${WORKDIR}/stone_soup-${PV}-src" src_unpack() { unpack stone_soup-${PV}-src.tbz2 || die "unpacking files" } src_compile() { cd source sed -i \ -e '/^# DATADIR :=/a DATADIR := ${GAMES_DATADIR}/crawl-data' \ makefile.unix \ || die "sed failed" sed -i \ -e '/^# SAVEDIR :=/a SAVEDIR := ${GAMES_STATEDIR}/crawl-saves/' \ makefile.unix \ || die "sed failed" sed -i \ -e "s:morgue/:.:" \ initfile.cc \ || die "sed failed" emake || die "compilation failed" } src_install() { cd source dogamesbin crawl || die "installing the binary failed" dodir ${GAMES_DATADIR}/crawl-data dodir ${GAMES_STATEDIR}/crawl-saves cp -r dat ${D}${GAMES_DATADIR}/crawl-data cd .. dodoc CREDITS readme.txt cd docs dodoc crawl_manual.txt doman crawl.6 prepgamesdirs fperms 770 "${GAMES_STATEDIR}/crawl-saves" || die "fparms failed" }