]> rtime.felk.cvut.cz Git - lisovros/iproute2_canprio.git/blob - tc/Makefile
HFSC is configurable
[lisovros/iproute2_canprio.git] / tc / Makefile
1 TCOBJ=tc.o tc_qdisc.o tc_class.o tc_filter.o tc_util.o m_police.o m_estimator.o
2
3 include ../Config
4
5 TCMODULES :=
6 TCMODULES += q_fifo.o
7 TCMODULES += q_sfq.o
8 TCMODULES += q_red.o
9 TCMODULES += q_prio.o
10 TCMODULES += q_tbf.o
11 TCMODULES += q_cbq.o
12 TCMODULES += f_rsvp.o
13 TCMODULES += f_u32.o
14 TCMODULES += f_route.o
15 TCMODULES += f_fw.o
16 TCMODULES += q_dsmark.o
17 TCMODULES += q_gred.o
18 TCMODULES += f_tcindex.o
19 TCMODULES += q_ingress.o
20
21 ifeq ($(TC_CONFIG_HFSC),y)
22         TCMODULES += q_hfsc.o
23 endif
24
25 ifeq ($(TC_CONFIG_HTB),y)
26         TCMODULES += q_htb.o
27 endif
28
29 # deadmen walking
30 #TCMODULES += q_csz.o
31 #TCMODULES += q_hpfq.o
32
33 TCOBJ += $(TCMODULES)
34
35 TCLIB := tc_core.o
36 TCLIB += tc_red.o
37 TCLIB += tc_cbq.o
38 TCLIB += tc_estimator.o
39
40 TCSO :=
41 ifeq ($(TC_CONFIG_ATM),y)
42   TCSO += q_atm.so
43 endif
44
45 ifeq ($(TC_CONFIG_NETEM),y)
46   TCSO += q_netem.so
47 endif
48
49 LDLIBS += -L. -ltc -lm -ldl
50 LDFLAGS += -Wl,-export-dynamic
51
52 %.so: %.c
53         $(CC) $(CFLAGS) -shared -fpic $< -o $@
54
55 all: libtc.a tc $(TCSO)
56
57 tc: $(TCOBJ) $(LIBNETLINK) $(LIBUTIL) $(TCLIB)
58
59 libtc.a: $(TCLIB)
60         $(AR) rcs $@ $(TCLIB)
61
62 install: all
63         mkdir -p $(DESTDIR)/usr/lib/tc
64         install -m 0755 -s tc $(DESTDIR)$(SBINDIR)
65         for i in $(TCSO); do install -m 755 -s $$i $(DESTDIR)/usr/lib/tc; done
66
67 clean:
68         rm -f $(TCOBJ) $(TCLIB) libtc.a tc
69
70 q_atm.so: q_atm.c
71         $(CC) $(CFLAGS) -shared -fpic -o q_atm.so q_atm.c -latm
72
73