Hello,

The rp-pppoe package from the packages feed, section net fails to build.

There are two problems:
 1) rp-pppoe.so not built
 2) spurious dependency on libevent missing

1) The resulting error message is:
cp: cannot stat `xxx/rp-pppoe-3.11/ipkg-install/etc/ppp/plugins/rp-pppoe.so': 
No such file or directory

What happens is that configure has a test to decide if the plugin is to be built. The test compiles a test file containing the linux/if_pppox.h header file. It fails because the header needs an additional include beforehand (i.e. linux/in6.h, because of ipv6 support). Thus the plugin won't be built.

2) The resulting error message is:
Package rp-pppoe-server is missing dependencies for the following libraries:
libevent-2.0.so.5

What happens is, that the target may contain the libevent library as well, and rp-pppoe-server gets (superflously) linked against that library. The fix is to drop the "-Llibevent -levent" linking flags. They are superflous anyway, because libevent.a (the rp-pppoe one, in the rp-pppoe subdir src/libevent) is already part of rp-pppoe-server's dependencies. (Here we talk about Makefile dependencies, not opkg dependencies)


I hope, thunderbird won't whitespace damage the following patch:

Best regards, Nils Rennebarth

diff --git a/net/rp-pppoe/patches/100-configure.patch 
b/net/rp-pppoe/patches/100-configure.patch
index 62e9222..d45593a 100644
--- a/net/rp-pppoe/patches/100-configure.patch
+++ b/net/rp-pppoe/patches/100-configure.patch
@@ -9,7 +9,7 @@
  "
  if test "x$ac_cv_header_linux_if_h" = x""yes; then :
    cat >>confdefs.h <<_ACEOF
-@@ -3675,10 +3675,10 @@ done
+@@ -3675,10 +3675,11 @@ done
  for ac_header in linux/if_pppox.h
  do :
    ac_fn_c_check_header_compile "$LINENO" "linux/if_pppox.h" 
"ac_cv_header_linux_if_pppox_h" "
@@ -21,10 +21,11 @@
 +#include <net/ethernet.h>
 +#include <linux/if.h>
 +#include <linux/in.h>
++#include <linux/in6.h>

  "
  if test "x$ac_cv_header_linux_if_pppox_h" = x""yes; then :
-@@ -4611,7 +4611,7 @@ esac
+@@ -4611,7 +4612,7 @@ esac
  $as_echo_n "checking packing order of bit fields... " >&6; }
  if test "${rpppoe_cv_pack_bitfields+set}" != set ; then
  if test "$cross_compiling" = yes; then :
diff --git a/net/rp-pppoe/patches/110-Makefile.patch 
b/net/rp-pppoe/patches/110-Makefile.patch
new file mode 100644
index 0000000..9dc1c72
--- /dev/null
+++ b/net/rp-pppoe/patches/110-Makefile.patch
@@ -0,0 +1,11 @@
+--- a/src/Makefile.in
++++ b/src/Makefile.in
+@@ -71,7 +71,7 @@ pppoe-sniff: pppoe-sniff.o if.o common.o
+       @CC@ -o $@ $^ $(LDFLAGS)
+
+ pppoe-server: pppoe-server.o if.o debug.o common.o md5.o libevent/libevent.a 
@PPPOE_SERVER_DEPS@
+-      @CC@ -o $@ @RDYNAMIC@ $^ $(LDFLAGS) $(PPPOE_SERVER_LIBS) -Llibevent 
-levent
++      @CC@ -o $@ @RDYNAMIC@ $^ $(LDFLAGS) $(PPPOE_SERVER_LIBS)
+
+ pppoe: pppoe.o if.o debug.o common.o ppp.o discovery.o
+       @CC@ -o $@ $^ $(LDFLAGS)


--
Nils Rennebarth
Software Developer
Teldat packetalarm logo
Teldat Security GmbH
Moenchhaldenstr. 28
D-70191 Stuttgart
Tel: +49 711 900300 - 62
Fax: +49 711 900300 - 90
E-Mail: nils.renneba...@teldat.de

Location: GmbH Nuernberg, Local Court Nuernberg, HRB 25481 Managing Director: 
Bernd Buettner

Teldat packetalarm banner

--------------------------------
The information contained in this e-mail has been carefully researched, but the 
possibility of it being inapplicable in
individual cases cannot be ruled out. We therefore regret that we cannot accept 
responsibility or liability of any kind
whatsoever for the correctness of the information given. Please notify us if 
you discover that information is inapplicable.
_______________________________________________
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel

Reply via email to