Generating multiple types with bpf2go #627
-
Hi, I have multiple types in ebpf code and I couldn't use bpf2go to generate code for multiple types. If i use one type as specified in example, its working and if i define second type, go generate failing with second type not found,. is there any way to do it? working: Not Working:
|
Beta Was this translation helpful? Give feedback.
Replies: 3 comments 3 replies
-
Hi, can you provide the C source in question? |
Beta Was this translation helpful? Give feedback.
-
@lmb i figured it out. i didn't define the verdict event. i was missing this:
|
Beta Was this translation helpful? Give feedback.
-
@lmb not related to this question. Currently im compiling bpf2go code and using bpf2go cmd directly with go:generate. I couldn't compile with go:generate go run github.com/cilium/ebpf/cmd/bpf2go. it s failing with |
Beta Was this translation helpful? Give feedback.
@lmb i figured it out. i didn't define the verdict event. i was missing this:
const struct verdict *unusedverdict __attribute__((unused));