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

qt6: Fix linking when configured with -DENABLE_WALLET=OFF #837

Merged
merged 1 commit into from
Oct 4, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions src/qt/rpcconsole.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,9 @@
#include <qt/guiutil.h>
#include <qt/peertablesortproxy.h>
#include <qt/platformstyle.h>
#ifdef ENABLE_WALLET
#include <qt/walletmodel.h>
#endif // ENABLE_WALLET
Comment on lines +19 to +21
Copy link
Member

Choose a reason for hiding this comment

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

How the RPCExecutor::request method compiles when this line doesn't exist?

Copy link
Contributor

@pablomartin4btc pablomartin4btc Sep 19, 2024

Choose a reason for hiding this comment

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

I think because the compiler only needs to know WalletModel, it doesn't need the full definition unless you dereference the pointer (eg as in RPCConsole::RPCParseCommandLine -> wallet_model->getWalletName() - which is guarded).

Copy link
Member Author

@hebasto hebasto Oct 3, 2024

Choose a reason for hiding this comment

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

Reworked.

Copy link
Member Author

Choose a reason for hiding this comment

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

Reworked.

Reverted back.

How the RPCExecutor::request method compiles when this line doesn't exist?

Due to

class WalletModel;

#include <rpc/client.h>
#include <rpc/server.h>
#include <util/strencodings.h>
Expand Down
Loading