diff options
author | 2003-09-14 23:05:01 +0000 | |
---|---|---|
committer | 2003-09-14 23:05:01 +0000 | |
commit | 6039076ecf15dc870528ae8845c2b63f7ea035b4 (patch) | |
tree | 06faf4ae7ad744f606459d143da4944815b5f58d /media-sound | |
parent | added randomiser patch (diff) | |
download | gentoo-2-6039076ecf15dc870528ae8845c2b63f7ea035b4.tar.gz gentoo-2-6039076ecf15dc870528ae8845c2b63f7ea035b4.tar.bz2 gentoo-2-6039076ecf15dc870528ae8845c2b63f7ea035b4.zip |
added randomiser patch
Diffstat (limited to 'media-sound')
-rw-r--r-- | media-sound/xmms/ChangeLog | 9 | ||||
-rw-r--r-- | media-sound/xmms/Manifest | 4 | ||||
-rw-r--r-- | media-sound/xmms/files/digest-xmms-1.2.8-r2 | 2 | ||||
-rw-r--r-- | media-sound/xmms/files/xmms-1.2.8-random.patch | 30 | ||||
-rw-r--r-- | media-sound/xmms/xmms-1.2.8-r2.ebuild | 144 |
5 files changed, 186 insertions, 3 deletions
diff --git a/media-sound/xmms/ChangeLog b/media-sound/xmms/ChangeLog index 09ec24933832..e6353c705289 100644 --- a/media-sound/xmms/ChangeLog +++ b/media-sound/xmms/ChangeLog @@ -1,6 +1,13 @@ # ChangeLog for media-sound/xmms # Copyright 2002-2003 Gentoo Technologies, Inc.; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/media-sound/xmms/ChangeLog,v 1.67 2003/09/13 03:46:59 vapier Exp $ +# $Header: /var/cvsroot/gentoo-x86/media-sound/xmms/ChangeLog,v 1.68 2003/09/14 23:05:00 seemant Exp $ + +*xmms-1.2.8-r2 (14 Sep 2003) + + 14 Sep 2003; Seemant Kulleen <seemant@gentoo.org> xmms-1.2.8-r2.ebuild: + added the superior randomising patch. Bret Towe (magnade in #gentoo-dev) + <btowe@gbis.com> adapted this patch for us from the xmms bugzilla. All the + info is in bug #24137 by Lesley van Zijl <zyl@xs4all.nl> *xmms-1.2.8-r1 (12 Sep 2003) diff --git a/media-sound/xmms/Manifest b/media-sound/xmms/Manifest index afc9a8dd95fd..13e444dbc2fb 100644 --- a/media-sound/xmms/Manifest +++ b/media-sound/xmms/Manifest @@ -1,10 +1,10 @@ MD5 67719e9afde51fc778b8882f48bebfc2 xmms-1.2.7-r23.ebuild 5233 -MD5 d8e8a39360c6ce5d5f66aca2aa764a91 xmms-1.2.8-r2.ebuild 3902 +MD5 11bf996dbc79054069ea44717bad0d67 xmms-1.2.8-r2.ebuild 3902 MD5 1f4fb5fbbf7591ead0b68071825b2de3 xmms-1.2.7-r25.ebuild 5652 MD5 5013cb7f0010b3daa8efd1548cbe83b4 xmms-1.2.7-r20.ebuild 4923 MD5 0ee64fc05669ecd516d7239e2a575e8d xmms-1.2.8.ebuild 4350 MD5 092d1ae9348717c6e29072cbc747275e xmms-1.2.8-r1.ebuild 3813 -MD5 e96feff582effb171e866ff933c5ec94 ChangeLog 12478 +MD5 38ca2ceb36200852f771cbce7268d40f ChangeLog 12795 MD5 a1eaeb2ae801daeb712c90c060e922dc metadata.xml 158 MD5 e7e0c91780b115aaad1a1ed534bf7ae8 files/xmms-ipv6-20020408-mmx.patch 9210 MD5 a095e427745739d9b2555b64fa14029b files/xmms-1.2.8-dtd.patch 53079 diff --git a/media-sound/xmms/files/digest-xmms-1.2.8-r2 b/media-sound/xmms/files/digest-xmms-1.2.8-r2 new file mode 100644 index 000000000000..737c2f506433 --- /dev/null +++ b/media-sound/xmms/files/digest-xmms-1.2.8-r2 @@ -0,0 +1,2 @@ +MD5 d523735b59232f0eedd45dc2b7a4f5ad xmms-1.2.8.tar.bz2 2322808 +MD5 a68edd5b03d650c366f09852a8414ee2 gentoo_ice.zip 68458 diff --git a/media-sound/xmms/files/xmms-1.2.8-random.patch b/media-sound/xmms/files/xmms-1.2.8-random.patch new file mode 100644 index 000000000000..e3364bcd7a93 --- /dev/null +++ b/media-sound/xmms/files/xmms-1.2.8-random.patch @@ -0,0 +1,30 @@ +--- xmms/playlist.c.old 2003-09-14 00:39:21.000000000 -0700 ++++ xmms/playlist.c 2003-09-14 00:45:40.000000000 -0700 +@@ -545,7 +545,8 @@ + /* If there are entries */ + if (g_list_length(skinlist)) { + /* Get a random value to select the skin to use */ +- int randval = random() % (g_list_length(skinlist) + 1); ++ int len = (g_list_length(skinlist) + 1); ++ int randval = (int)((double)random() / RAND_MAX * len); + /* If the random value is 0, use the default skin */ + /* Otherwise subtract 1 from the random value and */ + /* select the skin */ +@@ -1887,7 +1888,7 @@ + { + /* Only find new songs in our current + score section */ +- j = (rand() % (next_score_section - i)) + i; ++ j = (gint)((double)random() / RAND_MAX * (next_score_section - i)) + i; + + assert(j < next_score_section); + } +@@ -1970,7 +1971,7 @@ + gint j; + + /* Pick a random song among the ones that are left */ +- j = (rand() % (len - i)) + i; ++ j = (gint)((double)random() / RAND_MAX * len); + + /* Swap pointer #i and pointer #j */ + swap_ptr = ptrs[i]; diff --git a/media-sound/xmms/xmms-1.2.8-r2.ebuild b/media-sound/xmms/xmms-1.2.8-r2.ebuild new file mode 100644 index 000000000000..df2b32241e57 --- /dev/null +++ b/media-sound/xmms/xmms-1.2.8-r2.ebuild @@ -0,0 +1,144 @@ +# Copyright 1999-2003 Gentoo Technologies, Inc. +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/media-sound/xmms/xmms-1.2.8-r2.ebuild,v 1.1 2003/09/14 23:05:00 seemant Exp $ + +IUSE="xml nls esd gnome opengl mmx oggvorbis 3dnow mikmod directfb ipv6 cjk" + +inherit flag-o-matic eutils +filter-flags -fforce-addr -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE + +DESCRIPTION="X MultiMedia System" +HOMEPAGE="http://www.xmms.org/" +SRC_URI="http://www.xmms.org/files/1.2.x/${P}.tar.bz2 + mirror://gentoo/gentoo_ice.zip" + +SLOT="0" +LICENSE="GPL-2" +KEYWORDS="~x86 ~ppc ~sparc ~alpha ~hppa ~mips" + +DEPEND="app-arch/unzip + =x11-libs/gtk+-1.2* + mikmod? ( >=media-libs/libmikmod-3.1.6 ) + esd? ( >=media-sound/esound-0.2.22 ) + xml? ( >=dev-libs/libxml-1.8.15 ) + gnome? ( <gnome-base/gnome-panel-1.5.0 ) + opengl? ( virtual/opengl ) + oggvorbis? ( >=media-libs/libvorbis-1.0_beta4 )" + +RDEPEND="${DEPEND} + directfb? ( dev-libs/DirectFB ) + nls? ( dev-util/intltool )" + +src_unpack() { + unpack ${P}.tar.bz2 + cd ${S} + + # Patch to allow external programmes to have the "jump to" dialog box + epatch ${FILESDIR}/${P}-jump.patch + + # Save playlist, etc on SIGTERM and SIGINT, bug #13604. + epatch ${FILESDIR}/${P}-sigterm.patch + + # Patch for mpg123 to convert Japanese character code of MP3 tag info + # the Japanese patch and the Russian one overlap, so its one or the other + if use cjk; then + epatch ${FILESDIR}/${P}-mpg123j.patch + else + # add russian charset support + epatch ${FILESDIR}/${P}-russian-charset.patch + fi + + # Add dynamic taste detection patch + epatch ${FILESDIR}/${P}-dtd.patch + + if [ ! -f ${S}/config.rpath ] ; then + touch ${S}/config.rpath + chmod +x ${S}/config.rpath + fi + + # Add /usr/local/share/xmms/Skins to the search path for skins + epatch ${FILESDIR}/${PN}-fhs-skinsdir.patch + + # This patch passes audio output through the output plugin + # before recording via the diskwriter plugin + # http://forum.xmms.org/viewtopic.php?t=500&sid=c286e1c01fb924a2f81f519969f33764 + epatch ${FILESDIR}/xmms-diskwriter-audio.patch + + # Patch to enable superior randomised playlists: + epatch ${FILESDIR}/${P}-random.patch + + export WANT_AUTOCONF_2_5=1 + for x in . libxmms ; do + cd ${S}/${x} + automake --gnu --add-missing --include-deps || die + done +} + +src_compile() { + local myconf="" + + # Allow configure to detect mipslinux systems + use mips && gnuconfig_update + + if [ `use 3dnow` ] || [ `use mmx` ] ; then + myconf="${myconf} --enable-simd" + else + myconf="${myconf} --disable-simd" + fi + + use xml || myconf="${myconf} --disable-cdindex" + + econf \ + --with-dev-dsp=/dev/sound/dsp \ + --with-dev-mixer=/dev/sound/mixer \ + `use_with gnome` \ + `use_enable oggvorbis vorbis` \ + `use_enable oggvorbis oggtest` \ + `use_enable oggvorbis vorbistest` \ + `use_enable esd` \ + `use_enable esd esdtest` \ + `use_enable mikmod` \ + `use_enable mikmod mikmodtest` \ + `use_with mikmod libmikmod` \ + `use_enable opengl` \ + `use_enable nls` \ + `use_enable ipv6` \ + ${myconf} \ + || die + + ### emake seems to break some compiles, please keep @ make + make || die +} + +src_install() { + einstall \ + incdir=${D}/usr/include \ + sysdir=${D}/usr/share/applets/Multimedia \ + GNOME_SYSCONFDIR=${D}/etc \ + install || die "make install failed" + + dodoc AUTHORS ChangeLog COPYING FAQ NEWS README TODO + + keepdir /usr/share/xmms/Skins + insinto /usr/share/pixmaps/ + donewins gnomexmms/gnomexmms.xpm xmms.xpm + doins xmms/xmms_logo.xpm + insinto /usr/share/pixmaps/mini + doins xmms/xmms_mini.xpm + + insinto /etc/X11/wmconfig + donewins xmms/xmms.wmconfig xmms + + if [ `use gnome` ] ; then + insinto /usr/share/gnome/apps/Multimedia + doins xmms/xmms.desktop + dosed "s:xmms_mini.xpm:mini/xmms_mini.xpm:" \ + /usr/share/gnome/apps/Multimedia/xmms.desktop + else + rm ${D}/usr/share/man/man1/gnomexmms* + fi + + # Add the sexy Gentoo Ice skin + insinto /usr/share/xmms/Skins + doins ${DISTDIR}/gentoo_ice.zip +} |