View previous topic :: View next topic |
Author |
Message |
Maedhros Bodhisattva
Joined: 14 Apr 2004 Posts: 5511 Location: Durham, UK
|
Posted: Fri Jul 01, 2005 9:05 am Post subject: XMMS2 ebuilds |
|
|
I was bored this morning, so decided to get xmms2 managed by portage on my system. Here's what I came up with:
xmms2-0.1_pre11.ebuild:
Code: | # Copyright 1999-2005 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: $
inherit eutils toolchain-funcs
MY_P="xmms2-0.1DR1.1"
DESCRIPTION="A server/client music player."
HOMEPAGE="http://wiki.xmms2.xmms.se/index.php/Main_Page"
SRC_URI="mirror://sourceforge/xmms2/${MY_P}.tar.gz"
LICENSE="GPL-2"
SLOT="0"
KEYWORDS="~amd64"
IUSE="alsa diskwrite flac oggvorbis oss python ruby samba"
DEPEND=">=dev-util/scons-0.96.1
>=dev-lang/python-2.2.1
>=dev-libs/glib-2.2.0
media-libs/libmad
net-misc/curl
=dev-db/sqlite-3.2*
python? (>=dev-python/pyrex-0.9.3)
ruby? (>=dev-lang/ruby-1.8)
oggvorbis? (media-libs/libvorbis)
alsa? (media-libs/alsa-lib)
flac? (media-libs/flac)
samba? (net-fs/samba)"
S="${WORKDIR}/${MY_P}"
src_compile() {
if useq python && [[ $(gcc-major-version ) == 4 ]]; then
eerror "Pyrex generates code that gcc4 does not compile, so you need"
eerror "to drop down to gcc3."
die
fi
EXCLUDE=""
useq python || EXCLUDE="${EXCLUDE} python"
useq ruby || EXCLUDE="${EXCLUDE} ruby"
useq oggvorbis || EXCLUDE="${EXCLUDE} vorbis"
useq flac || EXCLUDE="${EXCLUDE} flac"
useq oss || EXCLUDE="${EXCLUDE} oss"
useq alsa || EXCLUDE="${EXCLUDE} alsa"
useq samba || EXCLUDE="${EXCLUDE} samba"
useq diskwrite || EXCLUDE="${EXCLUDE} diskwrite"
scons CCFLAGS="${CFLAGS}" \
CPPFLAGS="${CXXFLAGS}" \
LINKFLAGS="${LDFLAGS}" \
PREFIX="/usr" \
INSTALLDIR="${D}" \
EXCLUDE="${EXCLUDE}" \
${MAKEOPTS} || die "scons failed"
}
src_install() {
scons install || die "scons install failed"
} |
I'm not entirely happy with the version for this ebuild -- since you can't put DR in an ebuild version things get slightly complicated. What would be ideal would be xmms2-0.1_pre1.1, but the number after _pre has to be a positive integer, _pre1_p1 doesn't work as you can't specify both, and -r is only for Gentoo patches. In the end I went with the first option but got rid of the full stop, but this means DR2 will have to be _pre20.
gxmms2-0.4.1.ebuild:
Code: | # Copyright 1999-2005 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: $
DESCRIPTION="gxmms2 is a GTK2 based XMMS2 client, written in C."
HOMEPAGE="http://wejp.homelinux.org/wejp/xmms2/"
SRC_URI="http://wejp.homelinux.org/wejp/xmms2/${P}.tar.gz"
LICENSE="GPL"
SLOT="0"
KEYWORDS="~amd64"
IUSE=""
DEPEND="=x11-libs/gtk+-2.6*"
src_compile() {
# Remove the -O2 for people who have their own -O settings:
sed -ie "s:^FLAGS = -O2:FLAGS =:" Makefile
make XMMS2_INCLUDE_DIR="/usr/include/xmms2" || die "make failed"
}
src_install() {
make INSTALLPATH="${D}/usr/bin" install || die "make install failed"
} |
Enjoy! _________________ No-one's more important than the earthworm.
Last edited by Maedhros on Fri Jul 01, 2005 11:53 am; edited 3 times in total |
|
Back to top |
|
|
TrueDFX Retired Dev
Joined: 02 Jun 2004 Posts: 1348
|
Posted: Fri Jul 01, 2005 10:19 am Post subject: Re: XMMS2 ebuilds |
|
|
Maedhros wrote: | Code: | DEPEND="...
python? (>=dev-python/pyrex-0.9.3 !=sys-devel/gcc-4*)
... |
|
Mostly curious, but why the !=sys-devel/gcc-4* ? If it's just because it doesn't compile with gcc 4, wouldn't this also block users with both gcc 3 and 4 installed who are currently using gcc 3? |
|
Back to top |
|
|
Maedhros Bodhisattva
Joined: 14 Apr 2004 Posts: 5511 Location: Durham, UK
|
Posted: Fri Jul 01, 2005 10:26 am Post subject: Re: XMMS2 ebuilds |
|
|
TrueDFX wrote: | Mostly curious, but why the !=sys-devel/gcc-4* ? If it's just because it doesn't compile with gcc 4, wouldn't this also block users with both gcc 3 and 4 installed who are currently using gcc 3? |
Ehm, because I didn't think of that. I assume I should be looking in the toolchain-funcs.eclass for a better solution? _________________ No-one's more important than the earthworm. |
|
Back to top |
|
|
TrueDFX Retired Dev
Joined: 02 Jun 2004 Posts: 1348
|
Posted: Fri Jul 01, 2005 10:29 am Post subject: |
|
|
Yeah, you could use gcc-majorversion for that (or, since gcc 4 isn't supported yet, you could just let it try to compile and watch it die ) |
|
Back to top |
|
|
Maedhros Bodhisattva
Joined: 14 Apr 2004 Posts: 5511 Location: Durham, UK
|
Posted: Fri Jul 01, 2005 11:49 am Post subject: |
|
|
TrueDFX wrote: | (or, since gcc 4 isn't supported yet, you could just let it try to compile and watch it die ) |
easy_option++. Oh for a configure script so I could actually disable/enable things sensibly.
I've also added a note for the foolhardy^Wbrave.
Edit: Some trial and error later... The ebuild will now die if you're trying to build the python bindings with gcc4, and the USE flags now actually enable/disable things. I've also discovered some other optional modules, so they're now controllable with USE flags too. _________________ No-one's more important than the earthworm. |
|
Back to top |
|
|
plbe l33t
Joined: 01 May 2004 Posts: 661
|
Posted: Fri Jul 01, 2005 2:29 pm Post subject: |
|
|
great work, I'm curious as to why this isn't in portage yet |
|
Back to top |
|
|
drakos7 Apprentice
Joined: 21 Feb 2003 Posts: 294 Location: Rockville, MD, USA, Earth, Sol
|
Posted: Fri Jul 01, 2005 2:38 pm Post subject: |
|
|
Simple edit: you may want to add ~x86 to the KEYWORDS so rookie x86 Gentooers are not really confused when it says the package is masked.
And it is not in portage yet because of the standard reasons (see https://forums.gentoo.org/viewtopic-t-333423.html) |
|
Back to top |
|
|
plbe l33t
Joined: 01 May 2004 Posts: 661
|
Posted: Fri Jul 01, 2005 2:51 pm Post subject: |
|
|
drakos7 wrote: | Simple edit: you may want to add ~x86 to the KEYWORDS so rookie x86 Gentooers are not really confused when it says the package is masked.
And it is not in portage yet because of the standard reasons (see https://forums.gentoo.org/viewtopic-t-333423.html) |
standard reason == 404 not found I mean if we can have live cvs ebuilds of experimental stuff why not xmms2 DR's....there aim is for client development and testing
Last edited by plbe on Fri Jul 01, 2005 2:54 pm; edited 1 time in total |
|
Back to top |
|
|
Maedhros Bodhisattva
Joined: 14 Apr 2004 Posts: 5511 Location: Durham, UK
|
Posted: Fri Jul 01, 2005 2:54 pm Post subject: |
|
|
I've just found this fairly large bug with several ebuilds already attached: https://bugs.gentoo.org/show_bug.cgi?id=93583
This is official reason it isn't in Portage, anyway:
Eric Shattow wrote: | xmms2 wiki states that this is unsuitable for end users. marking invalid; please
try again when the xmms2 is ready. |
_________________ No-one's more important than the earthworm. |
|
Back to top |
|
|
plbe l33t
Joined: 01 May 2004 Posts: 661
|
Posted: Fri Jul 01, 2005 2:55 pm Post subject: |
|
|
Maedhros wrote: | I've just found this fairly large bug with several ebuilds already attached: https://bugs.gentoo.org/show_bug.cgi?id=93583
This is official reason it isn't in Portage, anyway:
Eric Shattow wrote: | xmms2 wiki states that this is unsuitable for end users. marking invalid; please
try again when the xmms2 is ready. |
|
unsuitable how? been using it for a while and has been working just fine I ran into a problem installing it on amd64 but the howto i posted in documentation tips and tricks works perfect |
|
Back to top |
|
|
mirko_3 l33t
Joined: 02 Nov 2003 Posts: 605 Location: Birreria
|
Posted: Fri Jul 01, 2005 3:10 pm Post subject: |
|
|
Just because it works for you, it doesn't mean that it wont blow up my computer, kill me, start a fire, burn the nearby power station and exterminate the rest of humanity... _________________ Non fa male! Non fa male! |
|
Back to top |
|
|
drakos7 Apprentice
Joined: 21 Feb 2003 Posts: 294 Location: Rockville, MD, USA, Earth, Sol
|
Posted: Fri Jul 01, 2005 3:23 pm Post subject: |
|
|
Exactly. And it does not seem to work for me. As we all know, I am the arbiter of justice, goodness, and supported software. Code: | xmms2d &
xmms2 play
...blah blah...
2005-07-01 11:20 DEBUG: src/plugins/vorbis/vorbisfile.c:370: Vorbis inited!!!!
2005-07-01 11:20 DEBUG: src/xmms/output.c:886: Starting playback!
2005-07-01 11:20 DEBUG: src/xmms/ipc.c:441: disconnect was true!
2005-07-01 11:20 DEBUG: src/xmms/ipc.c:478: Destroying client!
2005-07-01 11:20 DEBUG: src/plugins/alsa/alsa.c:346: Opening device: default
2005-07-01 11:20 DEBUG: src/plugins/vorbis/vorbisfile.c:298: Running get_media_info()
2005-07-01 11:20 DEBUG: src/plugins/alsa/alsa.c:651: Setting format 3 2 44100
2005-07-01 11:20 DEBUG: src/plugins/alsa/alsa.c:479: Buffer time requested: 500ms, got
: 341ms
2005-07-01 11:20 DEBUG: src/xmms/transport.c:454: Let's start buffering
xmms2d: pcm.c:5960: snd_pcm_mmap_commit: Assertion `frames <= snd_pcm_mmap_avail(pcm)'
failed.
Aborted |
Hmmm.... |
|
Back to top |
|
|
plbe l33t
Joined: 01 May 2004 Posts: 661
|
Posted: Fri Jul 01, 2005 3:40 pm Post subject: |
|
|
Actually to be quite honest now that you mention DR1.1 gave me some problems. I simply downloaded one of the daily snapshots and it worked perfect.....perhaps we can do something like a live cvs ebuild? erm git ebuild? |
|
Back to top |
|
|
plbe l33t
Joined: 01 May 2004 Posts: 661
|
Posted: Fri Jul 01, 2005 3:47 pm Post subject: |
|
|
drakos7 wrote: | Exactly. And it does not seem to work for me. As we all know, I am the arbiter of justice, goodness, and supported software. Code: | xmms2d &
xmms2 play
...blah blah...
2005-07-01 11:20 DEBUG: src/plugins/vorbis/vorbisfile.c:370: Vorbis inited!!!!
2005-07-01 11:20 DEBUG: src/xmms/output.c:886: Starting playback!
2005-07-01 11:20 DEBUG: src/xmms/ipc.c:441: disconnect was true!
2005-07-01 11:20 DEBUG: src/xmms/ipc.c:478: Destroying client!
2005-07-01 11:20 DEBUG: src/plugins/alsa/alsa.c:346: Opening device: default
2005-07-01 11:20 DEBUG: src/plugins/vorbis/vorbisfile.c:298: Running get_media_info()
2005-07-01 11:20 DEBUG: src/plugins/alsa/alsa.c:651: Setting format 3 2 44100
2005-07-01 11:20 DEBUG: src/plugins/alsa/alsa.c:479: Buffer time requested: 500ms, got
: 341ms
2005-07-01 11:20 DEBUG: src/xmms/transport.c:454: Let's start buffering
xmms2d: pcm.c:5960: snd_pcm_mmap_commit: Assertion `frames <= snd_pcm_mmap_avail(pcm)'
failed.
Aborted |
Hmmm.... |
follow my howto and see if it works for you I didn't really glance at the ebuild to see if its amd64 specific, I only see ~amd64 keyword, no ~x86(a few things have to be changed for amd64 which might effect x86 which may be why its not working for you)
https://forums.gentoo.org/viewtopic-t-333423-postdays-0-postorder-asc-start-0.html |
|
Back to top |
|
|
Maedhros Bodhisattva
Joined: 14 Apr 2004 Posts: 5511 Location: Durham, UK
|
Posted: Fri Jul 01, 2005 4:17 pm Post subject: |
|
|
The ebuild shouldn't be amd64 specific -- it built and works fine for me without appending -fPIC since it seems to be done internally now anyway.
Here's a snapshot ebuild that may or may not work for you. I wouldn't even know where to start with a live git ebuild, so snapshots seemed the safer way to go. X is the version of the snapshot you want to install, so for instance the most recent would be 200506282054:
xmms2-0.1_preX.ebuild
Code: | # Copyright 1999-2005 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: $
inherit eutils toolchain-funcs versionator
MY_PV="$(get_version_component_range 3 ${PV})"
MY_PV="${MY_PV/pre/}"
MY_P="${PN}-snapshot-${MY_PV}"
DESCRIPTION="A server/client music player."
HOMEPAGE="http://wiki.xmms2.xmms.se/index.php/Main_Page"
SRC_URI="http://git.xmms.se/snapshots/${MY_P}.tar.gz"
LICENSE="GPL-2"
SLOT="0"
KEYWORDS="~amd64"
IUSE="alsa diskwrite flac oggvorbis oss python ruby samba"
DEPEND=">=dev-util/scons-0.96.1
>=dev-lang/python-2.2.1
>=dev-libs/glib-2.2.0
media-libs/libmad
net-misc/curl
=dev-db/sqlite-3.2*
python? (>=dev-python/pyrex-0.9.3)
ruby? (>=dev-lang/ruby-1.8)
oggvorbis? (media-libs/libvorbis)
alsa? (media-libs/alsa-lib)
flac? (media-libs/flac)
samba? (net-fs/samba)"
S="${WORKDIR}/${MY_P}"
src_compile() {
if useq python && [[ $(gcc-major-version ) == 4 ]]; then
eerror "Pyrex generates code that gcc4 does not compile, so you need "
eerror "to drop down to gcc3."
die
fi
EXCLUDE=""
useq python || EXCLUDE="${EXCLUDE} python"
useq ruby || EXCLUDE="${EXCLUDE} ruby"
useq oggvorbis || EXCLUDE="${EXCLUDE} vorbis"
useq flac || EXCLUDE="${EXCLUDE} flac"
useq oss || EXCLUDE="${EXCLUDE} oss"
useq alsa || EXCLUDE="${EXCLUDE} alsa"
useq samba || EXCLUDE="${EXCLUDE} samba"
useq diskwrite || EXCLUDE="${EXCLUDE} diskwrite"
scons CCFLAGS="${CFLAGS}" \
CPPFLAGS="${CXXFLAGS}" \
LINKFLAGS="${LDFLAGS}" \
PREFIX="/usr" \
INSTALLDIR="${D}" \
EXCLUDE="${EXCLUDE}" \
${MAKEOPTS} || die "scons failed"
}
src_install() {
scons install || die "scons install failed"
} |
_________________ No-one's more important than the earthworm. |
|
Back to top |
|
|
plbe l33t
Joined: 01 May 2004 Posts: 661
|
Posted: Fri Jul 01, 2005 4:26 pm Post subject: |
|
|
yeah isn't there a way you can tell portage to download the latest snapshot available and use that? or is that what this ebuild does? I should really read the ebuild howto guide some day |
|
Back to top |
|
|
drakos7 Apprentice
Joined: 21 Feb 2003 Posts: 294 Location: Rockville, MD, USA, Earth, Sol
|
Posted: Fri Jul 01, 2005 4:30 pm Post subject: |
|
|
My problem (above) was an alsa lib problem. Upgrading my alsa architecture fixed it. |
|
Back to top |
|
|
plbe l33t
Joined: 01 May 2004 Posts: 661
|
Posted: Fri Jul 01, 2005 4:31 pm Post subject: |
|
|
drakos7 wrote: | My problem (above) was an alsa lib problem. Upgrading my alsa architecture fixed it. |
glad to hear |
|
Back to top |
|
|
Maedhros Bodhisattva
Joined: 14 Apr 2004 Posts: 5511 Location: Durham, UK
|
Posted: Fri Jul 01, 2005 4:38 pm Post subject: |
|
|
plbe wrote: | yeah isn't there a way you can tell portage to download the latest snapshot available and use that? or is that what this ebuild does? I should really read the ebuild howto guide some day |
Not that I know of. There are ebuilds that pull the sources straight from cvs or subversion, but there are eclasses available that do all the hard work behind the scenes, and there isn't one for git (at the moment). AFAIK there's no way to get portage to download the latest snapshot tarball available; the ebuild just uses the version part of the filename (as do all ebuilds, this one just needs a bit of manipulation to get the relevant part) to find the version to download.
drakos7: Glad to hear it's working for you now. _________________ No-one's more important than the earthworm. |
|
Back to top |
|
|
plbe l33t
Joined: 01 May 2004 Posts: 661
|
Posted: Fri Jul 01, 2005 4:44 pm Post subject: |
|
|
well if this ebuild works, there shouldn't be no reason it can't be in portage eh? |
|
Back to top |
|
|
Maedhros Bodhisattva
Joined: 14 Apr 2004 Posts: 5511 Location: Durham, UK
|
Posted: Fri Jul 01, 2005 4:58 pm Post subject: |
|
|
I suspect that since it's still in heavy development, and may or may not be stable at all the devs don't want to deal with supporting any bug reports. I wouldn't expect it in portage until the first release candidate, personally. _________________ No-one's more important than the earthworm. |
|
Back to top |
|
|
plbe l33t
Joined: 01 May 2004 Posts: 661
|
Posted: Fri Jul 01, 2005 5:03 pm Post subject: |
|
|
Maedhros wrote: | I suspect that since it's still in heavy development, and may or may not be stable at all the devs don't want to deal with supporting any bug reports. I wouldn't expect it in portage until the first release candidate, personally. |
eh, but look at e17, supposibly thats not even alpha yet and we have that just put a nice big note after the installation is complete that this is not stable software, if doesn't work don't bitch |
|
Back to top |
|
|
jxn Guru
Joined: 27 Aug 2004 Posts: 327 Location: south dakota
|
Posted: Fri Jul 01, 2005 8:44 pm Post subject: |
|
|
plbe wrote: | if doesn't work don't bitch |
a key phrase. _________________ My Last.fm profile | get e17! |
|
Back to top |
|
|
plbe l33t
Joined: 01 May 2004 Posts: 661
|
Posted: Sat Jul 02, 2005 9:17 pm Post subject: |
|
|
jxn wrote: | plbe wrote: | if doesn't work don't bitch |
a key phrase. |
indeed |
|
Back to top |
|
|
plbe l33t
Joined: 01 May 2004 Posts: 661
|
Posted: Sun Jul 03, 2005 2:12 pm Post subject: |
|
|
hrm so did this ebuild work ok for anyone else? |
|
Back to top |
|
|
|