-
Notifications
You must be signed in to change notification settings - Fork 302
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
aya-gen: rework command line #95
Comments
I can pick this up @alessandrod |
awesome thank you! 😊 |
@nitishm ping? are you still interested in working on this? |
Really sorry @alessandrod but I have been really occupied with work lately. I should've updated earlier and that's my mistake. It would be best that I give this up and let someone else take this up. I hope to get back to the project in 2022 when things settle down. |
All good no need to apologize at all - we all get busy! 😊 |
@alessandrod I'm going to try and take on the more general refactor of aya-gen to aya-tool this week (#87), which will include this change. |
@alessandrod Slight problem -- In order for this to work as you described, allowing you to pass flags directly to bindgen, we would need to invoke bindgen as a command rather than using the builder API. One potential workaround is to use the builder's |
Yep I've ran into this before. Using the builder, then calling |
Alright.
Currently we are just calling the builder's |
consider using BTFGen way for aya-gen: |
aya already supports all the bits to implement it. You only have to point aya-gen to the vmlinux you want to target. It needs to be checked if vmlinux can be passed to bpfloader at runtime. Btfgen generates a stripped down version of BTF input, you can ship this reduced btf along the way to your app in user space.
|
@vadorovsky could this be a solution for aya-gen regarding btftool version issue? BTFGen way for aya-gen or do you think a container workaround is enough? |
@albertxos I think that could be a solution, yes. Let me have a deeper look on BTFGen (I didn't use it yet) and I will try to find some time to figure out how to integrate it with aya-gen. |
Is there anything left to do here? |
Looks like #297 finished this. |
The aya-gen command allows generating bindings from BTF info. We should add support for generating bindings from C header files too. Related to #87 but can be done before.
The command today looks like:
I'm proposing we change it to look like:
So it would still default to BTF, it would optionally allow passing a custom BTF info path, and it would add the possibility to generate bindings from a C header file using
--header
.All variations should additionally allow passing arguments to bindgen directly, eg:
The text was updated successfully, but these errors were encountered: