testsuite: let make compile build the netlink helper

The generate_nlmsg binary is required but make -C testsuite compile
does not build it. Add the necessary includes and C*FLAGS to the tools
Makefile and have the compile target build it.

Signed-off-by: Luca Boccassi <bluca@debian.org>
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
This commit is contained in:
Luca Boccassi 2018-08-22 19:09:02 +01:00 committed by Stephen Hemminger
parent ad23e152b8
commit 012895ce4e
2 changed files with 4 additions and 1 deletions

View File

@ -30,6 +30,7 @@ configure:
compile: configure
echo "Entering iproute2" && cd iproute2 && $(MAKE) && cd ..;
$(MAKE) -C tools
listtests:
@for t in $(TESTS); do \

View File

@ -1,6 +1,8 @@
# SPDX-License-Identifier: GPL-2.0
include ../../config.mk
generate_nlmsg: generate_nlmsg.c ../../lib/libnetlink.c
$(CC) -o $@ $^
$(CC) $(CPPFLAGS) $(CFLAGS) $(LDLIBS) $(EXTRA_CFLAGS) -I../../include -include../../include/uapi/linux/netlink.h -o $@ $^
clean:
rm -f generate_nlmsg