Refactor CMake to create GUI free library - #1437
Conversation
|
Why is this touching so much? It's rather invasive too. If you're trying to make the minimal Qt-less library for Python integration, why is the entire media stack being pulled in? Same with the Discord integration? |
|
It's mostly because of GlobalSettingsPanel.cpp. It includes Discord stuff, ErrorReports, which in turn pull in media stuff. Would you prefer if we just ifdef the stuff higher up in the chain? NintendoSwitch_ProController, NintendoSwitch_Joycon, NintendoSwitch_PABotBase2_OemController, NintendoSwitch_PABotBase2_Controller all require "NintendoSwitch/NintendoSwitch_Settings.h", which eventually includes GlobalSettingsPanel. If we ifdef NintendoSwitch_Settings, that would solve a lot of the problems. The other problem is that ControllerState includes OperationFailedException, which includes ProgramNotifications, and all the Discord stuff. So OperationFailedException would need to be ifdef as well. |
|
Yeah, ideally we break the dependencies much higher up.
|
|
Could ControllerState just throw a regular Exception (the base class for OperationFailed)? EDIT: I decided to go with InternalProgramError, since I'm not sure that it should ever happen. Alternatively, maybe we could do UserSetupError? |
I also applied ifdef to all usages of Qt (in the files included in the Core library).