1SSOBJ=ss.o ssfilter.o 2LNSTATOBJ=lnstat.o lnstat_util.o 3 4TARGETS=ss nstat ifstat rtacct arpd lnstat 5 6include ../Config 7 8all: $(TARGETS) 9 10ss: $(SSOBJ) $(LIBUTIL) 11 12nstat: nstat.c 13 $(CC) $(CFLAGS) $(LDFLAGS) -o nstat nstat.c -lm 14 15ifstat: ifstat.c 16 $(CC) $(CFLAGS) $(LDFLAGS) -o ifstat ifstat.c $(LIBNETLINK) -lm 17 18rtacct: rtacct.c 19 $(CC) $(CFLAGS) $(LDFLAGS) -o rtacct rtacct.c $(LIBNETLINK) -lm 20 21arpd: arpd.c 22 $(CC) $(CFLAGS) -I$(DBM_INCLUDE) $(LDFLAGS) -o arpd arpd.c $(LIBNETLINK) -ldb -lpthread 23 24ssfilter.c: ssfilter.y 25 bison ssfilter.y -o ssfilter.c 26 27lnstat: $(LNSTATOBJ) 28 29install: all 30 install -m 0755 $(TARGETS) $(DESTDIR)$(SBINDIR) 31 ln -sf lnstat $(DESTDIR)$(SBINDIR)/rtstat 32 ln -sf lnstat $(DESTDIR)$(SBINDIR)/ctstat 33 34clean: 35 rm -f *.o $(TARGETS) ssfilter.c 36