diff options
author | Felix Fietkau <nbd@nbd.name> | 2021-11-18 16:47:51 +0100 |
---|---|---|
committer | Felix Fietkau <nbd@nbd.name> | 2021-11-19 23:51:20 +0100 |
commit | 98ef23dda84924e01348f2354161459a06e79e58 (patch) | |
tree | 05b803c568a855c34bacd859028b520764ad4162 | |
parent | 7ae04d3799d44b4a9fd3a2c82763d202be97fb77 (diff) | |
download | upstream-98ef23dda84924e01348f2354161459a06e79e58.tar.gz upstream-98ef23dda84924e01348f2354161459a06e79e58.tar.bz2 upstream-98ef23dda84924e01348f2354161459a06e79e58.zip |
include/bpf.mk: preserve the bpf .o file with debug symbols
Makes it easier to analyze verifier complaints
Signed-off-by: Felix Fietkau <nbd@nbd.name>
-rw-r--r-- | include/bpf.mk | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/include/bpf.mk b/include/bpf.mk index d9f1153cba..61e5b534ab 100644 --- a/include/bpf.mk +++ b/include/bpf.mk @@ -77,6 +77,7 @@ define CompileBPF $(LLVM_OPT) -O2 -mtriple=$(BPF_TARGET) < $(patsubst %.c,%.bc,$(1)) > $(patsubst %.c,%.opt,$(1)) $(LLVM_DIS) < $(patsubst %.c,%.opt,$(1)) > $(patsubst %.c,%.S,$(1)) $(LLVM_LLC) -march=$(BPF_TARGET) -filetype=obj -o $(patsubst %.c,%.o,$(1)) < $(patsubst %.c,%.S,$(1)) + $(CP) $(patsubst %.c,%.o,$(1)) $(patsubst %.c,%.debug.o,$(1)) $(LLVM_STRIP) --strip-debug $(patsubst %.c,%.o,$(1)) endef |