]> git.baikalelectronics.ru Git - kernel.git/commit
samples/bpf: Enable cross compiler support
authorJoel Fernandes <joelaf@google.com>
Wed, 20 Sep 2017 16:11:57 +0000 (09:11 -0700)
committerDavid S. Miller <davem@davemloft.net>
Thu, 21 Sep 2017 18:59:16 +0000 (11:59 -0700)
commita7b0aba26a6fff33d2cc1d98424e3baa4d43258a
tree8872934ddc072a92c589cdbe1199bd0b1c7d944d
parentd1f576b609cb14d013f0acdb3a4eea732b28366a
samples/bpf: Enable cross compiler support

When cross compiling, bpf samples use HOSTCC for compiling the non-BPF part of
the sample, however what we really want is to use the cross compiler to build
for the cross target since that is what will load and run the BPF sample.
Detect this and compile samples correctly.

Acked-by: Alexei Starovoitov <ast@kernel.org>
Signed-off-by: Joel Fernandes <joelaf@google.com>
Acked-by: Daniel Borkmann <daniel@iogearbox.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
samples/bpf/Makefile