Date: Thu, 6 Dec 2007 16:55:38 +0100 From: "Pietro Cerutti" <gahr@gahr.ch> To: "FreeBSD gnats submit" <FreeBSD-gnats-submit@FreeBSD.org> Subject: ports/118464: [patch] audio/gnomoradio unbreak fix build with GCC 4.2 + adopt maintainship Message-ID: <1196956538.74644@gahrtop.localhost> Resent-Message-ID: <200712061600.lB6G03DN014994@freefall.freebsd.org>
next in thread | raw e-mail | index | archive | help
>Number: 118464 >Category: ports >Synopsis: [patch] audio/gnomoradio unbreak fix build with GCC 4.2 + adopt maintainship >Confidential: no >Severity: serious >Priority: medium >Responsible: freebsd-ports-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Thu Dec 06 16:00:03 UTC 2007 >Closed-Date: >Last-Modified: >Originator: Pietro Cerutti >Release: FreeBSD 8.0-CURRENT i386 >Organization: >Environment: System: FreeBSD 8.0-CURRENT #15: Thu Dec 6 12:47:48 CET 2007 root@gahrtop.localhost:/usr/obj/usr/src/sys/MSI1034 >Description: The patch below: - fixes a namespace problem causing an error with GCC 4.2 - cleans a few const char * -> char * warnings - sets maintainship to me Tested on: 8.0-CURRENT i386 7.0-BETA3 sparc64 >How-To-Repeat: cd /usr/ports/audio/gnomoradio && make >Fix: --- _gnomoradio.diff begins here --- --- Makefile.orig 2007-12-06 15:15:19.000000000 +0100 +++ Makefile 2007-12-06 15:45:48.000000000 +0100 @@ -12,7 +12,7 @@ MASTER_SITES= ${MASTER_SITE_SAVANNAH} MASTER_SITE_SUBDIR= ${PORTNAME} -MAINTAINER= ports@FreeBSD.org +MAINTAINER= gahr@gahr.ch COMMENT= A program for finding and playing free music from the Internet LIB_DEPENDS= sigc-2.0:${PORTSDIR}/devel/libsigc++20 \ @@ -29,17 +29,13 @@ USE_LDCONFIG= yes LIBTOOLFLAGS= --tag=CXX CONFIGURE_ENV= CPPFLAGS="-I${LOCALBASE}/include" \ - LDFLAGS="-L${LOCALBASE}/lib" - -.include <bsd.port.pre.mk> - -.if ${OSVERSION} >= 700042 -BROKEN= Broken with gcc 4.2 -.endif + LDFLAGS="-L${LOCALBASE}/lib" post-patch: @${REINPLACE_CMD} -e 's|CCLD = $$(CC)|CCLD = $$(CXX)|; \ s|-lpthread|${PTHREAD_LIBS}|' \ ${WRKSRC}/roboradio/mp3/Makefile.in + @${REINPLACE_CMD} -e 's|static char|static const char|' \ + ${WRKSRC}/gnomoradio/*.xpm -.include <bsd.port.post.mk> +.include <bsd.port.mk> --- /dev/null 2007-12-06 15:49:29.000000000 +0100 +++ files/patch-gnomoradio_browser-link.cc 2007-12-06 15:48:27.000000000 +0100 @@ -0,0 +1,11 @@ +--- gnomoradio/browser-link.cc.orig 2007-12-06 15:46:11.000000000 +0100 ++++ gnomoradio/browser-link.cc 2007-12-06 15:48:02.000000000 +0100 +@@ -32,7 +32,7 @@ + { + gchar *my_url = g_strdup(Glib::locale_from_utf8(url).c_str()); + if (fork() == 0) { +- char *const argv[] = {"gnome-moz-remote", "--newwin", my_url, 0}; ++ char *const argv[] = {(char *)"gnome-moz-remote", (char *)"--newwin", my_url, 0}; + execvp(argv[0], argv); + + // if we made it here something went wrong --- /dev/null 2007-12-06 15:49:41.000000000 +0100 +++ files/patch-roboradio-audio_prober.cc 2007-12-06 15:40:44.000000000 +0100 @@ -0,0 +1,58 @@ +--- roboradio/audio/prober.cc.orig 2007-12-06 15:39:58.000000000 +0100 ++++ roboradio/audio/prober.cc 2007-12-06 15:40:19.000000000 +0100 +@@ -21,6 +21,30 @@ + #include "../mp3/esd-audio.h" + } + ++namespace Roboradio ++{ ++ namespace Audio ++ { ++ gboolean probe (gpointer s) ++ { ++ Prober *sng = static_cast<Prober*>(s); ++ if (esdout_playing()) { ++ int pos = sng->get_position(); ++ if (pos >= 0) ++ sng->signal_position_changed(pos); ++ return true; ++ } else if (sng->get_position() >= 0) { ++ return true; ++ } else { ++ sng->stop(); ++ sng->signal_done(); ++ sng->activated = false; ++ return false; ++ } ++ } ++ } ++} ++ + Roboradio::Audio::Prober::Prober () + : activated(false) + { +@@ -31,24 +55,6 @@ + stop_prober(); + } + +-gboolean Roboradio::Audio::probe (gpointer s) +-{ +- Prober *sng = static_cast<Prober*>(s); +- if (esdout_playing()) { +- int pos = sng->get_position(); +- if (pos >= 0) +- sng->signal_position_changed(pos); +- return true; +- } else if (sng->get_position() >= 0) { +- return true; +- } else { +- sng->stop(); +- sng->signal_done(); +- sng->activated = false; +- return false; +- } +-} +- + void Roboradio::Audio::Prober::start_prober () + { + if (activated) --- _gnomoradio.diff ends here --- >Release-Note: >Audit-Trail: >Unformatted:
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?1196956538.74644>