This repository has been archived by the owner. It is now read-only.
Permalink
Browse files

add deluge-1.3.5

  • Loading branch information...
11mariom committed Apr 12, 2012
1 parent ecbbbd2 commit 864086cb539675190f5a06fb74c9408635e472f5
View
@@ -0,0 +1,4 @@
+AUX deluged.conf 184 RMD160 f1721fcc20b77836c783cbe4e7492748902f0428 SHA1 e330df742ae8f21e7dfbbaa31f181279ef96e3b8 SHA256 9f686931e7f5c337d4866d91ae725b0a983ee2a409eee69a197e7db8e4bc2b3d
+AUX deluged.init 2053 RMD160 bbac1a15daa68a6f47c6a80a203189d7d26fabca SHA1 895d247a428f6417abb7463402b6883ddef3975c SHA256 04cacfadc79e738d8cccc4de6ffe735697c01e17c0e96d9604b7018e68c8a9a3
+DIST deluge-1.3.5.tar.lzma 2100244 RMD160 35c3b72d8ffc33717791f8be4ca07d50350e1621 SHA1 26eb8c60f9dfdf77be02369fc8c996d09d5bd909 SHA256 cdb97fd64cc2131da812fad026f49e82f82b6a214e592222145ddcfb19174247
+EBUILD deluge-1.3.5.ebuild 1901 RMD160 4b326ceee760949b69954ffef88112291cacc23e SHA1 0172facbd2cfa79df183866839bb3e0818228524 SHA256 27f42312e6692610a80d17d27ec36bc1a9f9af288838060ac1ea38402196b998
@@ -0,0 +1,73 @@
+# Copyright 1999-2011 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/net-p2p/deluge/deluge-1.3.3.ebuild,v 1.5 2011/10/24 06:34:50 tetromino Exp $
+
+EAPI="3"
+PYTHON_DEPEND="2:2.5"
+
+inherit distutils flag-o-matic
+
+DESCRIPTION="BitTorrent client with a client/server model."
+HOMEPAGE="http://deluge-torrent.org/"
+SRC_URI="http://download.deluge-torrent.org/source/${P}.tar.lzma"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~arm ~ppc ~sparc ~x86"
+IUSE="geoip gtk libnotify setproctitle webinterface"
+
+DEPEND=">=net-libs/rb_libtorrent-0.14.9[python]
+ dev-python/setuptools
+ dev-util/intltool"
+RDEPEND="${DEPEND}
+ dev-python/chardet
+ dev-python/pyopenssl
+ dev-python/pyxdg
+ || ( dev-lang/python:2.7 dev-lang/python:2.6 dev-python/simplejson )
+ >=dev-python/twisted-8.1
+ >=dev-python/twisted-web-8.1
+ geoip? (
+ dev-libs/geoip
+ )
+ gtk? (
+ dev-python/pygame
+ dev-python/pygobject:2
+ >=dev-python/pygtk-2.12
+ gnome-base/librsvg
+ libnotify? ( dev-python/notify-python )
+ )
+ setproctitle? ( dev-python/setproctitle )
+ webinterface? ( dev-python/mako )"
+
+pkg_setup() {
+ append-ldflags $(no-as-needed)
+ python_set_active_version 2
+ python_pkg_setup
+}
+
+src_prepare() {
+ distutils_src_prepare
+ python_convert_shebangs -r 2 .
+}
+
+src_install() {
+ distutils_src_install
+ newinitd "${FILESDIR}"/deluged.init deluged
+ newconfd "${FILESDIR}"/deluged.conf deluged
+}
+
+pkg_postinst() {
+ distutils_pkg_postinst
+ elog
+ elog "If after upgrading it doesn't work, please remove the"
+ elog "'~/.config/deluge' directory and try again, but make a backup"
+ elog "first!"
+ elog
+ elog "To start the daemon either run 'deluged' as user"
+ elog "or modify /etc/conf.d/deluged and run"
+ elog "/etc/init.d/deluged start as root"
+ elog "You can still use deluge the old way"
+ elog
+ elog "For more information look at http://dev.deluge-torrent.org/wiki/Faq"
+ elog
+}
@@ -0,0 +1,7 @@
+# /etc/conf.d/deluged
+# Change this to the user you want to run deluged as.
+# You may specify a group too, after a colon
+DELUGED_USER=""
+DELUGEUI_START="false"
+DELUGEUI_OPTS="-u web"
+
@@ -0,0 +1,71 @@
+#!/sbin/runscript
+# Copyright 1999-2011 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License, v2 or later
+# $Header: /var/cvsroot/gentoo-x86/net-p2p/deluge/files/deluged.init,v 1.10 2011/09/21 14:56:39 armin76 Exp $
+
+depend() {
+ need net
+}
+
+checkconfig() {
+ if [ "${DELUGED_USER}" = "" ] ; then
+ eerror "Please edit /etc/conf.d/deluged"
+ eerror "You have to specify a user to run deluged as, as we will not run it as root!"
+ eerror "Modify DELUGED_USER to your needs (you can also add a group, after a colon)"
+ return 1
+ fi
+ if ! getent passwd "${DELUGED_USER%:*}" >/dev/null ; then
+ eerror "Please edit /etc/conf.d/deluged"
+ eerror "Your user has to exist!"
+ return 1
+ fi
+ if [ "${DELUGED_USER%:*}" = "${DELUGED_USER}" ] ; then
+ return 0
+ else
+ if ! getent group "${DELUGED_USER#*:}" >/dev/null ; then
+ eerror "Please edit /etc/conf.d/deluged"
+ eerror "Your group has to exist too!"
+ return 1
+ fi
+ fi
+ return 0
+}
+
+start() {
+ checkconfig || return $?
+ if [ "${DELUGED_HOME}" = "" ] ; then
+ DELUGED_USER_HOME=$(getent passwd "${DELUGED_USER%:*}" | cut -d ':' -f 6)
+ else
+ DELUGED_USER_HOME=${DELUGED_HOME}
+ fi
+ ebegin "Starting Deluged"
+ start-stop-daemon --start --user "${DELUGED_USER%:*}" \
+ --name deluged --pidfile /var/run/deluged.pid --background --make-pidfile \
+ --exec /usr/bin/deluged -e HOME=${DELUGED_USER_HOME} -- --do-not-daemonize "${DELUGED_OPTS}"
+ eend $?
+
+
+ if [ "${DELUGEUI_START}" = "true" ] ; then
+ ebegin "Starting Deluge"
+ start-stop-daemon --start --background --pidfile \
+ /var/run/deluge.pid --make-pidfile \
+ --exec /usr/bin/deluge --user "${DELUGED_USER%:*}" \
+ -e HOME="${DELUGED_USER_HOME}" -- ${DELUGEUI_OPTS}
+ eend $?
+ fi
+}
+
+stop() {
+ ebegin "Stopping Deluged"
+ start-stop-daemon --stop --user "${DELUGED_USER%:*}" \
+ --name deluged --pidfile /var/run/deluged.pid
+ eend $?
+
+
+ if [ "${DELUGEUI_START}" = "true" ] ; then
+ ebegin "Stopping Deluge"
+ start-stop-daemon --stop --user "${DELUGED_USER%:*}" \
+ --name deluge --pidfile /var/run/deluge.pid
+ eend $?
+ fi
+}

0 comments on commit 864086c

Please sign in to comment.