blob: 8351654c76020122faeab76aa3d76fb03e07d89f (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
|
--- 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-21 21:29:58.118658260 +0100
@@ -1,13 +1,13 @@
-#CC = gcc
-COPTS = -O2 -g
-CFLAGS = $(COPTS) -I.. -I../../include -fPIC
-LDFLAGS = -shared
-INSTALL = install
+#
+# makefile for pppd/plugins
+#
+VERSION = $(shell awk -F '"' '/VERSION/ { print $$2; }' ../patchlevel.h)
-DESTDIR = $(INSTROOT)@DESTDIR@
-BINDIR = $(DESTDIR)/sbin
-MANDIR = $(DESTDIR)/share/man/man8
-LIBDIR = $(DESTDIR)/lib/pppd/$(VERSION)
+include ../../Makedefs.com
+
+CPPFLAGS += -I.. -I../../include
+CFLAGS += -fPIC
+LDFLAGS += -shared
SUBDIRS := rp-pppoe pppoatm pppol2tp
# Uncomment the next line to include the radius authentication plugin
@@ -23,12 +23,10 @@ all: $(PLUGINS)
for d in $(SUBDIRS); do $(MAKE) $(MFLAGS) -C $$d all; done
%.so: %.c
- $(CC) -o $@ $(LDFLAGS) $(CFLAGS) $^
-
-VERSION = $(shell awk -F '"' '/VERSION/ { print $$2; }' ../patchlevel.h)
+ $(CC) $(CPPFLAGS) $(CFLAGS) $(LDFLAGS) -o $@ $^
install: $(PLUGINS)
- $(INSTALL) -d $(LIBDIR)
+ $(INSTALL) -d -m 755 $(LIBDIR)
$(INSTALL) $? $(LIBDIR)
for d in $(SUBDIRS); do $(MAKE) $(MFLAGS) -C $$d install; done
@@ -37,5 +35,4 @@ clean:
for d in $(SUBDIRS); do $(MAKE) $(MFLAGS) -C $$d clean; done
depend:
- $(CPP) -M $(CFLAGS) *.c >.depend
- for d in $(SUBDIRS); do $(MAKE) $(MFLAGS) -C $$d depend; done
+ $(CPP) -M $(CPPFLAGS) *.c >.depend
|