summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarcin Kryczek <mkay@gentoo.org>2005-10-20 23:41:06 +0000
committerMarcin Kryczek <mkay@gentoo.org>2005-10-20 23:41:06 +0000
commitea8bd5f23acf58705ec7d4c9f441a6899e627a79 (patch)
treef1b53a4d9709ab14a6e8c40f717a577cee69c658 /net-p2p
parentAdded optional Octave support, avoid access violations (fixes bug #109684). (diff)
downloadhistorical-ea8bd5f23acf58705ec7d4c9f441a6899e627a79.tar.gz
historical-ea8bd5f23acf58705ec7d4c9f441a6899e627a79.tar.bz2
historical-ea8bd5f23acf58705ec7d4c9f441a6899e627a79.zip
Updated start script (and configuration in conf.d). This fixes bug #109469 and bug #109604
Package-Manager: portage-2.0.52-r1
Diffstat (limited to 'net-p2p')
-rw-r--r--net-p2p/mldonkey/ChangeLog6
-rw-r--r--net-p2p/mldonkey/Manifest6
-rw-r--r--net-p2p/mldonkey/files/mldonkey.confd7
-rw-r--r--net-p2p/mldonkey/files/mldonkey.initd46
4 files changed, 32 insertions, 33 deletions
diff --git a/net-p2p/mldonkey/ChangeLog b/net-p2p/mldonkey/ChangeLog
index f12dd59dbade..d78eb4db9b61 100644
--- a/net-p2p/mldonkey/ChangeLog
+++ b/net-p2p/mldonkey/ChangeLog
@@ -1,6 +1,10 @@
# ChangeLog for net-p2p/mldonkey
# Copyright 2002-2005 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/net-p2p/mldonkey/ChangeLog,v 1.103 2005/10/15 10:14:10 mkay Exp $
+# $Header: /var/cvsroot/gentoo-x86/net-p2p/mldonkey/ChangeLog,v 1.104 2005/10/20 23:41:06 mkay Exp $
+
+ 20 Oct 2005; <mkay@gentoo.org> files/mldonkey.confd, files/mldonkey.initd:
+ Updated start script (and configuration in conf.d). This fixes bug #109469
+ and bug #109604
15 Oct 2005; <mkay@gentoo.org> mldonkey-2.6.0.ebuild,
mldonkey-2.6.0-r1.ebuild:
diff --git a/net-p2p/mldonkey/Manifest b/net-p2p/mldonkey/Manifest
index 2931a56befc6..ed9b359e9303 100644
--- a/net-p2p/mldonkey/Manifest
+++ b/net-p2p/mldonkey/Manifest
@@ -1,4 +1,4 @@
-MD5 d0d61eb5543d4932980caf263b667231 ChangeLog 17287
+MD5 589acdd625e0eedb1e0d08575dd40558 ChangeLog 17460
MD5 ee159929f3e247f937fe88bb1919d8bd metadata.xml 242
MD5 1c9c6bded549ef569052d0f75fafb019 mldonkey-2.6.5.ebuild 4979
MD5 a92ec1a9e1c381c49b544c81221a8bd0 mldonkey-2.5.16-r9.ebuild 2660
@@ -13,12 +13,12 @@ MD5 b1c7f6fe232921bb9516c1007f34efd4 files/digest-mldonkey-2.5.16-r9 128
MD5 f145ba120c09f53b0032ea8b3f930128 files/digest-mldonkey-2.5.21-r2 126
MD5 eed52b2efc88d5b19ac43a6f4eeb5af7 files/digest-mldonkey-2.6.5 144
MD5 2db375201ae817eaa7075507d9700eed files/digest-mldonkey-2.6.0 68
+MD5 0308db20eac32dd62c1519106c6809a7 files/mldonkey.confd 770
MD5 ac93ed074d62909b2a496045f0740127 files/mldonkey 336
MD5 be0c71929c461b50601e8715706a4a16 files/mldonkey-2.5.16-configure.patch 540
MD5 be0c71929c461b50601e8715706a4a16 files/mldonkey-2.5.21-configure.patch 540
MD5 05622542c4f7a93553ab90d66f871b2d files/mldonkey-2.6.0-gtk2-gentoo.patch 497
MD5 93e16748ad44af182177978057266aa7 files/mldonkey-gui.desktop 263
-MD5 476ec69e79e7c93a7bdaa6cb049c0857 files/mldonkey.confd 836
-MD5 51820a1f1d6520039308f7a329403435 files/mldonkey.initd 3019
+MD5 49ad037d9b03c4bd6ace86263027c4c3 files/mldonkey.initd 3047
MD5 855aedd7fba1ffe74d7f6c0bce98f45f files/mldonkey.png 6835
MD5 9613def727af8826277e993290216c36 files/digest-mldonkey-2.6.4-r1 144
diff --git a/net-p2p/mldonkey/files/mldonkey.confd b/net-p2p/mldonkey/files/mldonkey.confd
index 51f53d34db3d..d2a94796b999 100644
--- a/net-p2p/mldonkey/files/mldonkey.confd
+++ b/net-p2p/mldonkey/files/mldonkey.confd
@@ -8,11 +8,8 @@
# owner of mlnet process (don't change, must be existing)
USER="p2p"
-# home dir of owner (don't change, must be existing)
-BASEDIR="/home/p2p"
-
-# subdir if any (will be created, if not existing)
-SUBDIR=".mldonkey"
+# mldonkey's working dir (must be existing)
+MLDONKEY_DIR="/home/p2p/mldonkey"
# logfile (/dev/null for nowhere)
LOG="/var/log/mldonkey.log"
diff --git a/net-p2p/mldonkey/files/mldonkey.initd b/net-p2p/mldonkey/files/mldonkey.initd
index b86a7360f10f..75d1cc739c31 100644
--- a/net-p2p/mldonkey/files/mldonkey.initd
+++ b/net-p2p/mldonkey/files/mldonkey.initd
@@ -7,37 +7,35 @@ depend() {
}
start() {
- result=0
ebegin "Starting mldonkey"
- if [ ! -d ${BASEDIR}/${SUBDIR} ]
- then
- einfo "Directory ${BASEDIR}/${SUBDIR} not existing, trying to create..."
- if [ ! -d ${BASEDIR} ]
- then
- mkdir -p ${BASEDIR}
- chown ${USER}:users ${BASEDIR}
- if [ ! -d ${BASEDIR} ]
- then
- eerror "Directory ${BASEDIR} could not be created!"
- result=$(( ${result} + 1 ))
- fi
- fi
- su ${USER} -c "mkdir ${BASEDIR}/${SUBDIR}"
- if [ ! -d ${BASEDIR}/${SUBDIR} ]
- then
- eerror "Directory ${BASEDIR}/${SUBDIR} could not be created!"
- result=$(( ${result} + 1 ))
+ result=0
+
+ if [ -z "${MLDONKEY_DIR}" ]; then
+ ewarn "mldonkey's start script has been changed. You should remove"
+ ewarn "BASEDIR and SUBDIR from /etc/conf.d/mldonkey and set MLDONKEY_DIR"
+ ewarn "to corect value (you propably want MLDONKEY_DIR=${BASEDIR}/${SUBDIR}"
+ MLDONKEY_DIR=${BASEDIR}/${SUBDIR}
+ einfo "Using ${MLDONKEY_DIR} as working directory"
+ fi
+
+ if [ ! -d ${MLDONKEY_DIR} ]; then
+ einfo "Directory ${MLDONKEY_DIR} not existing, trying to create..."
+ if `mkdir -p ${MLDONKEY_DIR} 2>/dev/null`; then
+ chown ${USER}:users ${MLDONKEY_DIR}
+ else
+ eerror "Directory ${MLDONKEY_DIR} could not be created!"
+ ((result++))
fi
- einfo "...ok!"
fi
- cd ${BASEDIR}/${SUBDIR}/
- env HOME=${BASEDIR} start-stop-daemon --quiet --start -c ${USER} \
- --nicelevel ${NICE} -x /usr/bin/mlnet &>${LOG} &
+
+ cd ${MLDONKEY_DIR}
+ env MLDONKEY_DIR=${MLDONKEY_DIR} start-stop-daemon --quiet --start \
+ -c ${USER} -N ${NICE} -x /usr/bin/mlnet &>${LOG} &
sleep 5
if ! pgrep -u ${USER} mlnet >/dev/null
then
eerror "MLDonkey could not be started! Check logfile: ${LOG}"
- result=$(( ${result} + 1 ))
+ ((result++))
fi
eend $result
}