]> git.ipfire.org Git - thirdparty/systemd.git/commitdiff
bpf: set gcc std and compile flags
authorJames Hilliard <james.hilliard1@gmail.com>
Mon, 1 Aug 2022 01:34:11 +0000 (01:34 +0000)
committerYu Watanabe <watanabe.yu+github@gmail.com>
Mon, 1 Aug 2022 12:35:44 +0000 (21:35 +0900)
This should make gcc bpf compilation more reliable.

src/core/bpf/meson.build

index c2f9b5ac4286a8f79486e91b53e16f10354e62af..f65401617a93e0f9895f5d67580fe1d6004b3a7a 100644 (file)
@@ -5,6 +5,7 @@ if conf.get('BPF_FRAMEWORK') != 1
 endif
 
 bpf_clang_flags = [
+        '-std=gnu11',
         '-Wno-compare-distinct-pointer-types',
         '-O2',
         '-target',
@@ -14,11 +15,13 @@ bpf_clang_flags = [
 ]
 
 bpf_gcc_flags = [
+        '-std=gnu11',
         '-O2',
         '-mkernel=5.2',
         '-mcpu=v3',
         '-mco-re',
         '-gbtf',
+        '-c',
 ]
 
 # Generate defines that are appropriate to tell the compiler what architecture