mirror of https://github.com/ntop/n2n.git
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
47 lines
1.1 KiB
47 lines
1.1 KiB
3 years ago
|
#
|
||
|
# This is not a standalone makefile, it must be called from the toplevel
|
||
|
# makefile to inherit the correct environment
|
||
|
|
||
5 years ago
|
DEBUG?=-g3
|
||
5 years ago
|
|
||
4 years ago
|
HEADERS=$(wildcard include/*.h)
|
||
3 years ago
|
CFLAGS+=-I../include
|
||
|
ifeq ($(CONFIG_TARGET),mingw)
|
||
|
CFLAGS+=-I../win32
|
||
2 years ago
|
LDLIBS+=-lnetapi32
|
||
3 years ago
|
endif
|
||
|
CFLAGS+=$(DEBUG)
|
||
5 years ago
|
LDFLAGS+=-L..
|
||
|
|
||
|
N2N_LIB=../libn2n.a
|
||
|
|
||
2 years ago
|
TOOLS=n2n-benchmark n2n-keygen n2n-route n2n-portfwd
|
||
2 years ago
|
TOOLS+=$(TOOLS_ADDITIONAL)
|
||
5 years ago
|
|
||
3 years ago
|
TESTS=tests-compress tests-elliptic tests-hashing tests-transform
|
||
|
TESTS+=tests-wire
|
||
3 years ago
|
TESTS+=tests-auth
|
||
5 years ago
|
|
||
3 years ago
|
.PHONY: all clean install
|
||
|
all: $(TOOLS) $(TESTS)
|
||
5 years ago
|
|
||
3 years ago
|
n2n-benchmark.o: $(N2N_LIB) $(HEADERS) ../Makefile Makefile
|
||
|
n2n-keygen.o: $(N2N_LIB) $(HEADERS) ../Makefile Makefile
|
||
3 years ago
|
n2n-route.o: $(N2N_LIB) $(HEADERS) ../Makefile Makefile
|
||
2 years ago
|
n2n-portfwd.o: $(N2N_LIB) $(HEADERS) ../Makefile Makefile
|
||
3 years ago
|
|
||
3 years ago
|
n2n-decode: n2n-decode.c $(N2N_LIB) $(HEADERS) ../Makefile Makefile
|
||
|
$(CC) $(CFLAGS) $< $(LDFLAGS) $(LDLIBS) -lpcap -o $@
|
||
5 years ago
|
|
||
3 years ago
|
# See comments in the topdir Makefile about how to generate coverage
|
||
|
# data.
|
||
|
gcov:
|
||
|
gcov $(TOOLS) $(TESTS)
|
||
|
|
||
5 years ago
|
clean:
|
||
4 years ago
|
rm -rf $(TOOLS) *.o *.dSYM *~
|
||
3 years ago
|
rm -f $(TESTS) *.gcno *.gcda
|
||
5 years ago
|
|
||
|
install: $(TOOLS)
|
||
|
$(INSTALL_PROG) $(TOOLS) $(SBINDIR)/
|