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

CMake warning: Could NOT find LibBfd #298

Closed
KivApple opened this issue May 25, 2022 · 4 comments
Closed

CMake warning: Could NOT find LibBfd #298

KivApple opened this issue May 25, 2022 · 4 comments

Comments

@KivApple
Copy link

KivApple commented May 25, 2022

I use Cgreen inside my project using add_subdirectory to avoid necessity for user to install anything except CMake and C/C++ compiler to build my project. I get annoying warnings like

-- Could NOT find LibBfd (missing: LIBBFD_LIBRARY LIBIBERTY_LIBRARY LIBBFD_INCLUDE_DIRS) 
CMake Warning at lib/cgreen/tools/CMakeLists.txt:45 (message):
  libbfd not found, cgreen-runner will not be built

But missing of cgreen-runner is fine for me and expected behavior. Is it possible to add some option to explicitly disable building of cgreen-runner and get rid of this warning?

@thoni56
Copy link
Contributor

thoni56 commented Jun 4, 2022

In 9cbc397ed62024f630b8bc2c338b03f7726aa8e4 I've added a CMake variable, CGREEN_BUILD_RUNNER, that actively selects/deselects building the auto-discovering runner.

I'm no CMake expert so I don't know if this will prevent trying to find libbfd, but it's a start.

Could you please try it?

@KivApple
Copy link
Author

KivApple commented Jun 5, 2022

Yes, the warning has gone. Thank you!

@thoni56
Copy link
Contributor

thoni56 commented Jun 5, 2022

Now I only have to make that official by documenting it.

@thoni56
Copy link
Contributor

thoni56 commented Jun 28, 2022

Closing this as we will be reverting the use of libbfd as outlined in #302

@thoni56 thoni56 closed this as completed Jun 28, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants