* [gentoo-commits] repo/gentoo:master commit in: games-server/pvpgn/files/, games-server/pvpgn/
@ 2021-04-09 21:47 Sam James
0 siblings, 0 replies; 2+ messages in thread
From: Sam James @ 2021-04-09 21:47 UTC (permalink / raw
To: gentoo-commits
commit: d372eba5a64bc383093d378d4fd0a166a86dfbf3
Author: Sam James <sam <AT> gentoo <DOT> org>
AuthorDate: Fri Apr 9 21:45:07 2021 +0000
Commit: Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Fri Apr 9 21:46:24 2021 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=d372eba5
games-server/pvpgn: add 1.99.7.2.1
Signed-off-by: Sam James <sam <AT> gentoo.org>
games-server/pvpgn/Manifest | 1 +
.../pvpgn/files/pvpgn-1.99.7.2.1-path.patch | 33 +++++++
games-server/pvpgn/pvpgn-1.99.7.2.1.ebuild | 109 +++++++++++++++++++++
3 files changed, 143 insertions(+)
diff --git a/games-server/pvpgn/Manifest b/games-server/pvpgn/Manifest
index 83a432ea0dc..5e4d6fed6c6 100644
--- a/games-server/pvpgn/Manifest
+++ b/games-server/pvpgn/Manifest
@@ -1,2 +1,3 @@
DIST pvpgn-1.8.5.tar.bz2 982931 BLAKE2B 73c84278c5a7a13b781541f49a77af45d05950f0e378237ec0bfce3b4a55a94f91cfc2f994f56046e76c3dfb5d390427ee9cecbc21d1da048d2c503bfa21cf7b SHA512 7cbe141efe03efa4ce0fc1cc3b4e15afe2e85e3c83a27afdf36fec9e2dadf1c7b9aca1773e6a3e6566b62f5a7999cc040c9517786ca70eeb70f86eea84e9218e
+DIST pvpgn-1.99.7.2.1.tar.gz 1515818 BLAKE2B b4f5017b58e91785b199b700ced9e54bc7d953f2fe12696c931d44e5cad93f86eb77cff8fdc429e7d033f19d93ae895c192ce4c5a73beb7812c2f27f94bbeaf3 SHA512 b3b042c739b15b8460d9e0da1ed9f1fb6fb2db39046a23d7d30290b47b31e41de6c152023f0ab6dd92ce0c7b7483e6933509bda216cb0cb1260b5eed0bc874dd
DIST pvpgn-support-1.3.tar.gz 123805 BLAKE2B dc051265c6d4c5a2ab69379f7ac4a57f402d25e8898020217f2ae5f12cb2ca4db860df47efe38ed6494eb040cbd52a7ed495bc3dab59c9e9e48a8e1386500d6e SHA512 9002fcdb7da92e84af97319b9f1e38f5cf97466aef88549b1fe81b9070643f321011adf674424e2c4acc22f847c7fc61ca2cbf2da0223842e9b9e6c8f1427d76
diff --git a/games-server/pvpgn/files/pvpgn-1.99.7.2.1-path.patch b/games-server/pvpgn/files/pvpgn-1.99.7.2.1-path.patch
new file mode 100644
index 00000000000..8cfa94610b5
--- /dev/null
+++ b/games-server/pvpgn/files/pvpgn-1.99.7.2.1-path.patch
@@ -0,0 +1,33 @@
+--- a/cmake/Modules/DefineInstallationPaths.cmake
++++ b/cmake/Modules/DefineInstallationPaths.cmake
+@@ -37,8 +37,8 @@
+ )
+ else()
+ SET(LOCALSTATE_INSTALL_DIR
+- "${EXEC_INSTALL_PREFIX}/var/${APPLICATION_NAME}"
+- CACHE PATH "The ${APPLICATION_NAME} local state install dir (default prefix/var)"
++ "/var/${APPLICATION_NAME}"
++ CACHE PATH "The ${APPLICATION_NAME} local state install dir (default /var)"
+ FORCE
+ )
+ endif()
+@@ -75,4 +75,4 @@
+ CACHE PATH "The ${APPLICATION_NAME} sysconfig install dir (default prefix/etc)"
+ FORCE
+ )
+-endif()
+\ No newline at end of file
++endif()
+--- a/cmake/Modules/DefineInstallationPaths.cmake
++++ b/cmake/Modules/DefineInstallationPaths.cmake
+@@ -71,8 +71,8 @@
+ )
+ else()
+ SET(SYSCONF_INSTALL_DIR
+- "${EXEC_INSTALL_PREFIX}/etc/${APPLICATION_NAME}"
+- CACHE PATH "The ${APPLICATION_NAME} sysconfig install dir (default prefix/etc)"
++ "/etc/${APPLICATION_NAME}"
++ CACHE PATH "The ${APPLICATION_NAME} sysconfig install dir (default /etc)"
+ FORCE
+ )
+ endif()
diff --git a/games-server/pvpgn/pvpgn-1.99.7.2.1.ebuild b/games-server/pvpgn/pvpgn-1.99.7.2.1.ebuild
new file mode 100644
index 00000000000..3073d0158b6
--- /dev/null
+++ b/games-server/pvpgn/pvpgn-1.99.7.2.1.ebuild
@@ -0,0 +1,109 @@
+# Copyright 1999-2021 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+inherit cmake toolchain-funcs
+
+SUPPORTP="${PN}-support-1.3"
+DESCRIPTION="A gaming server for Battle.Net compatible clients"
+HOMEPAGE="https://pvpgn.pro"
+SRC_URI="https://github.com/pvpgn/pvpgn-server/archive/refs/tags/${PV}.tar.gz -> ${P}.tar.gz"
+S="${WORKDIR}/${PN}-server-${PV}"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE="mysql odbc postgres sqlite"
+
+DEPEND="
+ mysql? ( dev-db/mysql-connector-c:0= )
+ odbc? ( dev-db/libiodbc )
+ postgres? ( dev-db/postgresql[server] )
+ sqlite? ( dev-db/sqlite )
+"
+RDEPEND="
+ ${DEPEND}
+ acct-user/pvpgn
+ acct-group/pvpgn
+"
+
+PATCHES=(
+ #"${FILESDIR}"/${PN}-1.8.5-fhs.patch
+ "${FILESDIR}"/${PN}-1.99.7.2.1-path.patch
+)
+
+src_prepare() {
+ sed -i \
+ -e 's/-O3 -march=native -mtune=native//' \
+ -e 's/-stdlib=libc++//' \
+ CMakeLists.txt || die
+
+ cmake_src_prepare
+}
+
+src_configure() {
+ tc-export CC
+
+ local mycmakeargs=(
+ -DWITH_MYSQL=$(usex mysql)
+ -DWITH_ODBC=$(usex odbc)
+ -DWITH_PGSQL=$(usex postgres)
+ -DWITH_SQLITE3=$(usex sqlite)
+ )
+
+ cmake_src_configure
+}
+
+src_install() {
+ local f
+
+ cmake_src_install
+
+ dolib.so "${BUILD_DIR}"/src/compat/libcompat.so
+ dolib.so "${BUILD_DIR}"/src/common/libcommon.so
+
+ # Was: "GAMES_USER_DED here instead of GAMES_USER (bug #65423)"
+ for f in bnetd d2cs d2dbs ; do
+ newinitd "${FILESDIR}/${PN}.rc" ${f}
+
+ sed -i \
+ -e "s:NAME:${f}:g" \
+ -e "s:GAMES_BINDIR:/usr/bin:g" \
+ -e "s:GAMES_USER:pvpgn:g" \
+ -e "s:GAMES_GROUP:pvpgn:g" \
+ "${ED}/etc/${PN}/${f}.conf" \
+ "${ED}/etc/init.d/${f}" || die
+ done
+
+ keepdir $(find "${ED}/var/lib"/${PN} -type d -printf "/var/lib/${PN}/%P ") /var/lib/${PN}/log
+
+ keepdir /var/pvpgn/{bnmail,chanlogs,charinfo,charsave,clans,ladders}
+ keepdir /var/pvpgn/{reports,status,teams,userlogs,users,userscdb}
+ keepdir /var/pvpgn/bak/char{info,save}
+
+ chown -R pvpgn:pvpgn "${ED}/var/lib/${PN}" || die
+ fperms 0775 "/var/lib/${PN}/log"
+ fperms 0770 "/var/lib/${PN}"
+}
+
+pkg_postinst() {
+ elog "If this is a first installation you need to configure the package by"
+ elog "editing the configuration files provided in /etc/${PN}"
+ elog "Also you should read the documentation in /usr/share/docs/${PF}"
+ elog
+ elog "If you are upgrading you MUST read UPDATE in /usr/share/docs/${PF}"
+ elog "and update your configuration accordingly."
+
+ if use mysql ; then
+ elog
+ elog "You have enabled MySQL storage support. You will need to edit"
+ elog "bnetd.conf to use it. Read README.storage from the docs directory."
+ fi
+
+ if use postgres ; then
+ elog
+ elog "You have enabled PostgreSQL storage support. You will need to edit"
+ elog "bnetd.conf to use it. Read README.storage from the docs directory."
+ fi
+}
^ permalink raw reply related [flat|nested] 2+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: games-server/pvpgn/files/, games-server/pvpgn/
@ 2021-04-09 20:14 Sam James
0 siblings, 0 replies; 2+ messages in thread
From: Sam James @ 2021-04-09 20:14 UTC (permalink / raw
To: gentoo-commits
commit: 507647a276b58fcb7df7ff8ae973ea080e274913
Author: Sam James <sam <AT> gentoo <DOT> org>
AuthorDate: Fri Apr 9 20:13:14 2021 +0000
Commit: Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Fri Apr 9 20:14:23 2021 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=507647a2
games-server/pvpgn: port to EAPI 7, games.eclass--
Signed-off-by: Sam James <sam <AT> gentoo.org>
games-server/pvpgn/files/pvpgn-1.8.5-fhs.patch | 20 +++----
...pvpgn-1.8.5-r2.ebuild => pvpgn-1.8.5-r3.ebuild} | 64 +++++++++++++---------
2 files changed, 45 insertions(+), 39 deletions(-)
diff --git a/games-server/pvpgn/files/pvpgn-1.8.5-fhs.patch b/games-server/pvpgn/files/pvpgn-1.8.5-fhs.patch
index d1450b3ad17..f4238450c41 100644
--- a/games-server/pvpgn/files/pvpgn-1.8.5-fhs.patch
+++ b/games-server/pvpgn/files/pvpgn-1.8.5-fhs.patch
@@ -1,6 +1,5 @@
-diff -ruN pvpgn-1.8.0rc2.orig/conf/bnetd.conf.in pvpgn-1.8.0rc2/conf/bnetd.conf.in
---- pvpgn-1.8.0rc2.orig/conf/bnetd.conf.in 2005-09-19 08:17:50.000000000 -0400
-+++ pvpgn-1.8.0rc2/conf/bnetd.conf.in 2006-08-16 23:34:10.000000000 -0400
+--- a/conf/bnetd.conf.in
++++ b/conf/bnetd.conf.in
@@ -50,22 +50,22 @@
# - "prefix" : prefix to use for all pvpgn tables (default "") #
# #
@@ -94,9 +93,8 @@ diff -ruN pvpgn-1.8.0rc2.orig/conf/bnetd.conf.in pvpgn-1.8.0rc2/conf/bnetd.conf.
fortunecmd = /usr/games/fortune
-diff -ruN pvpgn-1.8.0rc2.orig/conf/d2cs.conf.in pvpgn-1.8.0rc2/conf/d2cs.conf.in
---- pvpgn-1.8.0rc2.orig/conf/d2cs.conf.in 2005-09-29 01:37:33.000000000 -0400
-+++ pvpgn-1.8.0rc2/conf/d2cs.conf.in 2006-08-16 23:35:43.000000000 -0400
+--- a/conf/d2cs.conf.in
++++ b/conf/d2cs.conf.in
@@ -86,16 +86,16 @@
# Use absolute paths in these lines to avoid problems! #
#-------------------------------------------------------------------------------#
@@ -124,9 +122,8 @@ diff -ruN pvpgn-1.8.0rc2.orig/conf/d2cs.conf.in pvpgn-1.8.0rc2/conf/d2cs.conf.in
# #
#################################################################################
-diff -ruN pvpgn-1.8.0rc2.orig/conf/d2dbs.conf.in pvpgn-1.8.0rc2/conf/d2dbs.conf.in
---- pvpgn-1.8.0rc2.orig/conf/d2dbs.conf.in 2005-08-24 23:58:18.000000000 -0400
-+++ pvpgn-1.8.0rc2/conf/d2dbs.conf.in 2006-08-16 23:36:58.000000000 -0400
+--- a/conf/d2dbs.conf.in
++++ b/conf/d2dbs.conf.in
@@ -49,14 +49,14 @@
# File and Path section #
# Use absolute paths in these lines to avoid problems! #
@@ -151,9 +148,8 @@ diff -ruN pvpgn-1.8.0rc2.orig/conf/d2dbs.conf.in pvpgn-1.8.0rc2/conf/d2dbs.conf.
# #
#################################################################################
-diff -ruN pvpgn-1.8.0rc2.orig/src/Makefile.in pvpgn-1.8.0rc2/src/Makefile.in
---- pvpgn-1.8.0rc2.orig/src/Makefile.in 2005-07-29 02:11:38.000000000 +0600
-+++ pvpgn-1.8.0rc2/src/Makefile.in 2005-09-23 15:10:02.968342144 +0600
+--- a/src/Makefile.in
++++ b/src/Makefile.in
@@ -23,22 +23,23 @@
bindir = @bindir@
sbindir = @sbindir@
diff --git a/games-server/pvpgn/pvpgn-1.8.5-r2.ebuild b/games-server/pvpgn/pvpgn-1.8.5-r3.ebuild
similarity index 61%
rename from games-server/pvpgn/pvpgn-1.8.5-r2.ebuild
rename to games-server/pvpgn/pvpgn-1.8.5-r3.ebuild
index 67ba4ceed17..924ace30c4a 100644
--- a/games-server/pvpgn/pvpgn-1.8.5-r2.ebuild
+++ b/games-server/pvpgn/pvpgn-1.8.5-r3.ebuild
@@ -1,8 +1,9 @@
-# Copyright 1999-2019 Gentoo Authors
+# Copyright 1999-2021 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
-EAPI=5
-inherit epatch games
+EAPI=7
+
+inherit toolchain-funcs
SUPPORTP="${PN}-support-1.3"
DESCRIPTION="A gaming server for Battle.Net compatible clients"
@@ -15,19 +16,28 @@ SLOT="0"
KEYWORDS="~amd64 ~x86"
IUSE="mysql postgres"
-DEPEND="mysql? ( dev-db/mysql-connector-c:0= )
- postgres? ( dev-db/postgresql[server] )"
-RDEPEND=${DEPEND}
+DEPEND="
+ mysql? ( dev-db/mysql-connector-c:0= )
+ postgres? ( dev-db/postgresql[server] )
+"
+RDEPEND="
+ ${DEPEND}
+ acct-user/pvpgn
+ acct-group/pvpgn
+"
-src_prepare() {
- epatch "${FILESDIR}/${P}-fhs.patch"
-}
+PATCHES=(
+ "${FILESDIR}"/${P}-fhs.patch
+)
src_configure() {
- cd src
- # everything in GAMES_BINDIR (bug #63071)
- egamesconf \
- --sbindir="${GAMES_BINDIR}" \
+ cd src || die
+
+ tc-export CC
+ # Was: "everything in GAMES_BINDIR (bug #63071)"
+ # Not anymore.
+ econf \
+ --sbindir="/usr/bin" \
$(use_with mysql) \
$(use_with postgres pgsql)
}
@@ -45,43 +55,43 @@ src_install() {
emake -C src DESTDIR="${D}" install
- insinto "${GAMES_DATADIR}/${PN}"
+ insinto /usr/share/${PN}
doins "${WORKDIR}/${SUPPORTP}/"*
- # GAMES_USER_DED here instead of GAMES_USER (bug #65423)
+ # Was: "GAMES_USER_DED here instead of GAMES_USER (bug #65423)"
for f in bnetd d2cs d2dbs ; do
newinitd "${FILESDIR}/${PN}.rc" ${f}
+
sed -i \
-e "s:NAME:${f}:g" \
- -e "s:GAMES_BINDIR:${GAMES_BINDIR}:g" \
- -e "s:GAMES_USER:${GAMES_USER_DED}:g" \
- -e "s:GAMES_GROUP:${GAMES_GROUP}:g" \
- "${D}/etc/games/${PN}/${f}.conf" \
+ -e "s:GAMES_BINDIR:/usr/bin:g" \
+ -e "s:GAMES_USER:pvpgn:g" \
+ -e "s:GAMES_GROUP:pvpgn:g" \
+ "${D}/etc/${PN}/${f}.conf" \
"${D}/etc/init.d/${f}" || die
done
- keepdir $(find "${D}${GAMES_STATEDIR}"/${PN} -type d -printf "${GAMES_STATEDIR}/${PN}/%P ") "${GAMES_STATEDIR}"/${PN}/log
- prepgamesdirs
+ keepdir $(find "${ED}/var/lib"/${PN} -type d -printf "/var/lib/${PN}/%P ") /var/lib/${PN}/log
- chown -R ${GAMES_USER_DED}:${GAMES_GROUP} "${D}${GAMES_STATEDIR}/${PN}"
- fperms 0775 "${GAMES_STATEDIR}/${PN}/log"
- fperms 0770 "${GAMES_STATEDIR}/${PN}"
+ chown -R pvpgn:pvpgn "${ED}/var/lib/${PN}" || die
+ fperms 0775 "/var/lib/${PN}/log"
+ fperms 0770 "/var/lib/${PN}"
}
pkg_postinst() {
- games_pkg_postinst
-
elog "If this is a first installation you need to configure the package by"
- elog "editing the configuration files provided in ${GAMES_SYSCONFDIR}/${PN}"
+ elog "editing the configuration files provided in /etc/${PN}"
elog "Also you should read the documentation in /usr/share/docs/${PF}"
elog
elog "If you are upgrading you MUST read UPDATE in /usr/share/docs/${PF}"
elog "and update your configuration accordingly."
+
if use mysql ; then
elog
elog "You have enabled MySQL storage support. You will need to edit"
elog "bnetd.conf to use it. Read README.storage from the docs directory."
fi
+
if use postgres ; then
elog
elog "You have enabled PostgreSQL storage support. You will need to edit"
^ permalink raw reply related [flat|nested] 2+ messages in thread
end of thread, other threads:[~2021-04-09 21:47 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2021-04-09 21:47 [gentoo-commits] repo/gentoo:master commit in: games-server/pvpgn/files/, games-server/pvpgn/ Sam James
-- strict thread matches above, loose matches on Subject: below --
2021-04-09 20:14 Sam James
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox