View previous topic :: View next topic |
Author |
Message |
Aphex3K Apprentice
Joined: 18 Nov 2003 Posts: 182 Location: Germany
|
Posted: Sun Mar 20, 2005 1:11 am Post subject: new selfmade mldonkey ebuild |
|
|
Hey Folks, i am using mldonkey p2p-client and the last updates of portage to this software have been quite some time ago. So I took an old ebuild and modified it a bit to install the latest version of mldonkey from source. (2.5.30c) As the C is not convinient to portage naming conventions i called the version mldonkey-2.5.30-r1.
Code: |
# $Header: /var/cvsroot/gentoo-x86/net-p2p/mldonkey/mldonkey-2.5.30-r1.ebuild,v 1.1 2005/03/20 02:25:00 aphex3k Exp $
inherit eutils
IUSE="gtk gtk2"
PATCHPACK="patch_pack30c.gz"
DESCRIPTION="mldonkey is a new client to access the eDonkey network. It is written in Objective-Caml, and comes with its own GTK GUI, an HTTP interface and a telnet interface."
HOMEPAGE="http://www.nongnu.org/mldonkey/"
SRC_URI="http://download.berlios.de/pub/mldonkey/spiralvoice/cvs/${P}.tar.bz2
http://download.berlios.de/pub/mldonkey/spiralvoice/patchpacks/${PATCHPACK}"
LICENSE="GPL-2"
SLOT="0"
KEYWORDS="~x86 ~ppc ~alpha ~ia64 ~amd64"
RDEPEND=">=dev-lang/ocaml-3.08
dev-lang/perl
net-misc/wget
gtk? ( !gtk2? ( =dev-ml/lablgtk-1.2.7* ) )
gtk? ( gtk2? ( >=dev-ml/lablgtk-2.4 ) )"
DEPEND="${RDEPEND}
>=sys-devel/autoconf-2.58"
MLUSER="p2p"
src_unpack() {
unpack ${P}.tar.bz2
cd ${S}
epatch ${DISTDIR}/${PATCHPACK}
#use gtk || epatch ${FILESDIR}/${PV}-conf.patch
export WANT_AUTOCONF=2.5
cd config; autoconf; cd ..
}
src_compile() {
use gtk || export GTK_CONFIG="no"
# the dirs are not (yet) used, but it doesn't hurt to specify them anyway
econf \
--sysconfdir=/etc/mldonkey \
--sharedstatedir=/var/mldonkey \
--localstatedir=/var/mldonkey \
--enable-batch \
--enable-checks \
--enable-pthread \
`use_enable gtk2` || die
export OCAMLRUNPARAM="l=256M"
emake || die
}
src_install() {
dobin mlnet
use gtk && dobin mlchat mlgui mlguistarter mlim mlnet+gui
dobin ${FILESDIR}/mldonkey
dodoc ChangeLog Copying.txt Developers.txt Install.txt
cd ${S}/distrib
dodoc ChangeLog Authors.txt Bugs.txt Copying.txt Developers.txt Install.txt Readme.txt Todo.txt ed2k_links.txt
dohtml FAQ.html
insinto /usr/share/doc/${PF}/scripts
doins kill_mldonkey mldonkey_command mldonkey_previewer
insinto /usr/share/doc/${PF}/distrib
doins directconnect.ini
cd ${S}/docs
dodoc *.txt *.tex *.pdf
dohtml *.html
cd ${S}/docs/developers
dodoc *.txt *.tex
cd ${S}/docs/images
insinto /usr/share/doc/${PF}/html/images
doins *
insinto /etc/conf.d; newins ${FILESDIR}/mldonkey.confd mldonkey
exeinto /etc/init.d; newexe ${FILESDIR}/mldonkey.initd mldonkey
}
pkg_preinst() {
enewuser ${MLUSER} -1 /bin/bash /home/p2p users
}
pkg_postinst() {
echo
einfo "Running \`mldonkey' will start the server inside ~/.mldonkey/"
einfo "If you want to start mldonkey in a particular working directory,"
einfo "use the \`mlnet' command."
einfo "If you want to start mldonkey as a system service, use"
einfo "the /etc/init.d/mldonkey script. To control bandwidth, use"
einfo "the 'slow' and 'fast' arguments. Be sure to have a look at"
einfo "/etc/conf.d/mldonkey also."
echo
}
| copy this file to your /usr/portage/net-p2p/mldonkey/ directory and run Code: | ebuild mldonkey-2.5.30-r1.ebuild digest
| After that, you need to modify package masking. Code: | echo "=net-p2p/mldonkey-2.5.30-r1 ~x86" >> /etc/portage/package.keywords
| and Code: | echo "=net-p2p/mldonkey-2.5.30-r1" >> /etc/portage/package.unmask |
Now the package can be emerged by executing Code: | emerge =net-p2p/mldonkey-2.5.30-r1 | but i suggest this build as unstable and therefor it should stay masked!
There ist one drawback about the line Code: | #use gtk || epatch ${FILESDIR}/${PV}-conf.patch | where i could not figure out what it does exactly. The ebuild works for me so if somebody could give help me with that I appriciate this. I compile this ebuild with --disbale-gui --disable-multinet so i can not say anything about problems related to those configure flags. _________________ managing a server running gentoo... |
|
Back to top |
|
|
Maedhros Bodhisattva
Joined: 14 Apr 2004 Posts: 5511 Location: Durham, UK
|
Posted: Sun Mar 20, 2005 9:04 am Post subject: |
|
|
Moved from Portage & Programming. _________________ No-one's more important than the earthworm. |
|
Back to top |
|
|
jbpros Tux's lil' helper
Joined: 05 May 2004 Posts: 133 Location: Brussels, Belgium
|
Posted: Wed Mar 23, 2005 8:58 am Post subject: |
|
|
I'm trying your ebuild right now but I would like to insist about one thing: custom ebuilds should be placed within the portage overlay directory, not in the official portage directory.
My 2 cents |
|
Back to top |
|
|
Aphex3K Apprentice
Joined: 18 Nov 2003 Posts: 182 Location: Germany
|
Posted: Wed Mar 23, 2005 1:18 pm Post subject: |
|
|
Just take a look at the updated version for 2.5.30-1 this works better than the 30c!
I don't know of an overlay directory? what up with that? _________________ managing a server running gentoo... |
|
Back to top |
|
|
Nick C Guru
Joined: 18 Mar 2005 Posts: 526 Location: Portsmouth, England
|
|
Back to top |
|
|
BlackiWid n00b
Joined: 15 May 2003 Posts: 35
|
Posted: Fri Mar 25, 2005 3:07 am Post subject: |
|
|
hab das script grade mal angepasst auf 2.5.30-1 läuft bei mir so auf einer amd64 maschine:
Code: |
# $Header: /var/cvsroot/gentoo-x86/net-p2p/mldonkey/mldonkey-2.5.30-r1.ebuild,v 1.1 2005/03/20 02:25:00 aphex3k Exp $
inherit eutils
IUSE="gtk gtk2"
#PATCHPACK="patch_pack30c.gz"
DESCRIPTION="mldonkey is a new client to access the eDonkey network. It is written in Objective-Caml, and comes with its own GTK GUI, an HTTP interface and a telnet interface."
HOMEPAGE="http://www.nongnu.org/mldonkey/"
SRC_URI="http://download.berlios.de/pub/mldonkey/spiralvoice/cvs/${P}-1.tar.bz2"
LICENSE="GPL-2"
SLOT="0"
KEYWORDS="~x86 ~ppc ~alpha ~ia64 ~amd64"
RDEPEND=">=dev-lang/ocaml-3.08
dev-lang/perl
net-misc/wget
gtk? ( !gtk2? ( =dev-ml/lablgtk-1.2.7* ) )
gtk? ( gtk2? ( >=dev-ml/lablgtk-2.4 ) )"
DEPEND="${RDEPEND}
>=sys-devel/autoconf-2.58"
MLUSER="p2p"
src_unpack() {
unpack ${P}-1.tar.bz2
cd ${WORKDIR}
mv ${P}-1 ${P}
cd ${S}
#use gtk || epatch ${FILESDIR}/${PV}-conf.patch
export WANT_AUTOCONF=2.5
cd config; autoconf; cd ..
}
src_compile() {
use gtk || export GTK_CONFIG="no"
# the dirs are not (yet) used, but it doesn't hurt to specify them anyway
econf \
--sysconfdir=/etc/mldonkey \
--sharedstatedir=/var/mldonkey \
--localstatedir=/var/mldonkey \
--enable-batch \
--enable-checks \
--enable-pthread \
`use_enable gtk2` || die
export OCAMLRUNPARAM="l=256M"
emake || die
}
src_install() {
dobin mlnet
use gtk && dobin mlchat mlgui mlguistarter mlim mlnet+gui
dobin ${FILESDIR}/mldonkey
dodoc ChangeLog Copying.txt Developers.txt Install.txt
cd ${S}/distrib
dodoc ChangeLog Authors.txt Bugs.txt Copying.txt Developers.txt Install.txt Readme.txt Todo.txt ed2k_links.txt
dohtml FAQ.html
insinto /usr/share/doc/${PF}/scripts
doins kill_mldonkey mldonkey_command mldonkey_previewer
insinto /usr/share/doc/${PF}/distrib
doins directconnect.ini
cd ${S}/docs
dodoc *.txt *.tex *.pdf
dohtml *.html
cd ${S}/docs/developers
dodoc *.txt *.tex
cd ${S}/docs/images
insinto /usr/share/doc/${PF}/html/images
doins *
insinto /etc/conf.d; newins ${FILESDIR}/mldonkey.confd mldonkey
exeinto /etc/init.d; newexe ${FILESDIR}/mldonkey.initd mldonkey
}
pkg_preinst() {
enewuser ${MLUSER} -1 /bin/bash /home/p2p users
}
pkg_postinst() {
echo
einfo "Running \`mldonkey' will start the server inside ~/.mldonkey/"
einfo "If you want to start mldonkey in a particular working directory,"
einfo "use the \`mlnet' command."
einfo "If you want to start mldonkey as a system service, use"
einfo "the /etc/init.d/mldonkey script. To control bandwidth, use"
einfo "the 'slow' and 'fast' arguments. Be sure to have a look at"
einfo "/etc/conf.d/mldonkey also."
echo
}
|
|
|
Back to top |
|
|
Aphex3K Apprentice
Joined: 18 Nov 2003 Posts: 182 Location: Germany
|
Posted: Fri Mar 25, 2005 11:14 am Post subject: |
|
|
Code: |
RDEPEND=">=dev-lang/ocaml-3.08
|
You'll get serious problems when linking mldonkey-2.5.30-1against ocaml-3.08 because it needs ocaml-3.08.3!
Code: | unpack ${P}-1.tar.bz2
cd ${WORKDIR}
mv ${P}-1 ${P}
cd ${S} | Moving the sources dir during install is not the "gentoo" way. Have a look at /usr/portage/skel.ebuild and you'll see that pointing {S} to the correct directory is better than renaming it!
There is allready a working 30-1ebuild --> mldonkey-2.5.30-r1.ebuild you should have better read the thread before! And btw. it is an english forum... _________________ managing a server running gentoo... |
|
Back to top |
|
|
BlackiWid n00b
Joined: 15 May 2003 Posts: 35
|
Posted: Sat Mar 26, 2005 3:20 pm Post subject: |
|
|
thanx for your tipps. that was my second or third ebuild file so its not perfekt but it works.
i have not checked the link here for 2.5.30-1 because i thought it was only a link to the source-file not to the ebuild-file.
but i agree thats better work than mine.
btw. i have problems with mldonkey k i know its not the place to ask that but i try it:
i have tried different versions 2.5.16x-versions and the newer ones. but i get not more than 30kb/s thats top.
with an old 16 version i got in december/january optimal dl-rates (90kb and more) but this version is now banned from most servers.
i tried also amule 2.xx but also no good results,
so any tipps??? |
|
Back to top |
|
|
Aphex3K Apprentice
Joined: 18 Nov 2003 Posts: 182 Location: Germany
|
Posted: Sat Mar 26, 2005 4:00 pm Post subject: |
|
|
I am sorry to tell you but i have got the same values _________________ managing a server running gentoo... |
|
Back to top |
|
|
novazur Guru
Joined: 19 Mar 2005 Posts: 461 Location: Martinique
|
Posted: Sun Apr 03, 2005 9:17 pm Post subject: |
|
|
There is a bug in this version, you have to x2 max_download_rate. |
|
Back to top |
|
|
novazur Guru
Joined: 19 Mar 2005 Posts: 461 Location: Martinique
|
Posted: Sun Apr 03, 2005 9:40 pm Post subject: |
|
|
Sorry, I had to add information sources :
http://download.berlios.de/pub/mldonkey/spiralvoice/
And, your ebuild doesnt work. Not your fault, but there is a bug in cvs tarball.
http://savannah.nongnu.org/bugs/index.php?func=detailitem&item_id=12383
You should patch it :
Code: | # diff -u /var/tmp/portage/mldonkey-2.5.30-r1/work/mldonkey-2.5.30/config/config
ure /usr/src/mldonkey/config/configure
--- /var/tmp/portage/mldonkey-2.5.30-r1/work/mldonkey-2.5.30/config/configure 2005-04-03 17:30:42.000000000 -0400
+++ /usr/src/mldonkey/config/configure 2005-03-30 20:10:12.000000000 -0400
@@ -1330,10 +1330,13 @@
echo $MYCONFIG_ARGS
CURRENT_VERSION=2.5
-CURRENT_RELEASE=30c
+CURRENT_RELEASE=30-1
+if test -d .svn; then
+ CURRENT_RELEASE=${CURRENT_RELEASE}_r`svnversion -n .`
+fi
-REQUIRED_OCAML=3.08.2
-DOWNLOAD_OCAML=3.08.2
+REQUIRED_OCAML=3.08.3
+DOWNLOAD_OCAML=3.08.3
REQUIRED_LABLGTK=1.2.7
@@ -4427,7 +4430,7 @@
if test ! -f ocaml-"$DOWNLOAD_OCAML".tar.gz; then
echo Downloading ...
- $WGET http://pauillac.inria.fr/caml/distrib/ocaml-"$REQUIRED_OCAML"/ocaml-"$DOWNLOAD_OCAML".tar.gz
+ $WGET http://pauillac.inria.fr/caml/distrib/ocaml-3.08/ocaml-"$DOWNLOAD_OCAML".tar.gz
# $WGET http://savannah.nongnu.org/download/mldonkey/tools/ocaml-"$REQUIRED_OCAML".tar.gz
# $WGET http://pauillac.inria.fr/~lefessan/mldonkey/ocaml-"$REQUIRED_OCAML".tar.gz
|
or get the right CVS version |
|
Back to top |
|
|
jschmoe333 n00b
Joined: 08 Apr 2005 Posts: 3
|
Posted: Fri Apr 08, 2005 11:32 am Post subject: |
|
|
Okay as a new gentoo'er I'm somewhat confused as what the final solution is here. I'd like to use the latest CVS version as you suggest but I'm unsure how to do that using emerge- well I understand it's done by using your own ebuild like the original poster but it doesn't even look like the latest. It's 2.5.30.4, no? Could you just replace the version number in your patch? If so how do you apply it and that would be to the original ebuild right? Sorry I guess I'm just confused. Thanks in advance.
P.S. Why is portage so outdated anyways?
novazur wrote: | Sorry, I had to add information sources :
http://download.berlios.de/pub/mldonkey/spiralvoice/
And, your ebuild doesnt work. Not your fault, but there is a bug in cvs tarball.
http://savannah.nongnu.org/bugs/index.php?func=detailitem&item_id=12383
You should patch it :
Code: | # diff -u /var/tmp/portage/mldonkey-2.5.30-r1/work/mldonkey-2.5.30/config/config
ure /usr/src/mldonkey/config/configure
--- /var/tmp/portage/mldonkey-2.5.30-r1/work/mldonkey-2.5.30/config/configure 2005-04-03 17:30:42.000000000 -0400
+++ /usr/src/mldonkey/config/configure 2005-03-30 20:10:12.000000000 -0400
@@ -1330,10 +1330,13 @@
echo $MYCONFIG_ARGS
CURRENT_VERSION=2.5
-CURRENT_RELEASE=30c
+CURRENT_RELEASE=30-1
+if test -d .svn; then
+ CURRENT_RELEASE=${CURRENT_RELEASE}_r`svnversion -n .`
+fi
-REQUIRED_OCAML=3.08.2
-DOWNLOAD_OCAML=3.08.2
+REQUIRED_OCAML=3.08.3
+DOWNLOAD_OCAML=3.08.3
REQUIRED_LABLGTK=1.2.7
@@ -4427,7 +4430,7 @@
if test ! -f ocaml-"$DOWNLOAD_OCAML".tar.gz; then
echo Downloading ...
- $WGET http://pauillac.inria.fr/caml/distrib/ocaml-"$REQUIRED_OCAML"/ocaml-"$DOWNLOAD_OCAML".tar.gz
+ $WGET http://pauillac.inria.fr/caml/distrib/ocaml-3.08/ocaml-"$DOWNLOAD_OCAML".tar.gz
# $WGET http://savannah.nongnu.org/download/mldonkey/tools/ocaml-"$REQUIRED_OCAML".tar.gz
# $WGET http://pauillac.inria.fr/~lefessan/mldonkey/ocaml-"$REQUIRED_OCAML".tar.gz
|
or get the right CVS version |
|
|
Back to top |
|
|
jschmoe333 n00b
Joined: 08 Apr 2005 Posts: 3
|
Posted: Tue Apr 12, 2005 1:11 pm Post subject: bump.. |
|
|
still wondering about this.. anyone? |
|
Back to top |
|
|
stillman Apprentice
Joined: 07 Dec 2002 Posts: 223 Location: Vienna, Austria
|
Posted: Thu Jun 09, 2005 6:54 pm Post subject: |
|
|
jschmoe333 wrote: | Okay as a new gentoo'er I'm somewhat confused as what the final solution is here. I'd like to use the latest CVS version as you suggest but I'm unsure how to do that using emerge- well I understand it's done by using your own ebuild like the original poster but it doesn't even look like the latest. It's 2.5.30.4, no? Could you just replace the version number in your patch? If so how do you apply it and that would be to the original ebuild right? Sorry I guess I'm just confused. Thanks in advance.
|
update: still not the newest version from june but at least something: download updated ebuild, copy to /usr/local/portage/net-p2p/mldonkey
do Code: | ebuild mldonkey-2.5.30.14.ebuild digest
echo "net-p2p/mldonkey" >> /etc/portage/package.unmask
echo "dev-ml/lablgtk-2.4 ~x86" >> /etc/portage/package.keywords
echo "dev-lang/ocaml-3.08.3 ~x86" >> /etc/portage/package.keywords
emerge net-p2p/mldonkey |
that should do the trick
i guess the echo-commands could be shortened into a single command but i don't know how to add the break...
jschmoe333 wrote: | P.S. Why is portage so outdated anyways?
|
i wonder too, mldonkey is very popular afaik so why isn't there more interest in an up-to-date ebuild? |
|
Back to top |
|
|
spiralvoice Apprentice
Joined: 09 Mar 2004 Posts: 238
|
Posted: Fri Jun 10, 2005 12:25 am Post subject: |
|
|
novazur wrote: | There is a bug in this version, you have to x2 max_download_rate. |
Hot-fixed in 2.5.30.16 |
|
Back to top |
|
|
spiralvoice Apprentice
Joined: 09 Mar 2004 Posts: 238
|
Posted: Fri Jun 10, 2005 12:30 am Post subject: |
|
|
BlackiWid wrote: | hab das script grade mal angepasst auf 2.5.30-1 läuft bei mir so auf einer amd64 maschine: |
Translation: His ebuild works on his amd64 machine...
Question: Do you, or other users with AMD64 hardware still have this bug:
Tiger Tree computation fails on amd64
https://savannah.nongnu.org/bugs/index.php?func=detailitem&item_id=8477
Please post your findings with current MLDonkey versions there. |
|
Back to top |
|
|
|