1 # Makefile for RADIUS plugin
3 # Copyright 2002 Roaring Penguin Software Inc.
7 MANDIR = $(DESTDIR)/share/man/man8
8 LIBDIR = $(DESTDIR)/lib/pppd/$(VERSION)
12 PLUGIN=radius.so radattr.so radrealms.so
13 CFLAGS=-I../.. -I../../../include -Iradiusclient/include -O2
15 # Uncomment the next line to include support for Microsoft's
16 # MS-CHAP authentication protocol.
18 # Uncomment the next line to include support for MPPE.
20 # Uncomment the next lint to include support for traffic limiting
30 CFLAGS += -DMAXOCTETS=1
36 $(MAKE) $(MFLAGS) -C radiusclient install
37 $(INSTALL) -d -m 755 $(LIBDIR)
38 $(INSTALL) -s -c -m 755 radius.so $(LIBDIR)
39 $(INSTALL) -s -c -m 755 radattr.so $(LIBDIR)
40 $(INSTALL) -s -c -m 755 radrealms.so $(LIBDIR)
41 $(INSTALL) -c -m 444 pppd-radius.8 $(MANDIR)
42 $(INSTALL) -c -m 444 pppd-radattr.8 $(MANDIR)
44 radius.so: radiusclient/lib/.libs/libradiusclient.a radius.o
45 gcc -o radius.so -shared radius.o radiusclient/lib/.libs/libradiusclient.a
48 gcc -o radattr.so -shared radattr.o
50 radrealms.so: radrealms.o
51 gcc -o radrealms.so -shared radrealms.o
54 gcc $(CFLAGS) -c -o radius.o -fPIC radius.c
57 gcc $(CFLAGS) -c -o radattr.o -fPIC radattr.c
59 radrealms.o: radrealms.c
60 gcc $(CFLAGS) -c -o radrealms.o -fPIC radrealms.c
62 radiusclient/lib/.libs/libradiusclient.a:
63 test -r radiusclient/Makefile || \
65 ./configure --prefix=@PREFIX@ \
66 --sysconfdir=@SYSCONF@ \
69 $(MAKE) -C radiusclient
72 $(MAKE) $(MFLAGS) -C radiusclient clean
77 $(MAKE) $(MFLAGS) -C radiusclient distclean