cmake: Rebasing #225 for ProcDump 3.4.0.#266
Open
jcfaracco wants to merge 6 commits intomicrosoft:masterfrom
Open
cmake: Rebasing #225 for ProcDump 3.4.0.#266jcfaracco wants to merge 6 commits intomicrosoft:masterfrom
jcfaracco wants to merge 6 commits intomicrosoft:masterfrom
Conversation
Signed-off-by: Julio Faracco <jfaracco@redhat.com>
- The local cmake/FindBpf.cmake module is used to discover an installed libbpf, unless the PROCDUMP_DISABLE_SYSTEM_LIBBPF option is enabled - If system libbpf is disabled or not found, ExternalProject_Add is used to retrieve libbpf sources, build, (NEW: and install into PROJECT_BUILD_DIR/libbpf) - `LANGUAGES C CXX` added to project() command (aids CMake discovery of parameters like correct library dir name) - `GNUInstallDirs` CMake module loaded, defines CMAKE_INCLUDE_DIR and CMAKE_LIBRARY_DIR correctly relative to install prefix Signed-off-by: Julio Faracco <jfaracco@redhat.com>
The repo's CMake Find module for Bpf includes the ability to discover the location of the `bpftool` executable and provide an executable target representing its location. Use that in commands to generate the various procdump_ebpf files. Also, split out the steps to generate files using bpftool into separate add_custom_command() invocations, so that dependencies between files are tracked and each output file will be automatically tagged as `GENERATED` by CMake (and deleted by the 'clean' target). Signed-off-by: Julio Faracco <jfaracco@redhat.com>
Contributor
Author
|
@kloczek do you have any suggestion about this PR? Feel free to do it. We can enhance the changes if necessary. |
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This Pull Request is just a rebase on top of release 3.4.0.
For further reference of what this PR does, see the original #225.
If the original owner of the patch set retake the ownership of the changes, anyone can close this PR.
I kept the original owner of the patches/commits that apply cleanly.