Skip to content

Commit

Permalink
libbpf: Compile using -std=gnu89
Browse files Browse the repository at this point in the history
The minimum supported C standard version is C89, with use of GNU
extensions, hence make sure to catch any instances that would break
the build for this mode by passing -std=gnu89.

Signed-off-by: Kumar Kartikeya Dwivedi <memxor@gmail.com>
Signed-off-by: Alexei Starovoitov <ast@kernel.org>
Link: https://lore.kernel.org/bpf/20211105234243.390179-4-memxor@gmail.com
  • Loading branch information
kkdwivedi authored and Alexei Starovoitov committed Nov 9, 2021
1 parent c23551c commit 3a74ac2
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions tools/lib/bpf/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,7 @@ else
endif

# Append required CFLAGS
override CFLAGS += -std=gnu89
override CFLAGS += $(EXTRA_WARNINGS) -Wno-switch-enum
override CFLAGS += -Werror -Wall
override CFLAGS += $(INCLUDES)
Expand Down

0 comments on commit 3a74ac2

Please sign in to comment.