Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

libbpf: Compile libbpf under -O2 level by default and catch extra warnings

For some reason compiler doesn't complain about uninitialized variable, fixed
in previous patch, if libbpf is compiled without -O2 optimization level. So do
compile it with -O2 and never let similar issue slip by again. -Wall is added
unconditionally, so no need to specify it again.

Signed-off-by: Andrii Nakryiko <andriin@fb.com>
Signed-off-by: Alexei Starovoitov <ast@kernel.org>
Acked-by: Martin KaFai Lau <kafai@fb.com>
Link: https://lore.kernel.org/bpf/20200929220604.833631-2-andriin@fb.com

authored by

Andrii Nakryiko and committed by
Alexei Starovoitov
0a62291d 33433913

+1 -1
+1 -1
tools/lib/bpf/Makefile
··· 98 98 ifdef EXTRA_CFLAGS 99 99 CFLAGS := $(EXTRA_CFLAGS) 100 100 else 101 - CFLAGS := -g -Wall 101 + CFLAGS := -g -O2 102 102 endif 103 103 104 104 # Append required CFLAGS