# Copyright 1999-2007 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 # $Header: $ inherit eutils games DESCRIPTION="a wxpython-based online role playing game client" HOMEPAGE="http://www.openrpg.com" SRC_URI="mirror://sourceforge/${PN}/${P}.tar.gz" LICENSE="GPL-2" # A SLOT might be useful, actually, since this ebuild is a total and # unconflicting change from 1.6.1 SLOT="0" KEYWORDS="~amd64" IUSE="" # Note that >=python-2.4 is required as well, but that is a dependency of # wxpython. # See bug #178727 for details on wxpython-2.8, which is not in portage as of # this writing. DEPEND=">=dev-python/wxpython-2.8 " S="${WORKDIR}/${PN}1" pkg_setup() { ebeep 3 ewarn "" ewarn "This package has a number of insecurities related to the original" ewarn "design of OpenRPG. Only allow trusted users in to the games group," ewarn "and make your users aware of the fact that several configuration" ewarn "files that SHOULD be user-specific are in fact global." ewarn "" ewarn "Furthermore, you should decide right now if you want to use OpenRPG's" ewarn "built-in update feature, or if you would rather stick with portage." ewarn "OpenRPG's built in updater will *probably* fail due to write access" ewarn "restriction, but if you want to use it anyway be sure to use:" ewarn "" ewarn "emerge --oneshot --ask --verbose openrpg" ewarn "" ewarn "That will avoid adding openrpg to your world file, thus preventing" ewarn "portage from updating OpenRPG in the future." einfo "" einfo "Installation will continue in 15 seconds. Press Ctrl+c to abort." epause 15 } src_unpack() { unpack ${A} mkdir "${WORKDIR}/bins" mkdir "${WORKDIR}/images" cp "${FILESDIR}/openrpg-client" "${WORKDIR}/bins/" cp "${FILESDIR}/openrpg-server" "${WORKDIR}/bins/" cp "${S}/images/d20.xpm" "${WORKDIR}/images/" ln -s "${WORKDIR}/bins/openrpg-client" "${WORKDIR}/bins/openrpg" } src_install() { dogamesbin "${WORKDIR}/bins/"* || die "Could not insert launch scripts." insinto "${GAMES_DATADIR}" doins -r ${S} doicon "${WORKDIR}/images/d20.xpm" make_desktop_entry ${PN} "OpenRPG" "${WORKDIR}/images/d20.xpm" # I'd *like* to "dodoc" now, except that there's no documentation! The only # thing is "readme.txt", which is made irrelevant by this package. (and # should probably be deleted.) prepgamesdirs # This is required by openrpg. It *is* a security flaw, and it *can* be used # to execute arbitrary code deposited by anyone in the games group. It # sucks, and the solution is to make sure you only add trusted users to the # games group. The OpenRPG team is rewriting OpenRPG from the ground up - # hopefully they'll resolve this issue then. chmod -R g+w "${GAMES_DATADIR}/$PN}1" }