From: Alin Năstac Date: Thu, 4 Jan 2007 22:23:56 +0000 (+0000) Subject: Fix broken compilation on glibc-2.5 , second try (bug #159896 comment #19) X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=a4cadf9b5866bd27259d8c582105264a95ab5928;p=gentoo.git Fix broken compilation on glibc-2.5 , second try (bug #159896 comment #19) Package-Manager: portage-2.1.1-r2 --- diff --git a/net-dialup/rp-pppoe/ChangeLog b/net-dialup/rp-pppoe/ChangeLog index 46ba3f187068..63b0a3ebee68 100644 --- a/net-dialup/rp-pppoe/ChangeLog +++ b/net-dialup/rp-pppoe/ChangeLog @@ -1,9 +1,11 @@ # ChangeLog for net-dialup/rp-pppoe # Copyright 2002-2007 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/net-dialup/rp-pppoe/ChangeLog,v 1.83 2007/01/04 15:04:51 mrness Exp $ +# $Header: /var/cvsroot/gentoo-x86/net-dialup/rp-pppoe/ChangeLog,v 1.84 2007/01/04 22:23:56 mrness Exp $ - 04 Jan 2007; Alin Nastac rp-pppoe-3.8.ebuild: - Add -D_GNU_SOURCE to CFLAGS (#159896). + 04 Jan 2007; Alin Năstac + +files/rp-pppoe-3.8-configure.patch, -files/rp-pppoe-3.8-no-strip.patch, + rp-pppoe-3.8.ebuild: + Fix broken compilation on glibc-2.5 (#159896). 23 Sep 2006; Alin Nastac +files/rp-pppoe-3.8-no-strip.patch, rp-pppoe-3.8.ebuild: diff --git a/net-dialup/rp-pppoe/files/rp-pppoe-3.8-configure.patch b/net-dialup/rp-pppoe/files/rp-pppoe-3.8-configure.patch new file mode 100644 index 000000000000..40f6f08c9138 --- /dev/null +++ b/net-dialup/rp-pppoe/files/rp-pppoe-3.8-configure.patch @@ -0,0 +1,70 @@ +diff -Nru rp-pppoe-3.8.orig/gui/Makefile.in rp-pppoe-3.8/gui/Makefile.in +--- rp-pppoe-3.8.orig/gui/Makefile.in 2006-09-23 18:05:31.000000000 +0300 ++++ rp-pppoe-3.8/gui/Makefile.in 2006-09-23 18:16:02.623018000 +0300 +@@ -46,7 +46,7 @@ + -mkdir -p $(RPM_INSTALL_ROOT)$(sbindir) + -mkdir -p $(RPM_INSTALL_ROOT)$(bindir) + -mkdir -p $(RPM_INSTALL_ROOT)/etc/ppp/rp-pppoe-gui +- $(install) -m 4755 -s pppoe-wrapper $(RPM_INSTALL_ROOT)$(sbindir) ++ $(install) -m 4755 pppoe-wrapper $(RPM_INSTALL_ROOT)$(sbindir) + $(install) -m 755 tkpppoe $(RPM_INSTALL_ROOT)$(bindir) + -mkdir -p $(RPM_INSTALL_ROOT)$(mandir)/man1 + $(install) -m 644 pppoe-wrapper.1 $(RPM_INSTALL_ROOT)$(mandir)/man1 +diff -Nru rp-pppoe-3.8.orig/src/configure.in rp-pppoe-3.8/src/configure.in +--- rp-pppoe-3.8.orig/src/configure.in 2006-04-02 17:29:42.000000000 +0300 ++++ rp-pppoe-3.8/src/configure.in 2007-01-05 00:12:48.000000000 +0200 +@@ -145,15 +145,15 @@ + AC_MSG_CHECKING(for Linux 2.4.X kernel-mode PPPoE support) + AC_CACHE_VAL(ac_cv_linux_kernel_pppoe,[ + if test "`uname -s`" = "Linux" ; then +-if test $cross_compiling = "no"; then ++dnl if test $cross_compiling = "no"; then + + dnl Do a bunch of modprobes. Can't hurt; might help. +-modprobe ppp_generic > /dev/null 2>&1 +-modprobe ppp_async > /dev/null 2>&1 +-modprobe n_hdlc > /dev/null 2>&1 +-modprobe ppp_synctty > /dev/null 2>&1 +-modprobe pppoe > /dev/null 2>&1 +-fi ++dnl modprobe ppp_generic > /dev/null 2>&1 ++dnl modprobe ppp_async > /dev/null 2>&1 ++dnl modprobe n_hdlc > /dev/null 2>&1 ++dnl modprobe ppp_synctty > /dev/null 2>&1 ++dnl modprobe pppoe > /dev/null 2>&1 ++dnl fi + AC_TRY_RUN([#include + #include + #include +@@ -180,7 +180,7 @@ + + dnl GCC warning level + if test "$GCC" = yes; then +- CFLAGS="$CFLAGS -Wall -Wstrict-prototypes -ansi" ++ CFLAGS="$CFLAGS -Wall -Wstrict-prototypes -D_GNU_SOURCE" + fi + + dnl If we couldn't find pppd, die +diff -Nru rp-pppoe-3.8.orig/src/plugin.c rp-pppoe-3.8/src/plugin.c +--- rp-pppoe-3.8.orig/src/plugin.c 2006-04-02 17:29:42.000000000 +0300 ++++ rp-pppoe-3.8/src/plugin.c 2007-01-05 00:08:41.000000000 +0200 +@@ -27,7 +27,6 @@ + static char const RCSID[] = + "$Id: rp-pppoe-3.8-configure.patch,v 1.1 2007/01/04 22:23:56 mrness Exp $"; + +-#define _GNU_SOURCE 1 + #include "pppoe.h" + + #include "pppd/pppd.h" +diff -Nru rp-pppoe-3.8.orig/src/relay.c rp-pppoe-3.8/src/relay.c +--- rp-pppoe-3.8.orig/src/relay.c 2006-04-02 17:29:42.000000000 +0300 ++++ rp-pppoe-3.8/src/relay.c 2007-01-05 00:08:46.000000000 +0200 +@@ -17,8 +17,6 @@ + static char const RCSID[] = + "$Id: rp-pppoe-3.8-configure.patch,v 1.1 2007/01/04 22:23:56 mrness Exp $"; + +-#define _GNU_SOURCE 1 /* For SA_RESTART */ +- + #include "relay.h" + + #include diff --git a/net-dialup/rp-pppoe/rp-pppoe-3.8.ebuild b/net-dialup/rp-pppoe/rp-pppoe-3.8.ebuild index 2a9a2dc3e038..35406eb3c86e 100644 --- a/net-dialup/rp-pppoe/rp-pppoe-3.8.ebuild +++ b/net-dialup/rp-pppoe/rp-pppoe-3.8.ebuild @@ -1,8 +1,8 @@ # Copyright 1999-2007 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/net-dialup/rp-pppoe/rp-pppoe-3.8.ebuild,v 1.11 2007/01/04 15:04:51 mrness Exp $ +# $Header: /var/cvsroot/gentoo-x86/net-dialup/rp-pppoe/rp-pppoe-3.8.ebuild,v 1.12 2007/01/04 22:23:56 mrness Exp $ -inherit eutils flag-o-matic +inherit eutils flag-o-matic autotools DESCRIPTION="A user-mode PPPoE client and server suite for Linux" HOMEPAGE="http://www.roaringpenguin.com/pppoe/" @@ -39,18 +39,18 @@ src_unpack() { epatch "${FILESDIR}/${P}-username-charset.patch" #82410 epatch "${FILESDIR}/${P}-plugin-options.patch" - epatch "${FILESDIR}/${P}-no-strip.patch" + epatch "${FILESDIR}/${P}-configure.patch" + cd "${S}" #Avoid "setXid, dynamically linked and using lazy bindings" QA notice - sed -i -e 's:\(@CC@\) \(-o pppoe-wrapper wrapper.o\):\1 '$(bindnow-flags)' \2:' "${S}/gui/Makefile.in" + sed -i -e 's:\(@CC@\) \(-o pppoe-wrapper wrapper.o\):\1 '$(bindnow-flags)' \2:' gui/Makefile.in - # sanbdox violation workaround - sed -i -e 's/modprobe/echo modprobe/' "${S}/src/configure" || die "sed failed" + cd src + eautoconf } src_compile() { addpredict /dev/ppp - append-flags -D_GNU_SOURCE cd "${S}/src" econf --enable-plugin=../../ppp-2.4.3 || die "econf failed"