diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-05-04 14:18:53 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-05-04 14:18:53 +0000 |
commit | a0e0018c9a7ef5ce7f6d2c3ae16aecbbd16a8f67 (patch) | |
tree | 8feaf1a1932871b139b3b30be4c09c66489918be /misc/Makefile | |
parent | Initial commit. (diff) | |
download | iproute2-a0e0018c9a7ef5ce7f6d2c3ae16aecbbd16a8f67.tar.xz iproute2-a0e0018c9a7ef5ce7f6d2c3ae16aecbbd16a8f67.zip |
Adding upstream version 6.1.0.upstream/6.1.0upstream
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to '')
-rw-r--r-- | misc/Makefile | 42 |
1 files changed, 42 insertions, 0 deletions
diff --git a/misc/Makefile b/misc/Makefile new file mode 100644 index 0000000..50dae79 --- /dev/null +++ b/misc/Makefile @@ -0,0 +1,42 @@ +# SPDX-License-Identifier: GPL-2.0 +SSOBJ=ss.o ssfilter_check.o ssfilter.tab.o +LNSTATOBJ=lnstat.o lnstat_util.o + +TARGETS=ss nstat ifstat rtacct lnstat + +include ../config.mk + +ifeq ($(HAVE_BERKELEY_DB),y) + TARGETS += arpd +endif + +all: $(TARGETS) + +ss: $(SSOBJ) + $(QUIET_LINK)$(CC) $^ $(LDFLAGS) $(LDLIBS) -o $@ + +nstat: nstat.c + $(QUIET_CC)$(CC) $(CFLAGS) $(CPPFLAGS) $(LDFLAGS) -o nstat nstat.c $(LDLIBS) -lm + +ifstat: ifstat.c + $(QUIET_CC)$(CC) $(CFLAGS) $(CPPFLAGS) $(LDFLAGS) -o ifstat ifstat.c $(LDLIBS) -lm + +rtacct: rtacct.c + $(QUIET_CC)$(CC) $(CFLAGS) $(CPPFLAGS) $(LDFLAGS) -o rtacct rtacct.c $(LDLIBS) -lm + +arpd: arpd.c + $(QUIET_CC)$(CC) $(CFLAGS) -I$(DBM_INCLUDE) $(CPPFLAGS) $(LDFLAGS) -o arpd arpd.c $(LDLIBS) -ldb + +ssfilter.tab.c: ssfilter.y + $(QUIET_YACC)$(YACC) -b ssfilter ssfilter.y + +lnstat: $(LNSTATOBJ) + $(QUIET_LINK)$(CC) $^ $(LDFLAGS) $(LDLIBS) -o $@ + +install: all + install -m 0755 $(TARGETS) $(DESTDIR)$(SBINDIR) + ln -sf lnstat $(DESTDIR)$(SBINDIR)/rtstat + ln -sf lnstat $(DESTDIR)$(SBINDIR)/ctstat + +clean: + rm -f *.o $(TARGETS) ssfilter.c |