Skip to content
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

Use temporary files instead of piping in ebpf Makefile #985

Merged
merged 1 commit into from
Jul 7, 2023

Conversation

nnsee
Copy link
Contributor

@nnsee nnsee commented Jul 7, 2023

Currently, when compiling the eBPF module, in the Makefile, the output of clang is directly piped to llc. This is bad, because in this case, should clang fail, llc still runs, but produces faulty .o files. make never picks up on it and doesn't abort compilation - a success is reported across the board (apart from the clang log).

This patch removes the file and explicitly writes (and later deletes) clang's output to a .partial file. This is later used as the input of llc.

@gustavo-iniguez-goya gustavo-iniguez-goya merged commit 78d82ec into evilsocket:master Jul 7, 2023
@gustavo-iniguez-goya
Copy link
Collaborator

thank you @nnsee :) everyone seems to use pipes, but it's true that empty/invalid objects was a problem.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants