diff options
author | Nick Hadaway <raker@gentoo.org> | 2002-12-27 01:10:33 +0000 |
---|---|---|
committer | Nick Hadaway <raker@gentoo.org> | 2002-12-27 01:10:33 +0000 |
commit | 206a9b38d9eae47dea5c172e5f75b2f2618ab174 (patch) | |
tree | f3cd9a6030095a341648fabdf642b5c3b3bf4f1d /media-sound/xmms | |
parent | new version (diff) | |
download | historical-206a9b38d9eae47dea5c172e5f75b2f2618ab174.tar.gz historical-206a9b38d9eae47dea5c172e5f75b2f2618ab174.tar.bz2 historical-206a9b38d9eae47dea5c172e5f75b2f2618ab174.zip |
New ebuild with ipv6 support. Also changed all patches to use epatch.
Diffstat (limited to 'media-sound/xmms')
-rw-r--r-- | media-sound/xmms/ChangeLog | 8 | ||||
-rw-r--r-- | media-sound/xmms/files/digest-xmms-1.2.7-r17 | 2 | ||||
-rw-r--r-- | media-sound/xmms/files/xmms-ipv6-20020408.patch | 354 | ||||
-rw-r--r-- | media-sound/xmms/xmms-1.2.7-r17.ebuild | 179 |
4 files changed, 542 insertions, 1 deletions
diff --git a/media-sound/xmms/ChangeLog b/media-sound/xmms/ChangeLog index 5a3092efa42e..9cee406f8fb8 100644 --- a/media-sound/xmms/ChangeLog +++ b/media-sound/xmms/ChangeLog @@ -1,6 +1,12 @@ # ChangeLog for media-sound/xmms # Copyright 2002 Gentoo Technologies, Inc.; Distributed under the GPL -# $Header: /var/cvsroot/gentoo-x86/media-sound/xmms/ChangeLog,v 1.35 2002/12/20 03:55:51 alron Exp $ +# $Header: /var/cvsroot/gentoo-x86/media-sound/xmms/ChangeLog,v 1.36 2002/12/27 01:10:32 raker Exp $ + +*xmms-1.2.7-r17 (26 Dec 2002) + + 26 Dec 2002; Nick Hadaway <raker@gentoo.org> xmms-1.2.7-r17.ebuild, + files/digest-xmms-1.2.7-r17, files/xmms-ipv6-20020408.patch : + New ebuild with ipv6 support. Now using epatch for all patches. 19 Dev 2002; Dean Bailey <alron@gentoo.org> : removed sparc64 keyword diff --git a/media-sound/xmms/files/digest-xmms-1.2.7-r17 b/media-sound/xmms/files/digest-xmms-1.2.7-r17 new file mode 100644 index 000000000000..89cc7eba5fd4 --- /dev/null +++ b/media-sound/xmms/files/digest-xmms-1.2.7-r17 @@ -0,0 +1,2 @@ +MD5 8aa14a305d1eeb1bb53dba2197ba695a xmms-1.2.7.tar.gz 2860908 +MD5 daea40648c3ae296597dcd3e78500279 xmms-1.2.7-mmx.patch.gz 14990 diff --git a/media-sound/xmms/files/xmms-ipv6-20020408.patch b/media-sound/xmms/files/xmms-ipv6-20020408.patch new file mode 100644 index 000000000000..31475e30f520 --- /dev/null +++ b/media-sound/xmms/files/xmms-ipv6-20020408.patch @@ -0,0 +1,354 @@ +Index: acconfig.h +=================================================================== +RCS file: /cvs/xmms/acconfig.h,v +retrieving revision 1.13 +diff -u -r1.13 acconfig.h +--- acconfig.h 14 Nov 2001 22:08:14 -0000 1.13 ++++ acconfig.h 8 Apr 2002 19:05:50 -0000 +@@ -57,6 +57,7 @@ + #undef PACKAGE + #undef VERSION + #undef USE_SIMD ++#undef USE_IPV6 + #undef WITH_SYMBOL_UNDERSCORE + #undef WITH_SM + #undef ENABLE_NLS +Index: configure.in +=================================================================== +RCS file: /cvs/xmms/configure.in,v +retrieving revision 1.116 +diff -u -r1.116 configure.in +--- configure.in 24 Mar 2002 14:38:22 -0000 1.116 ++++ configure.in 8 Apr 2002 19:05:51 -0000 +@@ -338,6 +338,17 @@ + fi + AM_CONDITIONAL(USE_SIMD,test "x$USE_SIMD" = xyes) + AC_SUBST(USE_SIMD_TRUE) ++ ++dnl IPv6 support ++dnl ======================== ++AC_ARG_ENABLE(ipv6, ++ [ --enable-ipv6 enable IPv6 support [default=no]], ++ enable_ipv6=$enableval, enable_ipv6=no) ++if test "x$enable_ipv6" = xyes; then ++ AC_DEFINE(USE_IPV6) ++fi ++AM_CONDITIONAL(USE_IPV6,test "x$enable_ipv6" = xyes) ++AC_SUBST(USE_IPV6) + dnl ======================== + + AC_CACHE_CHECK(for socklen_t, xmms_cv_type_socklen_t, +Index: Input/cdaudio/http.c +=================================================================== +RCS file: /cvs/xmms/Input/cdaudio/http.c,v +retrieving revision 1.5 +diff -u -r1.5 http.c +--- Input/cdaudio/http.c 21 Jul 2000 08:54:17 -0000 1.5 ++++ Input/cdaudio/http.c 8 Apr 2002 19:05:51 -0000 +@@ -25,9 +25,45 @@ + gint http_open_connection(gchar * server, gint port) + { + gint sock; ++#ifdef USE_IPV6 ++ struct addrinfo hints, *res, *res0; ++ char service[6]; ++#else + struct hostent *host; + struct sockaddr_in address; ++#endif + ++#ifdef USE_IPV6 ++ snprintf(service, 6, "%d", port); ++ memset(&hints, 0, sizeof(hints)); ++ hints.ai_socktype = SOCK_STREAM; ++ ++ if (getaddrinfo(server, service, &hints, &res0)) ++ return 0; ++ ++ for (res = res0; res; res = res->ai_next) { ++ sock = socket (res->ai_family, res->ai_socktype, res->ai_protocol); ++ if (sock < 0) { ++ if (res->ai_next) ++ continue; ++ else { ++ freeaddrinfo(res0); ++ return 0; ++ } ++ } ++ if (connect(sock, res->ai_addr, res->ai_addrlen) < 0) { ++ if (res->ai_next) { ++ close(sock); ++ continue; ++ } else { ++ freeaddrinfo(res0); ++ return 0; ++ } ++ } ++ freeaddrinfo(res0); ++ return sock; ++ } ++#else + sock = socket(AF_INET, SOCK_STREAM, 0); + address.sin_family = AF_INET; + +@@ -40,6 +76,7 @@ + if (connect(sock, (struct sockaddr *) &address, sizeof (struct sockaddr_in)) == -1) + return 0; + ++#endif + return sock; + } + +Index: Input/mpg123/http.c +=================================================================== +RCS file: /cvs/xmms/Input/mpg123/http.c,v +retrieving revision 1.26 +diff -u -r1.26 http.c +--- Input/mpg123/http.c 6 Jan 2002 22:13:16 -0000 1.26 ++++ Input/mpg123/http.c 8 Apr 2002 19:05:52 -0000 +@@ -332,8 +332,13 @@ + gboolean redirect; + int udp_sock = 0; + fd_set set; ++#ifdef USE_IPV6 ++ struct addrinfo hints, *res, *res0; ++ char service[6]; ++#else + struct hostent *hp; + struct sockaddr_in address; ++#endif + struct timeval tv; + + url = (gchar *) arg; +@@ -355,6 +360,45 @@ + chost = mpg123_cfg.use_proxy ? mpg123_cfg.proxy_host : host; + cport = mpg123_cfg.use_proxy ? mpg123_cfg.proxy_port : port; + ++#ifdef USE_IPV6 ++ snprintf(service, 6, "%d", cport); ++ memset(&hints, 0, sizeof(hints)); ++ hints.ai_socktype = SOCK_STREAM; ++ if (! getaddrinfo(chost, service, &hints, &res0)) { ++ eof = TRUE; ++ for (res = res0; res; res = res->ai_next) { ++ if ((sock = socket (res->ai_family, res->ai_socktype, res->ai_protocol)) < 0) ++ continue; ++ fcntl(sock, F_SETFL, O_NONBLOCK); ++ status = g_strdup_printf(_("CONNECTING TO %s:%d"), chost, cport); ++ mpg123_ip.set_info_text(status); ++ g_free(status); ++ ((struct sockaddr_in6 *)res->ai_addr)->sin6_port = htons(cport); ++ if (connect(sock, res->ai_addr, res->ai_addrlen) < 0) { ++ if (errno != EINPROGRESS) { ++ close(sock); ++ continue; ++ } ++ } ++ eof = FALSE; ++ break; ++ } ++ freeaddrinfo(res0); ++ if (eof) { ++ status = g_strdup_printf(_("Couldn't connect to host %s:%d"), chost, cport); ++ show_error_message(status); ++ g_free(status); ++ mpg123_ip.set_info_text(NULL); ++ } ++ } else { ++ status = g_strdup_printf(_("Couldn't look up host %s"), chost); ++ show_error_message(status); ++ g_free(status); ++ ++ mpg123_ip.set_info_text(NULL); ++ eof = TRUE; ++ } ++#else + sock = socket(AF_INET, SOCK_STREAM, 0); + fcntl(sock, F_SETFL, O_NONBLOCK); + address.sin_family = AF_INET; +@@ -372,9 +416,11 @@ + mpg123_ip.set_info_text(NULL); + eof = TRUE; + } ++#endif + + if (!eof) + { ++#ifndef USE_IPV6 + memcpy(&address.sin_addr.s_addr, *(hp->h_addr_list), sizeof (address.sin_addr.s_addr)); + address.sin_port = g_htons(cport); + +@@ -393,6 +439,7 @@ + eof = TRUE; + } + } ++#endif + while (going) + { + tv.tv_sec = 0; +@@ -697,14 +744,23 @@ + /* Find a good local udp port and bind udp_sock to it, return the port */ + static int udp_establish_listener(int *sock) + { ++#ifdef USE_IPV6 ++ struct sockaddr_in6 sin; ++ socklen_t sinlen = sizeof (struct sockaddr_in6); ++#else + struct sockaddr_in sin; + socklen_t sinlen = sizeof (struct sockaddr_in); ++#endif + + #ifdef DEBUG_UDP + fprintf (stderr,"Establishing udp listener\n"); + #endif + ++#ifdef USE_IPV6 ++ if ((*sock = socket(AF_INET6, SOCK_DGRAM, 0)) < 0) ++#else + if ((*sock = socket(AF_INET, SOCK_DGRAM, 0)) < 0) ++#endif + { + g_log(NULL, G_LOG_LEVEL_CRITICAL, + "udp_establish_listener(): unable to create socket"); +@@ -712,8 +768,12 @@ + } + + memset(&sin, 0, sinlen); ++#ifdef USE_IPV6 ++ sin.sin6_family = AF_INET6; ++#else + sin.sin_family = AF_INET; + sin.sin_addr.s_addr = g_htonl(INADDR_ANY); ++#endif + + if (bind(*sock, (struct sockaddr *)&sin, sinlen) < 0) + { +@@ -743,7 +803,11 @@ + fprintf (stderr,"Listening on local %s:%d\n", inet_ntoa(sin.sin_addr), g_ntohs(sin.sin_port)); + #endif + ++#ifdef USE_IPV6 ++ return g_ntohs(sin.sin6_port); ++#else + return g_ntohs(sin.sin_port); ++#endif + } + + static int udp_check_for_data(int sock) +@@ -752,10 +816,14 @@ + char *valptr; + gchar *title; + gint len, i; ++#ifdef USE_IPV6 ++ struct sockaddr_in6 from; ++#else + struct sockaddr_in from; ++#endif + socklen_t fromlen; + +- fromlen = sizeof(struct sockaddr_in); ++ fromlen = sizeof(from); + + if ((len = recvfrom(sock, buf, 1024, 0, (struct sockaddr *)&from, &fromlen)) < 0) + { +@@ -840,7 +908,14 @@ + #ifdef DEBUG_UDP + else + fprintf(stderr,"Sent ack: %s", obuf); ++#ifdef USE_IPV6 ++{ ++ char adr[INET6_ADDRSTRLEN]; ++ inet_ntop(AF_INET6, &from.sin6_addr, adr, INET6_ADDRSTRLEN); ++ fprintf (stderr,"Remote: [%s]:%d\n", adr, g_ntohs(from.sin6_port)); ++#else + fprintf (stderr,"Remote: %s:%d\n", inet_ntoa(from.sin_addr), g_ntohs(from.sin_port)); ++#endif + #endif + } + } +Index: Input/vorbis/http.c +=================================================================== +RCS file: /cvs/xmms/Input/vorbis/http.c,v +retrieving revision 1.4 +diff -u -r1.4 http.c +--- Input/vorbis/http.c 29 Dec 2001 19:03:38 -0000 1.4 ++++ Input/vorbis/http.c 8 Apr 2002 19:05:52 -0000 +@@ -287,8 +287,13 @@ + gint cnt, written, error, err_len, port, cport; + gboolean redirect; + fd_set set; ++#ifdef USE_IPV6 ++ struct addrinfo hints, *res, *res0; ++ char service[6]; ++#else + struct hostent *hp; + struct sockaddr_in address; ++#endif + struct timeval tv; + + url = (gchar *) arg; +@@ -310,6 +315,44 @@ + chost = vorbis_cfg.use_proxy ? vorbis_cfg.proxy_host : host; + cport = vorbis_cfg.use_proxy ? vorbis_cfg.proxy_port : port; + ++#ifdef USE_IPV6 ++ snprintf(service, 6, "%d", cport); ++ memset(&hints, 0, sizeof(hints)); ++ hints.ai_socktype = SOCK_STREAM; ++ if (! getaddrinfo(chost, service, &hints, &res0)) { ++ eof = TRUE; ++ for (res = res0; res; res = res->ai_next) { ++ if ((sock = socket (res->ai_family, res->ai_socktype, res->ai_protocol)) < 0) ++ continue; ++ fcntl(sock, F_SETFL, O_NONBLOCK); ++ status = g_strdup_printf(_("CONNECTING TO %s:%d"), chost, cport); ++ vorbis_ip.set_info_text(status); ++ g_free(status); ++ ((struct sockaddr_in6 *)res->ai_addr)->sin6_port = htons(cport); ++ if (connect(sock, res->ai_addr, res->ai_addrlen) < 0) { ++ if (errno != EINPROGRESS) { ++ close(sock); ++ continue; ++ } ++ } ++ eof = FALSE; ++ break; ++ } ++ freeaddrinfo(res0); ++ if (eof) { ++ status = g_strdup_printf(_("Couldn't connect to host %s:%d"), chost, cport); ++ vorbis_ip.set_info_text(status); ++ g_free(status); ++ eof = TRUE; ++ break; ++ } ++ } else { ++ status = g_strdup_printf(_("Couldn't look up host %s"), chost); ++ vorbis_ip.set_info_text(status); ++ g_free(status); ++ eof = TRUE; ++ } ++#else + sock = socket(AF_INET, SOCK_STREAM, 0); + fcntl(sock, F_SETFL, O_NONBLOCK); + address.sin_family = AF_INET; +@@ -327,9 +370,11 @@ + vorbis_ip.set_info_text(NULL); + eof = TRUE; + } ++#endif + + if (!eof) + { ++#ifndef USE_IPV6 + memcpy(&address.sin_addr.s_addr, *(hp->h_addr_list), sizeof (address.sin_addr.s_addr)); + address.sin_port = g_htons(cport); + +@@ -348,6 +393,7 @@ + eof = TRUE; + } + } ++#endif + while (going) + { + tv.tv_sec = 0; diff --git a/media-sound/xmms/xmms-1.2.7-r17.ebuild b/media-sound/xmms/xmms-1.2.7-r17.ebuild new file mode 100644 index 000000000000..88df4e440b44 --- /dev/null +++ b/media-sound/xmms/xmms-1.2.7-r17.ebuild @@ -0,0 +1,179 @@ +# Copyright 1999-2002 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.7-r17.ebuild,v 1.1 2002/12/27 01:10:32 raker Exp $ + +IUSE="xml nls esd gnome opengl mmx oggvorbis 3dnow mikmod directfb ipv6" + +inherit libtool flag-o-matic eutils + +filter-flags "-fforce-addr" + +S="${WORKDIR}/${P}" +DESCRIPTION="X MultiMedia System" +SRC_URI="http://www.xmms.org/files/1.2.x/${P}.tar.gz + mmx? ( http://members.jcom.home.ne.jp/jacobi/linux/etc/${P}-mmx.patch.gz )" +HOMEPAGE="http://www.xmms.org/" + +SLOT="0" +LICENSE="GPL-2" +KEYWORDS="~x86 ~ppc ~sparc ~alpha" + +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.gz + + cd ${S} + + # For plugins such as avi4xmms, xmms needs to be linked to libstdcxx. + # + # NOTE: because we change a Makefile.am here, we run auto* at the + # bottom. + # + # WARNING: Do not remove or feel my anger!!! :P + # + epatch ${FILESDIR}/${P}-link-libstdc++.patch + + # Patch to allow external programmes to have the "jump to" dialog box + epatch ${FILESDIR}/xmms-jump.patch + + # The following optimisations are ONLY for x86 platform + use x86 && ( \ + # For mmx/3dnow enabled CPUs, this patch adds mmx/3dnow optimisations + # + # ( use mmx || use 3dnow ) && \ + # cat ${DISTDIR}/${P}-mmx.patch.gz | gunzip -c | patch -p1 || die + # + # For you guys who favour this kind of USE flag checking ... this + # is exactly why I do NOT like it, because the actual + # "cat ${DISTDIR}/${P}-mmx.patch.gz | gunzip -c | patch -p1 || die" + # was not in a subshell, it would ALWAYS fail to build if "mmx" or + # "3dnow" was not in USE, because of the || die at the end. So + # PLEASE, PLEASE test things with all possible USE flags if you use + # this style!!!! Then, if in a subshell, it do not detect if the + # command fails :/ + # + # Azarah - 30 Jun 2002 + # + if use mmx || use 3dnow + then + epatch ${DISTDIR}/${P}-mmx.patch.gz + fi + ) + + use ipv6 && epatch ${FILESDIR}/xmms-ipv6-20020408.patch + + [ ! -f ${S}/config.rpath ] && ( \ + touch ${S}/config.rpath + chmod +x ${S}/config.rpath + ) + + # We run automake and autoconf here else we get a lot of warning/errors. + # I have tested this with gcc-2.95.3 and gcc-3.1. + elibtoolize + echo ">>> Reconfiguring..." + for x in ${S} ${S}/libxmms + do + cd ${x} + aclocal + export WANT_AUTOCONF_2_5=1 + automake --gnu --include-deps Makefile || die + autoconf || die + done +} + +src_compile() { + local myconf="" + + use gnome \ + && myconf="${myconf} --with-gnome" \ + || myconf="${myconf} --without-gnome" + + use 3dnow || use mmx \ + && myconf="${myconf} --enable-simd" \ + || myconf="${myconf} --disable-simd" + + use esd \ + && myconf="${myconf} --enable-esd --enable-esdtest" \ + || myconf="${myconf} --disable-esd --disable-esdtest" + + use mikmod \ + && myconf="${myconf} --enable-mikmod --enable-mikmodtest \ + --with-libmikmod" \ + || myconf="${myconf} --disable-mikmod --disable-mikmodtest \ + --without-libmikmod" + + use opengl \ + && myconf="${myconf} --enable-opengl" \ + || myconf="${myconf} --disable-opengl" + + use oggvorbis \ + && myconf="${myconf} --enable-vorbis --enable-oggtest \ + --enable-vorbistest --with-ogg" \ + || myconf="${myconf} --disable-vorbis --disable-oggtest \ + --disable-vorbistest --without-ogg" + + use xml \ + || myconf="${myconf} --disable-cdindex" + + use nls \ + || myconf="${myconf} --disable-nls" + + use ipv6 && myconf="${myconf) --enable-ipv6" + + econf ${myconf} || die + + emake || die +} + +src_install() { + einstall \ + sysdir=${D}/usr/share/applets/Multimedia \ + GNOME_SYSCONFDIR=${D}/etc || die + + dodoc AUTHORS ChangeLog COPYING FAQ NEWS README TODO + + dodir /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 + + use gnome && ( \ + 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 + ) || ( \ + rm ${D}/usr/share/man/man1/gnomexmms* + ) + + # causes segfaults for ppc users #10309 and after talking + # to xmms dev's, they've punted this from the src tree anyways ... + rm -rf ${D}/usr/lib/xmms/Input/libidcin.so +} + +pkg_postrm() { + + if [ -x ${ROOT}/usr/bin/xmms ] && [ ! -d ${ROOT}/usr/share/xmms/Skins ] + then + mkdir -p ${ROOT}/usr/share/xmms/Skins + fi +} + |