summaryrefslogtreecommitdiff
path: root/package/ppp/patches
diff options
context:
space:
mode:
Diffstat (limited to 'package/ppp/patches')
-rw-r--r--package/ppp/patches/patch-chat_Makefile_linux26
-rw-r--r--package/ppp/patches/patch-include_linux_ppp-comp_h63
-rw-r--r--package/ppp/patches/patch-include_net_ppp-comp_h36
-rw-r--r--package/ppp/patches/patch-pppd_Makefile_linux70
-rw-r--r--package/ppp/patches/patch-pppd_chap_ms_c6
-rw-r--r--package/ppp/patches/patch-pppd_main_c14
-rw-r--r--package/ppp/patches/patch-pppd_plugins_Makefile_linux29
-rw-r--r--package/ppp/patches/patch-pppd_plugins_pppoatm_Makefile_linux36
-rw-r--r--package/ppp/patches/patch-pppd_plugins_pppol2tp_Makefile_linux41
-rw-r--r--package/ppp/patches/patch-pppd_plugins_radius_Makefile_linux40
-rw-r--r--package/ppp/patches/patch-pppd_plugins_rp-pppoe_Makefile_linux80
-rw-r--r--package/ppp/patches/patch-pppd_pppd_810
-rw-r--r--package/ppp/patches/patch-pppdump_Makefile_linux32
-rw-r--r--package/ppp/patches/patch-pppstats_Makefile_linux45
14 files changed, 379 insertions, 149 deletions
diff --git a/package/ppp/patches/patch-chat_Makefile_linux b/package/ppp/patches/patch-chat_Makefile_linux
index 63190f3e3..3d0c3fdff 100644
--- a/package/ppp/patches/patch-chat_Makefile_linux
+++ b/package/ppp/patches/patch-chat_Makefile_linux
@@ -1,6 +1,26 @@
---- ppp-2.4.4.orig/chat/Makefile.linux 2006-06-04 07:07:46.000000000 +0200
-+++ ppp-2.4.4/chat/Makefile.linux 2009-06-05 19:12:00.000000000 +0200
-@@ -25,7 +25,7 @@ chat.o: chat.c
+--- ppp-2.4.5.orig/chat/Makefile.linux 2009-11-16 23:26:07.000000000 +0100
++++ ppp-2.4.5/chat/Makefile.linux 2011-01-16 15:56:59.000000000 +0100
+@@ -10,22 +10,23 @@ CDEF3= -UNO_SLEEP # Use the usleep fun
+ CDEF4= -DFNDELAY=O_NDELAY # Old name value
+ CDEFS= $(CDEF1) $(CDEF2) $(CDEF3) $(CDEF4)
+
+-COPTS= -O2 -g -pipe
+-CFLAGS= $(COPTS) $(CDEFS)
++CPPFLAGS?=
++CFLAGS?=-O2 -g -pipe
++LDFLAGS?=
+
+ INSTALL= install
+
+ all: chat
+
+ chat: chat.o
+- $(CC) -o chat chat.o
++ $(CC) $(LDFLAGS) -o chat chat.o
+
+ chat.o: chat.c
+- $(CC) -c $(CFLAGS) -o chat.o chat.c
++ $(CC) -c $(CPPFLAGS) $(CFLAGS) -o chat.o chat.c
install: chat
mkdir -p $(BINDIR) $(MANDIR)
diff --git a/package/ppp/patches/patch-include_linux_ppp-comp_h b/package/ppp/patches/patch-include_linux_ppp-comp_h
deleted file mode 100644
index 4ffaea45c..000000000
--- a/package/ppp/patches/patch-include_linux_ppp-comp_h
+++ /dev/null
@@ -1,63 +0,0 @@
---- ppp-2.4.4.orig/include/linux/ppp-comp.h 2002-12-06 10:49:15.000000000 +0100
-+++ ppp-2.4.4/include/linux/ppp-comp.h 2009-06-05 19:12:00.000000000 +0200
-@@ -36,7 +36,7 @@
- */
-
- /*
-- * ==FILEVERSION 20020319==
-+ * ==FILEVERSION 20020715==
- *
- * NOTE TO MAINTAINERS:
- * If you modify this file at all, please set the above date.
-@@ -86,7 +86,7 @@ struct compressor {
-
- /* Compress a packet */
- int (*compress) (void *state, unsigned char *rptr,
-- unsigned char *obuf, int isize, int osize);
-+ unsigned char *obuf, int isize, int osize);
-
- /* Return compression statistics */
- void (*comp_stat) (void *state, struct compstat *stats);
-@@ -107,7 +107,7 @@ struct compressor {
-
- /* Decompress a packet. */
- int (*decompress) (void *state, unsigned char *ibuf, int isize,
-- unsigned char *obuf, int osize);
-+ unsigned char *obuf, int osize);
-
- /* Update state for an incompressible packet received */
- void (*incomp) (void *state, unsigned char *ibuf, int icnt);
-@@ -288,6 +288,33 @@ struct compressor {
- opts |= MPPE_OPT_UNKNOWN; \
- } while (/* CONSTCOND */ 0)
-
-+/* MPPE/MPPC definitions by J.D.*/
-+#define MPPE_STATELESS MPPE_H_BIT /* configuration bit H */
-+#define MPPE_40BIT MPPE_L_BIT /* configuration bit L */
-+#define MPPE_56BIT MPPE_M_BIT /* configuration bit M */
-+#define MPPE_128BIT MPPE_S_BIT /* configuration bit S */
-+#define MPPE_MPPC MPPE_C_BIT /* configuration bit C */
-+
-+/*
-+ * Definitions for Stac LZS.
-+ */
-+
-+#define CI_LZS 17 /* config option for Stac LZS */
-+#define CILEN_LZS 5 /* length of config option */
-+
-+#define LZS_OVHD 4 /* max. LZS overhead */
-+#define LZS_HIST_LEN 2048 /* LZS history size */
-+#define LZS_MAX_CCOUNT 0x0FFF /* max. coherency counter value */
-+
-+#define LZS_MODE_NONE 0
-+#define LZS_MODE_LCB 1
-+#define LZS_MODE_CRC 2
-+#define LZS_MODE_SEQ 3
-+#define LZS_MODE_EXT 4
-+
-+#define LZS_EXT_BIT_FLUSHED 0x80 /* bit A */
-+#define LZS_EXT_BIT_COMP 0x20 /* bit C */
-+
- /*
- * Definitions for other, as yet unsupported, compression methods.
- */
diff --git a/package/ppp/patches/patch-include_net_ppp-comp_h b/package/ppp/patches/patch-include_net_ppp-comp_h
deleted file mode 100644
index 239cf1443..000000000
--- a/package/ppp/patches/patch-include_net_ppp-comp_h
+++ /dev/null
@@ -1,36 +0,0 @@
---- ppp-2.4.4.orig/include/net/ppp-comp.h 2002-12-06 10:49:15.000000000 +0100
-+++ ppp-2.4.4/include/net/ppp-comp.h 2009-06-05 19:12:00.000000000 +0200
-@@ -255,6 +255,33 @@ struct compressor {
- opts |= MPPE_OPT_UNKNOWN; \
- } while (/* CONSTCOND */ 0)
-
-+/* MPPE/MPPC definitions by J.D.*/
-+#define MPPE_STATELESS MPPE_H_BIT /* configuration bit H */
-+#define MPPE_40BIT MPPE_L_BIT /* configuration bit L */
-+#define MPPE_56BIT MPPE_M_BIT /* configuration bit M */
-+#define MPPE_128BIT MPPE_S_BIT /* configuration bit S */
-+#define MPPE_MPPC MPPE_C_BIT /* configuration bit C */
-+
-+/*
-+ * Definitions for Stac LZS.
-+ */
-+
-+#define CI_LZS 17 /* config option for Stac LZS */
-+#define CILEN_LZS 5 /* length of config option */
-+
-+#define LZS_OVHD 4 /* max. LZS overhead */
-+#define LZS_HIST_LEN 2048 /* LZS history size */
-+#define LZS_MAX_CCOUNT 0x0FFF /* max. coherency counter value */
-+
-+#define LZS_MODE_NONE 0
-+#define LZS_MODE_LCB 1
-+#define LZS_MODE_CRC 2
-+#define LZS_MODE_SEQ 3
-+#define LZS_MODE_EXT 4
-+
-+#define LZS_EXT_BIT_FLUSHED 0x80 /* bit A */
-+#define LZS_EXT_BIT_COMP 0x20 /* bit C */
-+
- /*
- * Definitions for other, as yet unsupported, compression methods.
- */
diff --git a/package/ppp/patches/patch-pppd_Makefile_linux b/package/ppp/patches/patch-pppd_Makefile_linux
index 32453b249..a447ae1ea 100644
--- a/package/ppp/patches/patch-pppd_Makefile_linux
+++ b/package/ppp/patches/patch-pppd_Makefile_linux
@@ -1,6 +1,31 @@
---- ppp-2.4.4.orig/pppd/Makefile.linux 2006-06-04 07:07:46.000000000 +0200
-+++ ppp-2.4.4/pppd/Makefile.linux 2009-06-05 19:12:00.000000000 +0200
-@@ -48,7 +48,7 @@ MPPE=y
+--- ppp-2.4.5.orig/pppd/Makefile.linux 2009-11-16 23:26:07.000000000 +0100
++++ ppp-2.4.5/pppd/Makefile.linux 2011-01-16 17:09:40.000000000 +0100
+@@ -2,12 +2,7 @@
+ # pppd makefile for Linux
+ # $Id: Makefile.linux,v 1.70 2007/06/19 02:08:34 carlsonj Exp $
+ #
+-
+-# Default installation locations
+-DESTDIR = $(INSTROOT)@DESTDIR@
+-BINDIR = $(DESTDIR)/sbin
+-MANDIR = $(DESTDIR)/share/man/man8
+-INCDIR = $(DESTDIR)/include
++include ../makedefs.linux
+
+ TARGETS = pppd
+
+@@ -30,10 +25,6 @@ ifeq (.depend,$(wildcard .depend))
+ include .depend
+ endif
+
+-# CC = gcc
+-#
+-COPTS = -O2 -pipe -Wall -g
+-LIBS =
+
+ # Uncomment the next 2 lines to include support for Microsoft's
+ # MS-CHAP authentication protocol. Also, edit plugins/radius/Makefile.linux.
+@@ -48,7 +39,7 @@ MPPE=y
# Uncomment the next line to include support for PPP packet filtering.
# This requires that the libpcap library and headers be installed
# and that the kernel driver support PPP packet filtering.
@@ -9,7 +34,7 @@
# Uncomment the next line to enable multilink PPP (enabled by default)
# Linux distributions: Please leave multilink ENABLED in your builds
-@@ -58,9 +58,9 @@ HAVE_MULTILINK=y
+@@ -58,9 +49,9 @@ HAVE_MULTILINK=y
# Uncomment the next line to enable the TDB database (enabled by default.)
# If you enable multilink, then TDB is automatically enabled also.
# Linux distributions: Please leave TDB ENABLED in your builds.
@@ -21,16 +46,22 @@
#USE_PAM=y
#HAVE_INET6=y
-@@ -77,7 +77,7 @@ MAXOCTETS=y
+@@ -75,11 +66,10 @@ PLUGIN=y
- INCLUDE_DIRS= -I../include
+ MAXOCTETS=y
+-INCLUDE_DIRS= -I../include
+-
-COMPILE_FLAGS= -DHAVE_PATHS_H -DIPX_CHANGE -DHAVE_MMAP
-+COMPILE_FLAGS= -DHAVE_PATHS_H -DHAVE_MMAP
++CPPFLAGS += -I../include
++CPPFLAGS += -DHAVE_PATHS_H -DHAVE_MMAP
- CFLAGS= $(COPTS) $(COMPILE_FLAGS) $(INCLUDE_DIRS) '-DDESTDIR="@DESTDIR@"'
+-CFLAGS= $(COPTS) $(COMPILE_FLAGS) $(INCLUDE_DIRS) '-DDESTDIR="@DESTDIR@"'
++CFLAGS+= $(COPTS) $(COMPILE_FLAGS) $(INCLUDE_DIRS) '-DDESTDIR="@DESTDIR@"'
-@@ -99,7 +99,7 @@ ifdef USE_SRP
+ ifdef CHAPMS
+ CFLAGS += -DCHAPMS=1
+@@ -99,7 +89,7 @@ ifdef USE_SRP
CFLAGS += -DUSE_SRP -DOPENSSL -I/usr/local/ssl/include
LIBS += -lsrp -L/usr/local/ssl/lib -lcrypto
TARGETS += srp-entry
@@ -39,7 +70,7 @@
MANPAGES += srp-entry.8
EXTRACLEAN += srp-entry.o
NEEDDES=y
-@@ -117,10 +117,8 @@ CFLAGS += -DHAS_SHADOW
+@@ -117,10 +107,8 @@ CFLAGS += -DHAS_SHADOW
#LIBS += -lshadow $(LIBS)
endif
@@ -50,7 +81,7 @@
ifdef NEEDDES
ifndef USE_CRYPT
-@@ -200,7 +198,7 @@ all: $(TARGETS)
+@@ -200,16 +188,16 @@ all: $(TARGETS)
install: pppd
mkdir -p $(BINDIR) $(MANDIR)
$(EXTRAINSTALL)
@@ -59,3 +90,20 @@
if chgrp pppusers $(BINDIR)/pppd 2>/dev/null; then \
chmod o-rx,u+s $(BINDIR)/pppd; fi
$(INSTALL) -c -m 444 pppd.8 $(MANDIR)
+
+ pppd: $(PPPDOBJS)
+- $(CC) $(CFLAGS) $(LDFLAGS) -o pppd $(PPPDOBJS) $(LIBS)
++ $(CC) $(LDFLAGS) -o pppd $(PPPDOBJS) $(LIBS)
+
+ srp-entry: srp-entry.c
+- $(CC) $(CFLAGS) $(LDFLAGS) -o $@ srp-entry.c $(LIBS)
++ $(CC) $(LDFLAGS) -o $@ srp-entry.c $(LIBS)
+
+ install-devel:
+ mkdir -p $(INCDIR)/pppd
+@@ -219,4 +207,4 @@ clean:
+ rm -f $(PPPDOBJS) $(EXTRACLEAN) $(TARGETS) *~ #* core
+
+ depend:
+- $(CPP) -M $(CFLAGS) $(PPPDSRCS) >.depend
++ $(CPP) -M $(CPPFLAGS) $(CFLAGS) $(PPPDSRCS) >.depend
diff --git a/package/ppp/patches/patch-pppd_chap_ms_c b/package/ppp/patches/patch-pppd_chap_ms_c
index c20fc8163..b829221d4 100644
--- a/package/ppp/patches/patch-pppd_chap_ms_c
+++ b/package/ppp/patches/patch-pppd_chap_ms_c
@@ -1,6 +1,6 @@
---- ppp-2.4.4.orig/pppd/chap_ms.c 2006-05-21 13:56:40.000000000 +0200
-+++ ppp-2.4.4/pppd/chap_ms.c 2009-06-05 19:12:00.000000000 +0200
-@@ -897,13 +897,17 @@ set_mppe_enc_types(int policy, int types
+--- ppp-2.4.5.orig/pppd/chap_ms.c 2009-11-16 23:26:07.000000000 +0100
++++ ppp-2.4.5/pppd/chap_ms.c 2011-01-16 15:51:05.000000000 +0100
+@@ -898,13 +898,17 @@ set_mppe_enc_types(int policy, int types
/*
* Disable undesirable encryption types. Note that we don't ENABLE
* any encryption types, to avoid overriding manual configuration.
diff --git a/package/ppp/patches/patch-pppd_main_c b/package/ppp/patches/patch-pppd_main_c
index 22e6a64f8..630420deb 100644
--- a/package/ppp/patches/patch-pppd_main_c
+++ b/package/ppp/patches/patch-pppd_main_c
@@ -1,5 +1,5 @@
---- ppp-2.4.4.orig/pppd/main.c 2006-06-04 05:52:50.000000000 +0200
-+++ ppp-2.4.4/pppd/main.c 2009-06-05 19:12:00.000000000 +0200
+--- ppp-2.4.5.orig/pppd/main.c 2009-11-16 23:26:07.000000000 +0100
++++ ppp-2.4.5/pppd/main.c 2011-01-16 15:51:05.000000000 +0100
@@ -90,6 +90,7 @@
#include <sys/socket.h>
#include <netinet/in.h>
@@ -8,7 +8,7 @@
#include "pppd.h"
#include "magic.h"
-@@ -227,6 +228,7 @@ static struct subprocess *children;
+@@ -228,6 +229,7 @@ static struct subprocess *children;
/* Prototypes for procedures local to this file. */
@@ -16,7 +16,7 @@
static void setup_signals __P((void));
static void create_pidfile __P((int pid));
static void create_linkpidfile __P((int pid));
-@@ -529,6 +531,7 @@ main(argc, argv)
+@@ -530,6 +532,7 @@ main(argc, argv)
info("Starting link");
}
@@ -24,7 +24,7 @@
gettimeofday(&start_time, NULL);
script_unsetenv("CONNECT_TIME");
script_unsetenv("BYTES_SENT");
-@@ -1262,6 +1265,36 @@ struct callout {
+@@ -1263,6 +1266,36 @@ struct callout {
static struct callout *callout = NULL; /* Callout list */
static struct timeval timenow; /* Current time */
@@ -61,7 +61,7 @@
/*
* timeout - Schedule a timeout.
-@@ -1332,6 +1365,8 @@ calltimeout()
+@@ -1333,6 +1366,8 @@ calltimeout()
{
struct callout *p;
@@ -70,7 +70,7 @@
while (callout != NULL) {
p = callout;
-@@ -1359,6 +1394,8 @@ timeleft(tvp)
+@@ -1360,6 +1395,8 @@ timeleft(tvp)
{
if (callout == NULL)
return NULL;
diff --git a/package/ppp/patches/patch-pppd_plugins_Makefile_linux b/package/ppp/patches/patch-pppd_plugins_Makefile_linux
new file mode 100644
index 000000000..9f78f3d19
--- /dev/null
+++ b/package/ppp/patches/patch-pppd_plugins_Makefile_linux
@@ -0,0 +1,29 @@
+--- ppp-2.4.5.orig/pppd/plugins/Makefile.linux 2009-11-16 23:26:07.000000000 +0100
++++ ppp-2.4.5/pppd/plugins/Makefile.linux 2011-01-16 17:14:34.000000000 +0100
+@@ -1,13 +1,8 @@
+-#CC = gcc
+-COPTS = -O2 -g
+-CFLAGS = $(COPTS) -I.. -I../../include -fPIC
+-LDFLAGS = -shared
+-INSTALL = install
++include ../../makedefs.linux
+
+-DESTDIR = $(INSTROOT)@DESTDIR@
+-BINDIR = $(DESTDIR)/sbin
+-MANDIR = $(DESTDIR)/share/man/man8
+-LIBDIR = $(DESTDIR)/lib/pppd/$(VERSION)
++CPPFLAGS += -I.. -I../../include
++CFLAGS += -fPIC
++LDFLAGS += -shared
+
+ SUBDIRS := rp-pppoe pppoatm pppol2tp
+ # Uncomment the next line to include the radius authentication plugin
+@@ -23,7 +18,7 @@ all: $(PLUGINS)
+ for d in $(SUBDIRS); do $(MAKE) $(MFLAGS) -C $$d all; done
+
+ %.so: %.c
+- $(CC) -o $@ $(LDFLAGS) $(CFLAGS) $^
++ $(CC) -o $@ $(LDFLAGS) $(CPPFLAGS) $(CFLAGS) $^
+
+ VERSION = $(shell awk -F '"' '/VERSION/ { print $$2; }' ../patchlevel.h)
+
diff --git a/package/ppp/patches/patch-pppd_plugins_pppoatm_Makefile_linux b/package/ppp/patches/patch-pppd_plugins_pppoatm_Makefile_linux
new file mode 100644
index 000000000..e7fb3f5e7
--- /dev/null
+++ b/package/ppp/patches/patch-pppd_plugins_pppoatm_Makefile_linux
@@ -0,0 +1,36 @@
+--- ppp-2.4.5.orig/pppd/plugins/pppoatm/Makefile.linux 2009-11-16 23:26:07.000000000 +0100
++++ ppp-2.4.5/pppd/plugins/pppoatm/Makefile.linux 2011-01-16 21:12:55.000000000 +0100
+@@ -1,13 +1,10 @@
+-#CC = gcc
+-COPTS = -O2 -g
+-CFLAGS = $(COPTS) -I../.. -I../../../include -fPIC
+-LDFLAGS = -shared
+-INSTALL = install
++include ../../../makedefs.linux
+
+-#***********************************************************************
++CPPFLAGS += -I../.. -I../../../include
++CFLAGS += -fPIC
++LDFLAGS += -shared
+
+-DESTDIR = $(INSTROOT)@DESTDIR@
+-LIBDIR = $(DESTDIR)/lib/pppd/$(VERSION)
++#***********************************************************************
+
+ VERSION = $(shell awk -F '"' '/VERSION/ { print $$2; }' ../../patchlevel.h)
+
+@@ -33,7 +30,7 @@ endif
+ all: $(PLUGIN)
+
+ $(PLUGIN): $(PLUGIN_OBJS)
+- $(CC) $(CFLAGS) -o $@ -shared $^ $(LIBS)
++ $(CC) $(LDFLAGS) -o $@ $^ $(LIBS)
+
+ install: all
+ $(INSTALL) -d -m 755 $(LIBDIR)
+@@ -43,4 +40,4 @@ clean:
+ rm -f *.o *.so
+
+ %.o: %.c
+- $(CC) $(CFLAGS) -c -o $@ $<
++ $(CC) $(CPPFLAGS) $(CFLAGS) -c -o $@ $<
diff --git a/package/ppp/patches/patch-pppd_plugins_pppol2tp_Makefile_linux b/package/ppp/patches/patch-pppd_plugins_pppol2tp_Makefile_linux
new file mode 100644
index 000000000..4c46c5971
--- /dev/null
+++ b/package/ppp/patches/patch-pppd_plugins_pppol2tp_Makefile_linux
@@ -0,0 +1,41 @@
+--- ppp-2.4.5.orig/pppd/plugins/pppol2tp/Makefile.linux 2009-11-16 23:26:07.000000000 +0100
++++ ppp-2.4.5/pppd/plugins/pppol2tp/Makefile.linux 2011-01-16 21:32:19.000000000 +0100
+@@ -1,13 +1,10 @@
+-#CC = gcc
+-COPTS = -O2 -g
+-CFLAGS = $(COPTS) -I. -I../.. -I../../../include -fPIC
+-LDFLAGS = -shared
+-INSTALL = install
++include ../../../makedefs.linux
+
+-#***********************************************************************
++CPPFLAGS += -I. -I../.. -I../../../include
++#CFLAGS += -fPIC
++#LDFLAGS += -shared
+
+-DESTDIR = @DESTDIR@
+-LIBDIR = $(DESTDIR)/lib/pppd/$(VERSION)
++#***********************************************************************
+
+ VERSION = $(shell awk -F '"' '/VERSION/ { print $$2; }' ../../patchlevel.h)
+
+@@ -16,7 +13,11 @@ PLUGINS := pppol2tp.so openl2tp.so
+ all: $(PLUGINS)
+
+ %.so: %.o
+- $(CC) $(CFLAGS) -o $@ -shared $^ $(LIBS)
++ $(CC) $(LDFLAGS) -o $@ $^ $(LIBS)
++ echo $(LDFLAGS)
++
++%.o: %.c
++ $(CC) $(CPPFLAGS) $(CFLAGS) -c -o $@ $<
+
+ install: all
+ $(INSTALL) -d -m 755 $(LIBDIR)
+@@ -25,5 +26,4 @@ install: all
+ clean:
+ rm -f *.o *.so
+
+-%.o: %.c
+- $(CC) $(CFLAGS) -c -o $@ $<
++.PHONY: clean
diff --git a/package/ppp/patches/patch-pppd_plugins_radius_Makefile_linux b/package/ppp/patches/patch-pppd_plugins_radius_Makefile_linux
index bee2a80cf..d01aeb86c 100644
--- a/package/ppp/patches/patch-pppd_plugins_radius_Makefile_linux
+++ b/package/ppp/patches/patch-pppd_plugins_radius_Makefile_linux
@@ -1,16 +1,28 @@
---- ppp-2.4.4.orig/pppd/plugins/radius/Makefile.linux 2006-06-04 07:04:14.000000000 +0200
-+++ ppp-2.4.4/pppd/plugins/radius/Makefile.linux 2009-06-05 19:12:00.000000000 +0200
-@@ -12,7 +12,8 @@ VERSION = $(shell awk -F '"' '/VERSION/
- INSTALL = install
+--- ppp-2.4.5.orig/pppd/plugins/radius/Makefile.linux 2009-11-16 23:26:07.000000000 +0100
++++ ppp-2.4.5/pppd/plugins/radius/Makefile.linux 2011-01-16 21:35:47.000000000 +0100
+@@ -1,18 +1,14 @@
+ # Makefile for RADIUS plugin
+ #
+ # Copyright 2002 Roaring Penguin Software Inc.
+-#
+
+-DESTDIR = $(INSTROOT)@DESTDIR@
+-MANDIR = $(DESTDIR)/share/man/man8
+-LIBDIR = $(DESTDIR)/lib/pppd/$(VERSION)
++include ../../../makedefs.linux
+
+-VERSION = $(shell awk -F '"' '/VERSION/ { print $$2; }' ../../patchlevel.h)
++CPPFLAGS+=-I. -I../.. -I../../../include -DRC_LOG_FACILITY=LOG_DAEMON
+
+-INSTALL = install
++VERSION = $(shell awk -F '"' '/VERSION/ { print $$2; }' ../../patchlevel.h)
PLUGIN=radius.so radattr.so radrealms.so
-CFLAGS=-I. -I../.. -I../../../include -O2 -fPIC -DRC_LOG_FACILITY=LOG_DAEMON
-+COPTS = -O2
-+CFLAGS=-I. -I../.. -I../../../include $(COPTS) -fPIC -DRC_LOG_FACILITY=LOG_DAEMON
# Uncomment the next line to include support for Microsoft's
# MS-CHAP authentication protocol.
-@@ -36,9 +37,9 @@ all: $(PLUGIN)
+@@ -36,25 +32,26 @@ all: $(PLUGIN)
install: all
$(INSTALL) -d -m 755 $(LIBDIR)
@@ -23,9 +35,21 @@
$(INSTALL) -c -m 444 pppd-radius.8 $(MANDIR)
$(INSTALL) -c -m 444 pppd-radattr.8 $(MANDIR)
-@@ -54,7 +55,7 @@ radrealms.so: radrealms.o
+ radius.so: radius.o libradiusclient.a
+- $(CC) -o radius.so -shared radius.o libradiusclient.a
++ $(CC) $(LDFLAGS) -o radius.so radius.o libradiusclient.a
+
+ radattr.so: radattr.o
+- $(CC) -o radattr.so -shared radattr.o
++ $(CC) $(LDFLAGS) -o radattr.so radattr.o
+
+ radrealms.so: radrealms.o
+- $(CC) -o radrealms.so -shared radrealms.o
++ $(CC) $(LDFLAGS) -o radrealms.so radrealms.o
+
CLIENTOBJS = avpair.o buildreq.o config.o dict.o ip_util.o \
clientid.o sendserver.o lock.o util.o md5.o
++
libradiusclient.a: $(CLIENTOBJS)
- $(AR) rv $@ $?
+ $(TARGET_AR) rcsv $@ $?
diff --git a/package/ppp/patches/patch-pppd_plugins_rp-pppoe_Makefile_linux b/package/ppp/patches/patch-pppd_plugins_rp-pppoe_Makefile_linux
new file mode 100644
index 000000000..09d845f6a
--- /dev/null
+++ b/package/ppp/patches/patch-pppd_plugins_rp-pppoe_Makefile_linux
@@ -0,0 +1,80 @@
+--- ppp-2.4.5.orig/pppd/plugins/rp-pppoe/Makefile.linux 2009-11-16 23:26:07.000000000 +0100
++++ ppp-2.4.5/pppd/plugins/rp-pppoe/Makefile.linux 2011-01-16 21:38:08.000000000 +0100
+@@ -1,6 +1,3 @@
+-# Generated automatically from Makefile.in by configure.
+-#***********************************************************************
+-#
+ # Makefile
+ #
+ # Makefile for Roaring Penguin's Linux PPPoE plugin.
+@@ -13,52 +10,50 @@
+ #
+ # $Id: Makefile.linux,v 1.8 2008/06/09 08:34:23 paulus Exp $
+ #***********************************************************************
+-
+-DESTDIR = $(INSTROOT)@DESTDIR@
+-BINDIR = $(DESTDIR)/sbin
+-LIBDIR = $(DESTDIR)/lib/pppd/$(PPPDVERSION)
+-
+-PPPDVERSION = $(shell awk -F '"' '/VERSION/ { print $$2; }' ../../patchlevel.h)
+-
+-INSTALL = install
++include ../../../makedefs.linux
+
+ # Version is set ONLY IN THE MAKEFILE! Don't delete this!
+ RP_VERSION=3.8p
+
+-COPTS=-O2 -g
+-CFLAGS=$(COPTS) -I../../../include '-DRP_VERSION="$(RP_VERSION)"'
++CPPFLAGS += -I../../.. -I../../../include '-DRP_VERSION="$(RP_VERSION)"'
++CFLAGS += -fPIC
++LDFLAGS += -shared
++
++VERSION = $(shell awk -F '"' '/VERSION/ { print $$2; }' ../../patchlevel.h)
++
+ all: rp-pppoe.so pppoe-discovery
+
+ pppoe-discovery: pppoe-discovery.o debug.o
+- $(CC) -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
++ $(CC) $(CPPFLAGS) $(CFLAGS) -c -o $@ $^
+
+ debug.o: debug.c
+- $(CC) $(CFLAGS) -c -o debug.o debug.c
++ $(CC) $(CPPFLAGS) $(CFLAGS) -c -o $@ $^
+
+ rp-pppoe.so: plugin.o discovery.o if.o common.o
+- $(CC) -o rp-pppoe.so -shared plugin.o discovery.o if.o common.o
++ $(CC) $(LDFLAGS) -o $@ $^
+
+ install: all
+ $(INSTALL) -d -m 755 $(LIBDIR)
+- $(INSTALL) -s -c -m 4550 rp-pppoe.so $(LIBDIR)
++ $(INSTALL) -c -m 4550 rp-pppoe.so $(LIBDIR)
+ $(INSTALL) -d -m 755 $(BINDIR)
+- $(INSTALL) -s -c -m 555 pppoe-discovery $(BINDIR)
++ $(INSTALL) -c -m 555 pppoe-discovery $(BINDIR)
+
+ clean:
+ rm -f *.o *.so pppoe-discovery
+
+ plugin.o: plugin.c
+- $(CC) $(CFLAGS) -I../../.. -c -o plugin.o -fPIC plugin.c
++ $(CC) $(CPPFLAGS) $(CFLAGS) -c -o plugin.o plugin.c
+
+ discovery.o: discovery.c
+- $(CC) $(CFLAGS) -I../../.. -c -o discovery.o -fPIC discovery.c
++ $(CC) $(CPPFLAGS) $(CFLAGS) -c -o discovery.o discovery.c
+
+ if.o: if.c
+- $(CC) $(CFLAGS) -I../../.. -c -o if.o -fPIC if.c
++ $(CC) $(CPPFLAGS) $(CFLAGS) -c -o if.o if.c
+
+ common.o: common.c
+- $(CC) $(CFLAGS) -I../../.. -c -o common.o -fPIC common.c
++ $(CC) $(CPPFLAGS) $(CFLAGS) -c -o common.o common.c
+
++.PHONY: clean
diff --git a/package/ppp/patches/patch-pppd_pppd_8 b/package/ppp/patches/patch-pppd_pppd_8
index 4e19f91d2..c877824eb 100644
--- a/package/ppp/patches/patch-pppd_pppd_8
+++ b/package/ppp/patches/patch-pppd_pppd_8
@@ -1,6 +1,6 @@
---- ppp-2.4.4.orig/pppd/pppd.8 2006-06-16 02:01:23.000000000 +0200
-+++ ppp-2.4.4/pppd/pppd.8 2009-06-05 19:12:00.000000000 +0200
-@@ -627,9 +627,29 @@ control, as for the \fIcrtscts\fR option
+--- ppp-2.4.5.orig/pppd/pppd.8 2009-11-16 23:26:07.000000000 +0100
++++ ppp-2.4.5/pppd/pppd.8 2011-01-16 15:51:05.000000000 +0100
+@@ -638,9 +638,29 @@ control, as for the \fIcrtscts\fR option
Enables the use of PPP multilink; this is an alias for the `multilink'
option. This option is currently only available under Linux.
.TP
@@ -33,7 +33,7 @@
.TP
.B mpshortseq
Enables the use of short (12-bit) sequence numbers in multilink
-@@ -767,17 +787,11 @@ peer is buggy.
+@@ -778,17 +798,11 @@ peer is buggy.
Disables the use of PPP multilink. This option is currently only
available under Linux.
.TP
@@ -55,7 +55,7 @@
.TP
.B nompshortseq
Disables the use of short (12-bit) sequence numbers in the PPP
-@@ -958,19 +972,6 @@ peer using PAP.
+@@ -980,19 +994,6 @@ peer using PAP.
Require the peer to authenticate itself using CHAP [Challenge
Handshake Authentication Protocol] authentication.
.TP
diff --git a/package/ppp/patches/patch-pppdump_Makefile_linux b/package/ppp/patches/patch-pppdump_Makefile_linux
index 10a5e2728..796548ab7 100644
--- a/package/ppp/patches/patch-pppdump_Makefile_linux
+++ b/package/ppp/patches/patch-pppdump_Makefile_linux
@@ -1,19 +1,33 @@
---- ppp-2.4.4.orig/pppdump/Makefile.linux 2006-06-04 07:04:14.000000000 +0200
-+++ ppp-2.4.4/pppdump/Makefile.linux 2009-06-05 19:12:00.000000000 +0200
-@@ -2,7 +2,8 @@ DESTDIR = $(INSTROOT)@DESTDIR@
- BINDIR = $(DESTDIR)/sbin
- MANDIR = $(DESTDIR)/share/man/man8
+--- ppp-2.4.5.orig/pppdump/Makefile.linux 2009-11-16 23:26:07.000000000 +0100
++++ ppp-2.4.5/pppdump/Makefile.linux 2011-01-16 16:58:39.000000000 +0100
+@@ -1,21 +1,19 @@
+-DESTDIR = $(INSTROOT)@DESTDIR@
+-BINDIR = $(DESTDIR)/sbin
+-MANDIR = $(DESTDIR)/share/man/man8
++include ../makedefs.linux
-CFLAGS= -O -I../include/net
-+COPTS = -O
-+CFLAGS= $(COPTS) -I../include/net
++CPPFLAGS+= -I../include/net
OBJS = pppdump.o bsd-comp.o deflate.o zlib.o
- INSTALL= install
-@@ -17,5 +18,5 @@ clean:
+-INSTALL= install
+-
+ all: pppdump
+
+ pppdump: $(OBJS)
+- $(CC) -o pppdump $(OBJS)
+-
+-clean:
+- rm -f pppdump $(OBJS) *~
++ $(CC) $(LDFLAGS) -o pppdump $(OBJS)
install:
mkdir -p $(BINDIR) $(MANDIR)
- $(INSTALL) -s -c pppdump $(BINDIR)
+ $(INSTALL) -c pppdump $(BINDIR)
$(INSTALL) -c -m 444 pppdump.8 $(MANDIR)
++
++clean:
++ rm -f pppdump $(OBJS) *~
++
++.PHONY: clean
diff --git a/package/ppp/patches/patch-pppstats_Makefile_linux b/package/ppp/patches/patch-pppstats_Makefile_linux
index 8c02431dd..81dfd920b 100644
--- a/package/ppp/patches/patch-pppstats_Makefile_linux
+++ b/package/ppp/patches/patch-pppstats_Makefile_linux
@@ -1,11 +1,48 @@
---- ppp-2.4.4.orig/pppstats/Makefile.linux 2006-06-04 07:07:46.000000000 +0200
-+++ ppp-2.4.4/pppstats/Makefile.linux 2009-06-05 19:12:00.000000000 +0200
-@@ -22,7 +22,7 @@ all: pppstats
+--- ppp-2.4.5.orig/pppstats/Makefile.linux 2009-11-16 23:26:07.000000000 +0100
++++ ppp-2.4.5/pppstats/Makefile.linux 2011-01-16 17:11:22.000000000 +0100
+@@ -1,36 +1,27 @@
+ #
+ # pppstats makefile
+ # $Id: Makefile.linux,v 1.9 2006/06/04 05:07:46 paulus Exp $
+-#
+-DESTDIR = $(INSTROOT)@DESTDIR@
+-BINDIR = $(DESTDIR)/sbin
+-MANDIR = $(DESTDIR)/share/man/man8
++include ../makedefs.linux
++
++CPPFLAGS += -I../include
+ PPPSTATSRCS = pppstats.c
+ PPPSTATOBJS = pppstats.o
+
+-#CC = gcc
+-COPTS = -O
+-COMPILE_FLAGS = -I../include
+-LIBS =
+-
+-INSTALL= install
+-
+-CFLAGS = $(COPTS) $(COMPILE_FLAGS)
+-
+ all: pppstats
+
++pppstats: $(PPPSTATSRCS)
++ $(CC) $(CPPFLAGS) $(CFLAGS) $(LDLAGS) -o pppstats pppstats.c $(LIBS)
++
install: pppstats
-mkdir -p $(MANDIR)
- $(INSTALL) -s -c pppstats $(BINDIR)
+ $(INSTALL) -c pppstats $(BINDIR)
$(INSTALL) -c -m 444 pppstats.8 $(MANDIR)
- pppstats: $(PPPSTATSRCS)
+-pppstats: $(PPPSTATSRCS)
+- $(CC) $(CFLAGS) -o pppstats pppstats.c $(LIBS)
+-
+ clean:
+ rm -f pppstats *~ #* core
+
+ depend:
+ cpp -M $(CFLAGS) $(PPPSTATSRCS) >.depend
+-# makedepend $(CFLAGS) $(PPPSTATSRCS)
++
++.PHONY: clean