提交 a36cd459 编写于 作者: I Ian Rogers 提交者: Zheng Zengkai

tools/bpftool: Add -Wall when building BPF programs

mainline inclusion
from mainline-5.12-rc1
commit bade5c55
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=bade5c554f1ac70a50cefe96517957629dbc0d8f

-------------------------------------------------

No additional warnings are generated by enabling this, but having it
enabled will help avoid regressions.
Signed-off-by: NIan Rogers <irogers@google.com>
Signed-off-by: NAndrii Nakryiko <andrii@kernel.org>
Acked-by: NYonghong Song <yhs@fb.com>
Link: https://lore.kernel.org/bpf/20210113223609.3358812-2-irogers@google.com
(cherry picked from commit bade5c55)
Signed-off-by: NWang Yufen <wangyufen@huawei.com>
上级 527d0e40
...@@ -165,7 +165,7 @@ $(OUTPUT)%.bpf.o: skeleton/%.bpf.c $(OUTPUT)vmlinux.h $(LIBBPF) ...@@ -165,7 +165,7 @@ $(OUTPUT)%.bpf.o: skeleton/%.bpf.c $(OUTPUT)vmlinux.h $(LIBBPF)
-I$(srctree)/tools/include/uapi/ \ -I$(srctree)/tools/include/uapi/ \
-I$(LIBBPF_PATH) \ -I$(LIBBPF_PATH) \
-I$(srctree)/tools/lib \ -I$(srctree)/tools/lib \
-g -O2 -target bpf -c $< -o $@ && $(LLVM_STRIP) -g $@ -g -O2 -Wall -target bpf -c $< -o $@ && $(LLVM_STRIP) -g $@
$(OUTPUT)%.skel.h: $(OUTPUT)%.bpf.o $(BPFTOOL_BOOTSTRAP) $(OUTPUT)%.skel.h: $(OUTPUT)%.bpf.o $(BPFTOOL_BOOTSTRAP)
$(QUIET_GEN)$(BPFTOOL_BOOTSTRAP) gen skeleton $< > $@ $(QUIET_GEN)$(BPFTOOL_BOOTSTRAP) gen skeleton $< > $@
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册