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

Print all detected features when VF=1 #181

Open
qmonnet opened this issue Feb 10, 2025 · 6 comments · May be fixed by #186
Open

Print all detected features when VF=1 #181

qmonnet opened this issue Feb 10, 2025 · 6 comments · May be fixed by #186
Assignees

Comments

@qmonnet
Copy link
Member

qmonnet commented Feb 10, 2025

Kernel file tools/build/Makefile.feature has

ifeq ($(VF),1)
  feature_display := 1
  feature_verbose := 1
endif

causing all features to be displayed:

$ VF=1 make

Auto-detecting system features:
...                         clang-bpf-co-re: [ on  ]
...                                    llvm: [ on  ]
...                                  libcap: [ on  ]
...                                  libbfd: [ on  ]
...                          libbfd-liberty: [ on  ]
...                        libbfd-liberty-z: [ on  ]
...                  disassembler-four-args: [ on  ]
...                disassembler-init-styled: [ on  ]
...                             libelf-zstd: [ on  ]

It could be useful for debugging features detection to have the same in this repository. We already have V=1, which prints the details of the detection, but this list is more succinct. On the other hand, it's also used in the kernel repo to force displaying the values when they would otherwise be skipped:

# The $(feature_display) controls the default detection message
# output. It's set if:
# - detected features differes from stored features from
#   last build (in $(FEATURE_DUMP_FILENAME) file)
# - one of the $(FEATURE_DISPLAY) is not detected
# - VF is enabled

but we don't have this issue in the GitHub repo, given that we don't dump features to a file and always print those in FEATURE_DISPLAY. Still, supporting VF=1 could be nice.

@Shankari02
Copy link

Hello @qmonnet, I want to improve this process and resolve the issue. Should I generate the patch and send it to the mailing list before creating the PR?

@qmonnet
Copy link
Member Author

qmonnet commented Mar 24, 2025

Hi, thanks for looking into this!

Usually the patches should go to the mailing list (and then they're automatically sync-ed with this repo), but this Issue is a particular case: We're trying to make the version from the GitHub repo behave more like the one from the kernel repo. It means that there's no change to do on kernel side, only in this repository. So we just need a PR against this repo.

@Shankari02
Copy link

Hi, thanks for looking into this!

Usually the patches should go to the mailing list (and then they're automatically sync-ed with this repo), but this Issue is a particular case: We're trying to make the version from the GitHub repo behave more like the one from the kernel repo. It means that there's no change to do on kernel side, only in this repository. So we just need a PR against this repo.

Thanks for clarifying! I'll generate a PR for this. Please assign me this issue.

@Shankari02
Copy link

Hi @qmonnet, I have made the required changes in Makefile.feature to display the features as required.

shankari@shankari-IdeaPad:~/bpftool/src$ VF=1 make
...                        libbfd: [ on  ]
...                libbfd-liberty: [ OFF ]
...              libbfd-liberty-z: [ OFF ]
...               clang-bpf-co-re: [ on  ]
...                          llvm: [ on  ]
...                        libcap: [ on  ]
...        disassembler-four-args: [ on  ]
...      disassembler-init-styled: [ on  ]
...                   libelf-zstd: [ OFF ]
make: Nothing to be done for 'all'.

This is the output I have got. Please verify this and let me know if it seems fine, then, I'll generate a PR.

@qmonnet
Copy link
Member Author

qmonnet commented Mar 26, 2025

Yes, this looks OK to me 👍

@Shankari02
Copy link

I have generated the PR - #186.
Please let me know if there are any changes to be made. Thanks!

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 a pull request may close this issue.

2 participants