selftests, bpftool: Skip the build test if not in tree
authorJakub Kicinski <jakub.kicinski@netronome.com>
Tue, 19 Nov 2019 10:50:10 +0000 (10:50 +0000)
committerAlexei Starovoitov <ast@kernel.org>
Mon, 25 Nov 2019 00:58:45 +0000 (16:58 -0800)
commit5940c5bf6504f66f57f03f1d0046abfaf2198b3a
treed1395935d61237275e7e98cf5b9aa1b55289d129
parent31f8b8295bb8997f139fe34b68654f8f1408f0da
selftests, bpftool: Skip the build test if not in tree

If selftests are copied over to another machine/location
for execution the build test of bpftool will obviously
not work, since the sources are not copied.
Skip it if we can't find bpftool's Makefile.

Reported-by: Naresh Kamboju <naresh.kamboju@linaro.org>
Signed-off-by: Jakub Kicinski <jakub.kicinski@netronome.com>
Signed-off-by: Quentin Monnet <quentin.monnet@netronome.com>
Signed-off-by: Daniel Borkmann <daniel@iogearbox.net>
Link: https://lore.kernel.org/bpf/20191119105010.19189-3-quentin.monnet@netronome.com
tools/testing/selftests/bpf/test_bpftool_build.sh