forked from iovisor/bcc
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
attempt to compile with system bpf.h if default compile failed
Currently, bcc uses its own version of bpf.h which tries to sync with upstream header regularly. If the host bpf.h version is lower, bcc can still compile as some bcc codes may requires a higher version of bpf.h. Such an approach does have a drawback. Suppose service A, statically linked with bcc, runs on kernel version X. Now, the kernel upgrades to version Y. After kernel upgrade/reboot, service A may not be able to compile since old bcc bpf.h may not align with the new kernel headers. For such cases, new version of service A needs rollout. This patch addresses this issue by attempting a second compilation using system bpf.h instead. The feature is not on by default. To enable it, pass -DBCC_BACKUP_COMPILE=1 in cmake setup stage. Signed-off-by: Yonghong Song <[email protected]>
- Loading branch information
1 parent
7bb5233
commit c53d8ae
Showing
3 changed files
with
59 additions
and
10 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters