# Copyright 1999-2006 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 # $Header: $ inherit games DESCRIPTION="Crossword game artificial intelligence and analysis tool that also plays Scrabble" HOMEPAGE="http://quackle.org" SRC_URI="http://web.mit.edu/jasonkb/www/quackle/downloads/${P}/${P}-source.tar.gz" LICENSE="GPL-2" SLOT="0" KEYWORDS="~amd64" IUSE="" DEPEND="dev-util/scons >=x11-libs/qt-4.2" RDEPEND="$DEPEND" src_unpack() { unpack ${A} cd ${S} #includes header to make C++ assert calls work epatch ${FILESDIR}/0.95-gentoo-assert.patch #changes path to data files einfo "Removing hard-coded paths to data files" replace \"data\" \"${GAMES_DATADIR}/${PN}\" -- quackletest.cpp quacker/settings.cpp replace ../data ${GAMES_DATADIR}/${PN} -- quacker/settings.cpp encodeleaves/encodeleaves.cpp makeminidawg/makeminidawg.cpp #need to clean up distfile first scons -c || die "couldn't clean up cruft in distfiles" } src_compile() { scons cd quackleio || die "couldn't cd to quackleio" qmake && emake || die "making quackleio failed" cd ../quacker || die "couldn't cd to quacker" qmake && emake || die "making quacker failed" } src_install() { dogamesbin ${S}/quacker/quacker || "installing quacker failed" insinto ${GAMES_DATADIR}/${PN} doins -r data/* || die "installing quacker data files failed" doicon "${FILESDIR}"/quackle.png make_desktop_entry quacker "Quackle" quackle "Game;BoardGame" }