net-p2p/deluge: sync live ebuild
authorPPed72 <paolo.pedroni@iol.it>
Wed, 9 Mar 2016 10:39:51 +0000 (11:39 +0100)
committerPatrice Clement <monsieurp@gentoo.org>
Thu, 10 Mar 2016 10:18:34 +0000 (10:18 +0000)
This series of commits closes #1010.

Pull-Request: https://github.com/gentoo/gentoo/pull/1010
Gentoo-Bug: https://bugs.gentoo.org/566806
Signed-off-by: Patrice Clement <monsieurp@gentoo.org>
net-p2p/deluge/deluge-9999.ebuild

index 41f5ba8550a077f26812d936c94e62e8270b2054..579b78ef727a9c6a67936cbaba39842d539ff9b8 100644 (file)
@@ -6,7 +6,7 @@ EAPI="5"
 
 PYTHON_COMPAT=( python2_7 )
 DISTUTILS_SINGLE_IMPL=1
-inherit distutils-r1 eutils systemd
+inherit distutils-r1 eutils systemd user
 
 DESCRIPTION="BitTorrent client with a client/server model"
 HOMEPAGE="http://deluge-torrent.org/"
@@ -48,7 +48,7 @@ RDEPEND=">=net-libs/rb_libtorrent-0.14.9[python]
        webinterface? ( dev-python/mako[${PYTHON_USEDEP}] )"
 
 python_prepare_all() {
-# Not needed anymore: bug #518354
+#Not needed anymore: bug #518354
 #      local PATCHES=(
 #              "${FILESDIR}"/${PN}-1.3.5-disable_libtorrent_internal_copy.patch
 #      )
@@ -69,11 +69,15 @@ python_install_all() {
        newconfd "${FILESDIR}"/deluged.conf-2 deluged
        newinitd "${FILESDIR}"/deluge-web.init deluge-web
        newconfd "${FILESDIR}"/deluge-web.conf deluge-web
-       systemd_dounit "${FILESDIR}"/deluged.service
-       systemd_dounit "${FILESDIR}"/deluge-web.service
+       systemd_newunit "${FILESDIR}"/deluged.service-2 deluged.service
+       systemd_newunit "${FILESDIR}"/deluge-web.service-2 deluge-web.service
+       systemd_install_serviced "${FILESDIR}"/deluged.service.conf
+       systemd_install_serviced "${FILESDIR}"/deluge-web.service.conf
 }
 
 pkg_postinst() {
+       enewgroup ${PN}
+       enewuser ${PN} -1 -1 /var/lib/${PN} ${PN}
        elog
        elog "If after upgrading it doesn't work, please remove the"
        elog "'~/.config/deluge' directory and try again, but make a backup"
@@ -84,6 +88,11 @@ pkg_postinst() {
        elog "/etc/init.d/deluged start as root"
        elog "You can still use deluge the old way"
        elog
+       elog "Systemd unit files for deluged and deluge-web no longer source"
+       elog "/etc/conf.d/deluge* files. Environment variable customization now"
+       elog "happens in /etc/systemd/system/deluged.service.d/00gentoo.conf"
+       elog "and /etc/systemd/system/deluge-web.service.d/00gentoo.conf"
+       elog
        elog "For more information look at http://dev.deluge-torrent.org/wiki/Faq"
        elog
 }