selftests/bpf: Enable cross-building
mainline inclusion from mainline-5.12-rc1 commit de11ae4f category: feature bugzilla: https://gitee.com/openeuler/kernel/issues/I5EUVD CVE: NA Reference: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=de11ae4f56fdc53474c08b03142860428e6c5655 ------------------------------------------------- Build bpftool and resolve_btfids using the host toolchain when cross-compiling, since they are executed during build to generate the selftests. Add a host build directory in order to build both host and target version of libbpf. Build host tools using $(HOSTCC) defined in Makefile.include. Signed-off-by: NJean-Philippe Brucker <jean-philippe@linaro.org> Signed-off-by: NAndrii Nakryiko <andrii@kernel.org> Acked-by: NAndrii Nakryiko <andrii@kernel.org> Link: https://lore.kernel.org/bpf/20210113163319.1516382-2-jean-philippe@linaro.org (cherry picked from commit de11ae4f) Signed-off-by: NWang Yufen <wangyufen@huawei.com>
Showing
想要评论请 注册 或 登录