From: "Kenton Groombridge" <concord@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] repo/gentoo:master commit in: net-voip/murmur/files/, net-voip/murmur/
Date: Fri,  9 Feb 2024 14:41:51 +0000 (UTC)	[thread overview]
Message-ID: <1707489648.cdf97e00d9cc8120deb8ed2e00589d56ce26adc5.concord@gentoo> (raw)
commit:     cdf97e00d9cc8120deb8ed2e00589d56ce26adc5
Author:     Sebastian Parborg <darkdefende <AT> gmail <DOT> com>
AuthorDate: Wed May 31 17:49:43 2023 +0000
Commit:     Kenton Groombridge <concord <AT> gentoo <DOT> org>
CommitDate: Fri Feb  9 14:40:48 2024 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=cdf97e00
net-voip/murmur: update live ebuild
Signed-off-by: Sebastian Parborg <darkdefende <AT> gmail.com>
Signed-off-by: Kenton Groombridge <concord <AT> gentoo.org>
 net-voip/murmur/files/murmur.confd-r2 |   9 +++
 net-voip/murmur/murmur-9999.ebuild    | 113 +++++++++++++++-------------------
 2 files changed, 58 insertions(+), 64 deletions(-)
diff --git a/net-voip/murmur/files/murmur.confd-r2 b/net-voip/murmur/files/murmur.confd-r2
new file mode 100644
index 000000000000..c8d3230b9974
--- /dev/null
+++ b/net-voip/murmur/files/murmur.confd-r2
@@ -0,0 +1,9 @@
+# where to look for the config file
+MURMUR_CONF=/etc/murmur/mumble-server.ini
+
+# run as this user
+MURMUR_USER=murmur
+
+# HOME directory of MURMUR_USER
+MURMUR_HOME=/var/lib/murmur
+
diff --git a/net-voip/murmur/murmur-9999.ebuild b/net-voip/murmur/murmur-9999.ebuild
index 767d7a494eb3..b5d57c5bea38 100644
--- a/net-voip/murmur/murmur-9999.ebuild
+++ b/net-voip/murmur/murmur-9999.ebuild
@@ -1,4 +1,4 @@
-# Copyright 1999-2022 Gentoo Authors
+# Copyright 1999-2024 Gentoo Authors
 # Distributed under the terms of the GNU General Public License v2
 
 EAPI=7
@@ -10,7 +10,20 @@ HOMEPAGE="https://wiki.mumble.info"
 if [[ "${PV}" == 9999 ]] ; then
 	inherit git-r3
 	EGIT_REPO_URI="https://github.com/mumble-voip/mumble.git"
-	EGIT_SUBMODULES=( '-*' 3rdparty/FindPythonInterpreter 3rdparty/gsl 3rdparty/tracy )
+
+	# needed for the included 3rdparty license script,
+	# even if these components may not be compiled in
+	EGIT_SUBMODULES=(
+		'-*'
+		3rdparty/cmake-compiler-flags
+		3rdparty/FindPythonInterpreter
+		3rdparty/gsl
+		3rdparty/minhook
+		3rdparty/opus
+		3rdparty/rnnoise-src
+		3rdparty/speexdsp
+		3rdparty/tracy
+	)
 else
 	MY_PN="mumble"
 	if [[ "${PV}" == *_pre* ]] ; then
@@ -29,7 +42,7 @@ fi
 
 LICENSE="BSD"
 SLOT="0"
-IUSE="+dbus grpc +ice test zeroconf"
+IUSE="+ice test zeroconf"
 RESTRICT="!test? ( test )"
 
 RDEPEND="
@@ -38,6 +51,7 @@ RDEPEND="
 	>=dev-libs/openssl-1.0.0b:0=
 	>=dev-libs/protobuf-2.2.0:=
 	dev-qt/qtcore:5
+	dev-qt/qtdbus:5
 	dev-qt/qtnetwork:5[ssl]
 	|| (
 		dev-qt/qtsql:5[sqlite]
@@ -46,8 +60,6 @@ RDEPEND="
 	dev-qt/qtxml:5
 	sys-apps/lsb-release
 	>=sys-libs/libcap-2.15
-	dbus? ( dev-qt/qtdbus:5 )
-	grpc? ( net-libs/grpc )
 	ice? ( dev-libs/Ice:= )
 	zeroconf? ( net-dns/avahi[mdnsresponder-compat] )
 "
@@ -62,58 +74,43 @@ BDEPEND="
 	virtual/pkgconfig
 "
 
-if [[ "${PV}" == *9999 ]] ; then
-	# Required for the mkini.sh script which calls perl multiple times
-	BDEPEND+="
-		dev-lang/perl
-	"
-fi
-
+DISABLE_AUTOFORMATTING="yes"
 DOC_CONTENTS="
-	Useful scripts are located in /usr/share/doc/${PF}/scripts.\n
-	Please execute:\n
-	murmurd -ini /etc/murmur/murmur.ini -supw <pw>\n
-	chown murmur:murmur /var/lib/murmur/murmur.sqlite\n
-	to set the build-in 'SuperUser' password before starting murmur.
-	Please restart dbus before starting murmur, or else dbus
-	registration will fail.
+The default 'SuperUser' password will be written into the log file
+when starting murmur for the first time.
+
+If you want to manually set a password yourself, please execute:
+su murmur -s /bin/bash -c 'mumble-server -ini /etc/murmur/mumble-server.ini -supw <pw>'
+
+This will set the built-in 'SuperUser' password to '<pw>' when starting murmur.
 "
 
 src_prepare() {
-	if [[ "${PV}" == *9999 ]] ; then
-		pushd scripts &>/dev/null || die
-		./mkini.sh || die
-		popd &>/dev/null || die
-	fi
-
+	# Adjust default server settings to be correct for our default setup
 	sed \
-		-e 's:mumble-server:murmur:g' \
-		-e 's:/var/run:/run:g' \
-		-i "${S}"/scripts/murmur.{conf,ini} || die
+		-e 's:database=:database=/var/lib/murmur/database.sqlite:' \
+		-e 's:;logfile=mumble-server.log:logfile=/var/log/murmur/murmur.log:' \
+		-e 's:;pidfile=:pidfile=/run/murmur/murmur.pid:' \
+		-i auxiliary_files/mumble-server.ini || die
 
-	# Adjust systemd service file to our config location #689208
-	sed \
-		-e "s@/etc/${PN}\.ini@/etc/${PN}/${PN}.ini@" \
-		-e "s@murmurd@mumble-server@" \
-		-i scripts/${PN}.service || die
+	# Replace the default group and user _mumble-server with murmur
+	grep -r -l _mumble-server auxiliary_files/ | xargs sed -i 's/_mumble-server/murmur/g' || die
 
 	cmake_src_prepare
 }
 
 src_configure() {
-	myuse() {
-		[[ -n "${1}" ]] || die "myconf: No use flag given."
-		use ${1} || echo "no-${1}"
-	}
 	local mycmakeargs=(
 		-DBUILD_TESTING="$(usex test)"
 		-Dclient="OFF"
-		-Ddbus="$(usex dbus)"
 		-Dg15="OFF"
-		-Dgrpc="$(usex grpc)"
 		-Dice="$(usex ice)"
+		-DMUMBLE_INSTALL_SYSCONFDIR="/etc/murmur"
 		-Doverlay="OFF"
 		-Dserver="ON"
+		-DMUMBLE_INSTALL_SERVICEFILEDIR=$(systemd_get_systemunitdir)
+		-DMUMBLE_INSTALL_SYSUSERSDIR=$(systemd_get_userunitdir)
+		-DMUMBLE_INSTALL_TMPFILESDIR="/usr/lib/tmpfiles.d"
 		-Dzeroconf="$(usex zeroconf)"
 	)
 	if [[ "${PV}" != 9999 ]] ; then
@@ -132,44 +129,32 @@ src_install() {
 
 	dodoc README.md
 
-	docinto scripts
-	dodoc -r scripts/server
-	docompress -x /usr/share/doc/${PF}/scripts
-
-	local etcdir="/etc/murmur"
-	insinto ${etcdir}
-	doins scripts/${PN}.ini
-
 	insinto /etc/logrotate.d/
 	newins "${FILESDIR}"/murmur.logrotate murmur
 
-	insinto /etc/dbus-1/system.d/
-	doins scripts/murmur.conf
+	# Copy over the initd file so we can modify it incase zeroconf support is on.
+	cp "${FILESDIR}"/murmur.initd-r2 "${T}"/murmur.initd || die
 
-	insinto /usr/share/murmur/
-	doins src/murmur/Murmur.ice
-
-	newinitd "${FILESDIR}"/murmur.initd-r2 murmur
-	newconfd "${FILESDIR}"/murmur.confd murmur
+	if use zeroconf; then
+		sed -e 's:need:need avahi-daemon:' -i "${T}"/murmur.initd || die
+	fi
 
-	systemd_dounit scripts/${PN}.service
-	newtmpfiles "${FILESDIR}"/murmurd-dbus.tmpfiles "${PN}".conf
+	newinitd "${T}"/murmur.initd murmur
+	newconfd "${FILESDIR}"/murmur.confd-r2 murmur
 
 	keepdir /var/lib/murmur /var/log/murmur
 	fowners -R murmur /var/lib/murmur /var/log/murmur
 	fperms 750 /var/lib/murmur /var/log/murmur
 
-	# Fix permissions on config file as it might contain passwords.
-	# (bug #559362)
-	fowners root:murmur ${etcdir}/murmur.ini
-	fperms 640 ${etcdir}/murmur.ini
-
-	newman man/mumble-server.1 murmurd.1
-
 	readme.gentoo_create_doc
 }
 
 pkg_postinst() {
-	tmpfiles_process ${PN}.conf
+	tmpfiles_process mumble-server.conf
 	readme.gentoo_print_elog
+
+	if use zeroconf; then
+		elog "To turn on the zeroconf functionality, you need to uncomment and"
+		elog "change the 'bonjour=false' setting in mumble-server.ini to 'true'"
+	fi
 }
next             reply	other threads:[~2024-02-09 14:41 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-02-09 14:41 Kenton Groombridge [this message]
  -- strict thread matches above, loose matches on Subject: below --
2024-08-30 13:11 [gentoo-commits] repo/gentoo:master commit in: net-voip/murmur/files/, net-voip/murmur/ Andreas Sturmlechner
2024-10-07  3:27 Eli Schwartz
2025-05-04 17:38 Kenton Groombridge
2025-09-22 21:47 Kenton Groombridge
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox
  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):
  git send-email \
    --in-reply-to=1707489648.cdf97e00d9cc8120deb8ed2e00589d56ce26adc5.concord@gentoo \
    --to=concord@gentoo.org \
    --cc=gentoo-commits@lists.gentoo.org \
    --cc=gentoo-dev@lists.gentoo.org \
    /path/to/YOUR_REPLY
  https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
  Be sure your reply has a Subject: header at the top and a blank line
  before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox