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

Add missed config/bitcoin-config.h header #29333

Closed
wants to merge 1 commit into from

Conversation

hebasto
Copy link
Member

@hebasto hebasto commented Jan 27, 2024

The config/bitcoin-config.h header is required to provide definitions for the USE_BDB and USE_SQLITE macros.

While this header might be included indirectly elsewhere, including it explicitly makes the build process more robust.

@DrahtBot
Copy link
Contributor

DrahtBot commented Jan 27, 2024

The following sections might be updated with supplementary metadata relevant to reviewers and maintainers.

Code Coverage

For detailed information about the code coverage, see the test coverage report.

Reviews

See the guideline for information on the review process.
A summary of reviews will appear here.

The `config/bitcoin-config.h` header is required to provide definitions
for the `USE_BDB` and `USE_SQLITE` macros.
Comment on lines +8 to 12
#if defined(HAVE_CONFIG_H)
#include <config/bitcoin-config.h>
#endif

#include <common/system.h>
Copy link
Member

@furszy furszy Jan 27, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Isn't bitcoin-config.h indirectly included by this system.h include? (which btw, doesn't seems to be needed).

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Isn't bitcoin-config.h indirectly included by this system.h include?

It is.

While this header might be included indirectly elsewhere, including it explicitly makes the build process more robust.

Copy link
Member

@furszy furszy Jan 27, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

then it would be good to remove the unused include within this change. walletdb.cpp does not call to any system.h` function.

@TheCharlatan
Copy link
Contributor

What motivates changing only this single file and not the various other modules that iwyu reports to have unused or missing bitcoin-config.h includes?

@hebasto
Copy link
Member Author

hebasto commented Jan 27, 2024

What motivates changing only this single file and not the various other modules that iwyu reports to have unused or missing bitcoin-config.h includes?

It was spotted during debugging another issue. Agree that it looks like a random diff.

@hebasto hebasto closed this Jan 27, 2024
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.

None yet

4 participants