]> git.ozlabs.org Git - ppp.git/blob - pppd/plugins/pppoe/Makefile.linux
Rename rp-pppoe.so plugin to pppoe.so
[ppp.git] / pppd / plugins / pppoe / Makefile.linux
1 # Generated automatically from Makefile.in by configure.
2 #***********************************************************************
3 #
4 # Makefile
5 #
6 # Makefile for Roaring Penguin's Linux PPPoE plugin.
7 # Modified for integration with pppd sources by Paul Mackerras.
8 #
9 # Copyright (C) 2001 Roaring Penguin Software Inc.
10 #
11 # This program may be distributed according to the terms of the GNU
12 # General Public License, version 2 or (at your option) any later version.
13 #
14 # $Id: Makefile.linux,v 1.8 2008/06/09 08:34:23 paulus Exp $
15 #***********************************************************************
16
17 DESTDIR = $(INSTROOT)@DESTDIR@
18 BINDIR = $(DESTDIR)/sbin
19 LIBDIR = $(DESTDIR)/lib/pppd/$(PPPDVERSION)
20
21 PPPDVERSION = $(shell awk -F '"' '/VERSION/ { print $$2; }' ../../patchlevel.h)
22
23 INSTALL = install
24 LN_S    = ln -sf
25
26 COPTS=-O2 -g
27 CFLAGS=$(COPTS) -I../../../include
28 all: pppoe.so pppoe-discovery
29
30 pppoe-discovery: pppoe-discovery.o debug.o
31         $(CC) $(LDFLAGS) -o pppoe-discovery pppoe-discovery.o debug.o
32
33 pppoe-discovery.o: pppoe-discovery.c
34         $(CC) $(CFLAGS) -I../../.. -c -o pppoe-discovery.o pppoe-discovery.c
35
36 debug.o: debug.c
37         $(CC) $(CFLAGS) -I../../.. -c -o debug.o debug.c
38
39 pppoe.so: plugin.o discovery.o if.o common.o
40         $(CC) $(LDFLAGS) -o pppoe.so -shared plugin.o discovery.o if.o common.o
41
42 install: all
43         $(INSTALL) -d -m 755 $(LIBDIR)
44         $(INSTALL) -c -m 4550 pppoe.so $(LIBDIR)
45         # Symlink for backward compatibility
46         $(LN_S) pppoe.so $(LIBDIR)/rp-pppoe.so
47         $(INSTALL) -d -m 755 $(BINDIR)
48         $(INSTALL) -c -m 555 pppoe-discovery $(BINDIR)
49
50 clean:
51         rm -f *.o *.so pppoe-discovery
52
53 plugin.o: plugin.c
54         $(CC) $(CFLAGS) -I../../.. -c -o plugin.o -fPIC plugin.c
55
56 discovery.o: discovery.c
57         $(CC) $(CFLAGS) -I../../.. -c -o discovery.o -fPIC discovery.c
58
59 if.o: if.c
60         $(CC) $(CFLAGS) -I../../.. -c -o if.o -fPIC if.c
61
62 common.o: common.c
63         $(CC) $(CFLAGS) -I../../.. -c -o common.o -fPIC common.c
64