aboutsummaryrefslogtreecommitdiffstats
path: root/package/network/services/ppp/patches/140-pppoe_compile_fix.patch
diff options
context:
space:
mode:
Diffstat (limited to 'package/network/services/ppp/patches/140-pppoe_compile_fix.patch')
-rw-r--r--package/network/services/ppp/patches/140-pppoe_compile_fix.patch46
1 files changed, 5 insertions, 41 deletions
diff --git a/package/network/services/ppp/patches/140-pppoe_compile_fix.patch b/package/network/services/ppp/patches/140-pppoe_compile_fix.patch
index d9c9b83a33..e25c567033 100644
--- a/package/network/services/ppp/patches/140-pppoe_compile_fix.patch
+++ b/package/network/services/ppp/patches/140-pppoe_compile_fix.patch
@@ -1,7 +1,7 @@
--- a/pppd/plugins/rp-pppoe/pppoe.h
+++ b/pppd/plugins/rp-pppoe/pppoe.h
-@@ -48,11 +48,7 @@
- #endif
+@@ -52,11 +52,7 @@
+ #include <netinet/in.h>
/* Ugly header files on some Linux boxes... */
-#if defined(HAVE_LINUX_IF_H)
@@ -12,7 +12,7 @@
#ifdef HAVE_NET_IF_TYPES_H
#include <net/if_types.h>
-@@ -80,22 +76,8 @@ typedef unsigned long UINT32_t;
+@@ -84,20 +80,7 @@ typedef unsigned long UINT32_t;
#error Could not find a 32-bit integer type
#endif
@@ -20,8 +20,6 @@
-#include <linux/if_ether.h>
-#endif
-
- #include <netinet/in.h>
--
-#ifdef HAVE_NETINET_IF_ETHER_H
-#include <sys/types.h>
-
@@ -35,45 +33,11 @@
+#include <net/ethernet.h>
-
---- a/pppd/plugins/rp-pppoe/pppoe-discovery.c
-+++ b/pppd/plugins/rp-pppoe/pppoe-discovery.c
-@@ -16,6 +16,7 @@
- #include <string.h>
-
- #include "pppoe.h"
-+#include "pppd/pppd.h"
-
- #ifdef HAVE_UNISTD_H
- #include <unistd.h>
-@@ -717,6 +718,23 @@ char *xstrdup(const char *s)
- return ret;
- }
-
-+void
-+error(char *fmt, ...)
-+{
-+ va_list pvar;
-+
-+#if defined(__STDC__)
-+ va_start(pvar, fmt);
-+#else
-+ char *fmt;
-+ va_start(pvar);
-+ fmt = va_arg(pvar, char *);
-+#endif
-+
-+ fprintf(stderr, fmt, pvar);
-+ va_end(pvar);
-+}
-+
- void usage(void)
- {
- fprintf(stderr, "Usage: pppoe-discovery [options]\n");
+ /* Ethernet frame types according to RFC 2516 */
--- a/pppd/plugins/rp-pppoe/Makefile.linux
+++ b/pppd/plugins/rp-pppoe/Makefile.linux
@@ -33,7 +33,7 @@ pppoe-discovery: pppoe-discovery.o debug
- $(CC) $(CFLAGS) -o pppoe-discovery pppoe-discovery.o debug.o
+ $(CC) $(LDFLAGS) -o pppoe-discovery pppoe-discovery.o debug.o
pppoe-discovery.o: pppoe-discovery.c
- $(CC) $(CFLAGS) -c -o pppoe-discovery.o pppoe-discovery.c