diff options
Diffstat (limited to 'games-server/pvpgn')
-rw-r--r-- | games-server/pvpgn/ChangeLog | 8 | ||||
-rw-r--r-- | games-server/pvpgn/Manifest | 4 | ||||
-rw-r--r-- | games-server/pvpgn/files/1.6.5-fhs.patch | 211 | ||||
-rw-r--r-- | games-server/pvpgn/files/digest-pvpgn-1.6.5 | 2 | ||||
-rw-r--r-- | games-server/pvpgn/files/init.d.rc | 37 | ||||
-rw-r--r-- | games-server/pvpgn/metadata.xml | 5 | ||||
-rw-r--r-- | games-server/pvpgn/pvpgn-1.6.5.ebuild | 87 |
7 files changed, 354 insertions, 0 deletions
diff --git a/games-server/pvpgn/ChangeLog b/games-server/pvpgn/ChangeLog new file mode 100644 index 000000000000..49e6a537a94d --- /dev/null +++ b/games-server/pvpgn/ChangeLog @@ -0,0 +1,8 @@ +# ChangeLog for games-server/pvpgn +# Copyright 1999-2004 Gentoo Foundation; Distributed under the GPL v2 +# $Header: /var/cvsroot/gentoo-x86/games-server/pvpgn/ChangeLog,v 1.1 2004/09/01 04:39:51 vapier Exp $ + +*pvpgn-1.6.5 (01 Sep 2004) + + 01 Sep 2004; Mike Frysinger <vapier@gentoo.org> : + Initial import. Ebuild submitted by Mihai RUSU #40979. diff --git a/games-server/pvpgn/Manifest b/games-server/pvpgn/Manifest new file mode 100644 index 000000000000..8b86a5d88ab4 --- /dev/null +++ b/games-server/pvpgn/Manifest @@ -0,0 +1,4 @@ +MD5 a5d62283715140e6349f0b6a9fe35736 pvpgn-1.6.5.ebuild 2351 +MD5 ba5db7daf3b6cfeb5c463b3d8f7ee32b files/digest-pvpgn-1.6.5 134 +MD5 68ec5add991261bc03bbc8dc7e5df905 files/init.d.rc 785 +MD5 778be818c35e7df1e022398198427172 files/1.6.5-fhs.patch 10322 diff --git a/games-server/pvpgn/files/1.6.5-fhs.patch b/games-server/pvpgn/files/1.6.5-fhs.patch new file mode 100644 index 000000000000..84be5abcd981 --- /dev/null +++ b/games-server/pvpgn/files/1.6.5-fhs.patch @@ -0,0 +1,211 @@ +diff -ur ../pvpgn-1.6.4/conf/bnetd.conf.in ./conf/bnetd.conf.in +--- ../pvpgn-1.6.4/conf/bnetd.conf.in 2004-06-22 16:29:33.000000000 +0300 ++++ ./conf/bnetd.conf.in 2004-08-27 11:12:19.789902272 +0300 +@@ -46,13 +46,13 @@ + # - "pass" : db password # + # # + # Examples: # +-# storage_path = file:dir=/usr/local/var/users;clan=/usr/local/var/clans;default=/usr/local/etc/bnetd_default_user.plain +-# storage_path = cdb:dir=/usr/local/var/userscdb;clan=/usr/local/var/clans;default=/usr/local/etc/bnetd_default_user.cdb ++# storage_path = file:dir=%statedir%/users;clan=%statedir%/clans;default=%confdir%/bnetd_default_user.plain ++# storage_path = cdb:dir=%statedir%/userscdb;clan=%statedir%/clans;default=%confdir%/bnetd_default_user.cdb + # storage_path = sql:mode=mysql;host=127.0.0.1;name=PVPGN;user=pvpgn;pass=pvpgnrocks;default=0 + # storage_path = sql:mode=pgsql;host=127.0.0.1;name=pvpgn;user=pvpgn;pass=pvpgnrocks;default=0 + #----------------------------------------------------------------------------# + +-storage_path = file:dir=/usr/local/var/users;clan=/usr/local/var/clans;default=/usr/local/etc/bnetd_default_user.plain ++storage_path = file:dir=%statedir%/users;clan=%statedir%/clans;default=%confdir%/bnetd_default_user.plain + + # # + ############################################################################## +@@ -63,36 +63,36 @@ + # Use absolute paths in these lines to avoid problems! # + #----------------------------------------------------------------------------# + +-filedir = /usr/local/var/files +-reportdir = /usr/local/var/reports +-chanlogdir = /usr/local/var/chanlogs +-motdfile = /usr/local/etc/bnmotd.txt +-issuefile = /usr/local/etc/bnissue.txt +-channelfile = /usr/local/etc/channel.conf +-newsfile = /usr/local/etc/news.txt +-adfile = /usr/local/etc/ad.conf +-topicfile = /usr/local/etc/topics.conf +-ipbanfile = /usr/local/etc/bnban.conf +-helpfile = /usr/local/etc/bnhelp.conf +-transfile = /usr/local/etc/gametrans.conf +-mpqfile = /usr/local/etc/autoupdate.conf +-logfile = /usr/local/var/bnetd.log +-realmfile = /usr/local/etc/realm.conf +-maildir = /usr/local/var/bnmail +-versioncheck_file = /usr/local/etc/versioncheck.conf +-mapsfile = /usr/local/etc/bnmaps.conf +-xplevelfile = /usr/local/etc/bnxplevel.conf +-xpcalcfile = /usr/local/etc/bnxpcalc.conf ++filedir = %datadir% ++reportdir = %statedir%/reports ++chanlogdir = %statedir%/chanlogs ++motdfile = %confdir%/bnmotd.txt ++issuefile = %confdir%/bnissue.txt ++channelfile = %confdir%/channel.conf ++newsfile = %confdir%/news.txt ++adfile = %confdir%/ad.conf ++topicfile = %statedir%/etc/topics.conf ++ipbanfile = %statedir%/etc/bnban.conf ++helpfile = %confdir%/bnhelp.conf ++transfile = %confdir%/gametrans.conf ++mpqfile = %confdir%/autoupdate.conf ++logfile = %logdir%/bnetd.log ++realmfile = %confdir%/realm.conf ++maildir = %statedir%/bnmail ++versioncheck_file = %confdir%/versioncheck.conf ++mapsfile = %confdir%/bnmaps.conf ++xplevelfile = %confdir%/bnxplevel.conf ++xpcalcfile = %confdir%/bnxpcalc.conf + #pidfile = /usr/local/var/bnetd.pid +-ladderdir = /usr/local/var/ladders +-command_groups_file = /usr/local/etc/command_groups.conf +-tournament_file = /usr/local/etc/tournament.conf +-statusdir = /usr/local/var/status +-aliasfile = /usr/local/etc/bnalias.conf +-w3trans_file = /usr/local/etc/w3trans.conf +-anongame_infos_file = /usr/local/etc/anongame_infos.conf +-DBlayoutfile = /usr/local/etc/sql_DB_layout.conf +-supportfile = /usr/local/etc/supportfile.conf ++ladderdir = %statedir%/ladders ++command_groups_file = %confdir%/command_groups.conf ++tournament_file = %confdir%/tournament.conf ++statusdir = %statedir%/status ++aliasfile = %confdir%/bnalias.conf ++w3trans_file = %confdir%/w3trans.conf ++anongame_infos_file = %confdir%/anongame_infos.conf ++DBlayoutfile = %confdir%/sql_DB_layout.conf ++supportfile = %confdir%/supportfile.conf + + fortunecmd = /usr/games/fortune + +diff -ur ../pvpgn-1.6.4/conf/d2cs.conf.in ./conf/d2cs.conf.in +--- ../pvpgn-1.6.4/conf/d2cs.conf.in 2004-08-12 15:30:36.000000000 +0300 ++++ ./conf/d2cs.conf.in 2004-08-26 14:11:11.000000000 +0300 +@@ -79,13 +79,13 @@ + # Use absolute paths in these lines to avoid problems! # + #-------------------------------------------------------------------------------# + # # +-logfile = /usr/local/var/d2cs.log +-charsavedir = /usr/local/var/charsave +-charinfodir = /usr/local/var/charinfo +-ladderdir = /usr/local/var/ladders +-newbiefile = /usr/local/var/files/newbie.save +-d2gstransfile = /usr/local/etc/d2gstrans.conf +-d2gsconffile = /usr/local/etc/d2server.ini ++logfile = %logdir%/d2cs.log ++charsavedir = %statedir%/charsave ++charinfodir = %statedir%/charinfo ++ladderdir = %statedir%/ladders ++newbiefile = %datadir%/files/newbie.save ++d2gstransfile = %confdir%/d2gstrans.conf ++d2gsconffile = %confdir%/d2server.ini + # # + ################################################################################# + +diff -ur ../pvpgn-1.6.4/conf/d2dbs.conf.in ./conf/d2dbs.conf.in +--- ../pvpgn-1.6.4/conf/d2dbs.conf.in 2004-01-21 21:21:26.000000000 +0200 ++++ ./conf/d2dbs.conf.in 2004-08-26 14:12:11.000000000 +0300 +@@ -47,13 +47,13 @@ + # File and Path section # + # Use absolute paths in these lines to avoid problems! # + #-------------------------------------------------------------------------------# +-logfile = /usr/local/var/d2dbs.log +-logfile-gs = /usr/local/var/d2dbs-gs.log +-charsavedir = /usr/local/var/charsave +-charinfodir = /usr/local/var/charinfo +-ladderdir = /usr/local/var/ladders +-bak_charsavedir = /usr/local/var/bak/charsave +-bak_charinfodir = /usr/local/var/bak/charinfo ++logfile = %logdir%/d2dbs.log ++logfile-gs = %logdir%/d2dbs-gs.log ++charsavedir = %statedir%/charsave ++charinfodir = %statedir%/charinfo ++ladderdir = %statedir%/ladders ++bak_charsavedir = %statedir%/bak/charsave ++bak_charinfodir = %statedir%/bak/charinfo + # # + ################################################################################# + +diff -ur ../pvpgn-1.6.4/src/Makefile.in ./src/Makefile.in +--- ../pvpgn-1.6.4/src/Makefile.in 2004-06-23 00:39:31.000000000 +0300 ++++ ./src/Makefile.in 2004-08-27 11:14:55.087293480 +0300 +@@ -23,21 +23,22 @@ + bindir = @bindir@ + sbindir = @sbindir@ + mandir = @mandir@ +-confdir = @sysconfdir@ +-sharedir = @localstatedir@ +-filesdir = @localstatedir@/files +-usersdir = @localstatedir@/users +-userscdbdir = @localstatedir@/userscdb +-clandir = @localstatedir@/clans +-bnmaildir = @localstatedir@/bnmail +-reportsdir = @localstatedir@/reports +-chanlogsdir = @localstatedir@/chanlogs +-charinfodir = @localstatedir@/charinfo +-charsavedir = @localstatedir@/charsave +-ladderdir = @localstatedir@/ladders +-statusdir = @localstatedir@/status +-bak_charsavedir = @localstatedir@/bak/charsave +-bak_charinfodir = @localstatedir@/bak/charinfo ++confdir = @sysconfdir@/pvpgn ++statedir = @localstatedir@/pvpgn ++filesdir = @datadir@/pvpgn ++usersdir = @localstatedir@/pvpgn/users ++userscdbdir = @localstatedir@/pvpgn/userscdb ++clandir = @localstatedir@/pvpgn/clans ++bnmaildir = @localstatedir@/pvpgn/bnmail ++reportsdir = @localstatedir@/pvpgn/reports ++chanlogsdir = @localstatedir@/pvpgn/chanlogs ++charinfodir = @localstatedir@/pvpgn/charinfo ++charsavedir = @localstatedir@/pvpgn/charsave ++ladderdir = @localstatedir@/pvpgn/ladders ++statusdir = @localstatedir@/pvpgn/status ++bak_charsavedir = @localstatedir@/pvpgn/bak/charsave ++bak_charinfodir = @localstatedir@/pvpgn/bak/charinfo ++logdir = @localstatedir@/pvpgn/log + + SRC_SRCDIR = @srcdir@ + SRC_BINDIR = @srcdir@/../bin +@@ -630,7 +631,7 @@ + + .PHONY: install-share + install-share: +- ${INSTALL_DIRS} ${DESTDIR}/${sharedir} ${DESTDIR}/${filesdir} ${DESTDIR}/${usersdir} ${DESTDIR}/${userscdbdir} ${DESTDIR}/${bnmaildir} ${DESTDIR}/${reportsdir} \ ++ ${INSTALL_DIRS} ${DESTDIR}/${datadir} ${DESTDIR}/${statedir} ${DESTDIR}/${statedir}/etc ${DESTDIR}/${filesdir} ${DESTDIR}/${usersdir} ${DESTDIR}/${userscdbdir} ${DESTDIR}/${bnmaildir} ${DESTDIR}/${reportsdir} \ + ${DESTDIR}/${chanlogsdir} ${DESTDIR}/${charinfodir} ${DESTDIR}/${charsavedir} ${DESTDIR}/${bak_charsavedir} \ + ${DESTDIR}/${bak_charinfodir} ${DESTDIR}/${ladderdir} ${DESTDIR}/${statusdir} ${DESTDIR}/${clandir} + @list='${SHARES}'; for p in $$list; do \ +@@ -680,21 +681,21 @@ + .PHONY: uninstall-share + uninstall-share: + @list='${SHARES}'; for p in $$list; do \ +- ${ECHO} " ${RMF} ${sharedir}/$$p"; \ +- ${RMF} ${sharedir}/$$p; \ ++ ${ECHO} " ${RMF} ${filesdir}/$$p"; \ ++ ${RMF} ${filesdir}/$$p; \ + done + + ${SRC_CONFDIR}/bnetd.conf: ${SRC_CONFDIR}/bnetd.conf.in ${SRC_SRCDIR}/config.status + @${RMF} $@ +- ${SED} -e "s@/usr/local/var/@${sharedir}/@g" -e "s@/usr/local/etc/@${confdir}/@g" ${SRC_CONFDIR}/bnetd.conf.in > $@ ++ ${SED} -e "s@%datadir%@${filesdir}/@g" -e "s@%confdir%@${confdir}/@g" -e "s@%statedir%@${statedir}@g" -e "s@%logdir%@${logdir}@g" ${SRC_CONFDIR}/bnetd.conf.in > $@ + + ${SRC_CONFDIR}/d2cs.conf: ${SRC_CONFDIR}/d2cs.conf.in ${SRC_SRCDIR}/config.status + @${RMF} $@ +- ${SED} -e "s@\(=[[:blank:]]*\"*\)/usr/local/var/@\1${sharedir}/@g" -e "s@\(=[[:blank:]]*\"*\)/usr/local/etc/@\1${confdir}/@g" ${SRC_CONFDIR}/d2cs.conf.in > $@ ++ ${SED} -e "s@\(=[[:blank:]]*\"*\)%datadir%@\1${filesdir}/@g" -e "s@\(=[[:blank:]]*\"*\)%confdir%@\1${confdir}/@g" -e "s@\(=[[:blank:]]*\"*\)%statedir%@\1${statedir}/@g" -e "s@\(=[[:blank:]]*\"*\)%logdir%@\1${logdir}/@g" ${SRC_CONFDIR}/d2cs.conf.in > $@ + + ${SRC_CONFDIR}/d2dbs.conf: ${SRC_CONFDIR}/d2dbs.conf.in ${SRC_SRCDIR}/config.status + @${RMF} $@ +- ${SED} -e "s@\(=[[:blank:]]*\"*\)/usr/local/var/@\1${sharedir}/@g" -e "s@\(=[[:blank:]]*\"*\)/usr/local/etc/@\1${confdir}/@g" ${SRC_CONFDIR}/d2dbs.conf.in > $@ ++ ${SED} -e "s@\(=[[:blank:]]*\"*\)%datadir%@\1${filesdir}/@g" -e "s@\(=[[:blank:]]*\"*\)%confdir%@\1${confdir}/@g" -e "s@\(=[[:blank:]]*\"*\)%statedir%@\1${statedir}/@g" -e "s@\(=[[:blank:]]*\"*\)%logdir%@\1${logdir}/@g" ${SRC_CONFDIR}/d2dbs.conf.in > $@ + + ${SRC_ACDIR}/ansi2knr: ${SRC_ACDIR}/ansi2knr.o + @${RMF} $@ diff --git a/games-server/pvpgn/files/digest-pvpgn-1.6.5 b/games-server/pvpgn/files/digest-pvpgn-1.6.5 new file mode 100644 index 000000000000..3d25d5d4a976 --- /dev/null +++ b/games-server/pvpgn/files/digest-pvpgn-1.6.5 @@ -0,0 +1,2 @@ +MD5 89d10957b44fb60cd112c588cf644da1 pvpgn-1.6.5.tar.bz2 1024406 +MD5 8ba36144ea3a7efe200536c142bb7886 pvpgn-support-1.0.tar.gz 126047 diff --git a/games-server/pvpgn/files/init.d.rc b/games-server/pvpgn/files/init.d.rc new file mode 100644 index 000000000000..52bc0b1a90be --- /dev/null +++ b/games-server/pvpgn/files/init.d.rc @@ -0,0 +1,37 @@ +#!/sbin/runscript +# Copyright 1999-2004 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/games-server/pvpgn/files/init.d.rc,v 1.1 2004/09/01 04:39:51 vapier Exp $ + +opts="reload shutdown" + +depend() { + need net +} + +checkconfig() { + if [ ! -f /etc/games/pvpgn/NAME.conf ]; then + eerror "You must have a NAME.conf configuration file to start NAME" + return 1 + fi +} + +start() { + checkconfig || return 1 + ebegin "Starting PvPGN NAME" + start-stop-daemon --start --quiet \ + --exec GAMES_BINDIR/NAME -c GAMES_USER:GAMES_GROUP -- + eend $? "Failed to start NAME" +} + +stop() { + ebegin "Stopping PvPGN NAME" + killall NAME + eend $? +} + +reload() { + ebegin "Rehashing configuration for PvPGN NAME" + killall -1 NAME + eend $? +} diff --git a/games-server/pvpgn/metadata.xml b/games-server/pvpgn/metadata.xml new file mode 100644 index 000000000000..d3c2cc926f0b --- /dev/null +++ b/games-server/pvpgn/metadata.xml @@ -0,0 +1,5 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> +<herd>games</herd> +</pkgmetadata> diff --git a/games-server/pvpgn/pvpgn-1.6.5.ebuild b/games-server/pvpgn/pvpgn-1.6.5.ebuild new file mode 100644 index 000000000000..9c947b3a0340 --- /dev/null +++ b/games-server/pvpgn/pvpgn-1.6.5.ebuild @@ -0,0 +1,87 @@ +# Copyright 1999-2004 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/games-server/pvpgn/pvpgn-1.6.5.ebuild,v 1.1 2004/09/01 04:39:51 vapier Exp $ + +inherit games + +SP="pvpgn-support-1.0" +DESCRIPTION="A gaming server for Battle.Net compatible clients" +HOMEPAGE="http://www.pvpgn.org/" +SRC_URI="mirror://sourceforge/pvpgn/${P}.tar.bz2 + mirror://sourceforge/pvpgn/${SP}.tar.gz" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="~x86" +IUSE="mysql postgres" + +DEPEND="virtual/libc + sys-libs/zlib + mysql? ( >=dev-db/mysql-3.23 ) + postgres? ( >=dev-db/postgresql-7 )" + +src_unpack() { + unpack ${A} + cd ${S} + epatch ${FILESDIR}/${PV}-fhs.patch +} + +src_compile() { + cd src + egamesconf \ + `use_with mysql` \ + `use_with postgres pgsql` \ + || die + emake || die "compile problem" +} + +src_install() { + dodoc README README.DEV CREDITS BUGS TODO UPDATE version-history.txt + docinto docs + dodoc docs/* + + cd src + make DESTDIR=${D} install || die + + insinto ${GAMES_DATADIR}/pvpgn + doins ${WORKDIR}/${SP}/* + + exeinto /etc/init.d + local f + for f in bnetd d2cs d2dbs ; do + newexe ${FILESDIR}/init.d.rc ${f} + sed -i \ + -e "s:NAME:${f}:g" \ + -e "s:GAMES_BINDIR:${GAMES_BINDIR}:g" \ + -e "s:GAMES_USER:${GAMES_USER}:g" \ + -e "s:GAMES_GROUP:${GAMES_GROUP}:g" \ + ${D}/etc/init.d/${f} + done + + prepgamesdirs +} + +pkg_postinst() { + einfo "Setting up permissions on ${GAMES_STATEDIR}/pvpgn" + mkdir -p ${GAMES_STATEDIR}/pvpgn/log + chmod 0755 ${GAMES_STATEDIR}/pvpgn/log + chown -R ${GAMES_USER}:${GAMES_GROUP} ${GAMES_STATEDIR}/pvpgn + chmod 0750 ${GAMES_STATEDIR}/pvpgn + + einfo " If this is a first installation you have to configure package by" + einfo "editing the configuration files provided in \"${GAMES_SYSCONFDIR}/pvpgn\". Also you" + einfo "should read the documentation from /usr/share/docs/${P}/" + einfo + einfo " If you are upgrading you MUST read /usr/share/docs/${P}/UPDATE.gz" + einfo "and update your configuration acordingly." + if use mysql ; then + einfo + einfo " You have enabled MySQL storage support. You will need to edit " + einfo "bnetd.conf to use it. Read README.storage from the docs dir." + fi + if use postgres ; then + einfo + einfo " You have enabled PostgreSQL storage support. You will need to edit " + einfo "bnetd.conf to use it. Read README.storage from the docs dir." + fi +} |