From 75be9ce40de47417b9af6fb6a7cbf1b428dc902d Mon Sep 17 00:00:00 2001 From: Glenn Rice Date: Thu, 8 Jul 2010 00:52:46 +0000 Subject: [PATCH] Fix the nowx build. Do we still want to keep the nowx build? If you do speak up now because soren wants to remove it. git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@5851 8ced0084-cf51-0410-be5f-012b33b47a6e --- Source/Core/DolphinWX/Src/MainNoGUI.cpp | 2 - Source/Core/DolphinWX/Src/SConscript | 4 +- Source/Core/InputCommon/Src/UDPWrapper.cpp | 3 ++ Source/Core/InputCommon/Src/UDPWrapper.h | 4 ++ Source/Plugins/Plugin_Wiimote/Src/SConscript | 37 ++++++++++--------- .../Plugins/Plugin_WiimoteNew/Src/SConscript | 31 +++++++++------- .../Plugin_WiimoteNew/Src/WiimoteNew.cpp | 2 +- 7 files changed, 46 insertions(+), 37 deletions(-) diff --git a/Source/Core/DolphinWX/Src/MainNoGUI.cpp b/Source/Core/DolphinWX/Src/MainNoGUI.cpp index 66e976310f..84933a5db7 100644 --- a/Source/Core/DolphinWX/Src/MainNoGUI.cpp +++ b/Source/Core/DolphinWX/Src/MainNoGUI.cpp @@ -379,7 +379,6 @@ int main(int argc, char* argv[]) updateMainFrameEvent.Init(); LogManager::Init(); - EventHandler::Init(); SConfig::Init(); CPluginManager::Init(); @@ -402,7 +401,6 @@ int main(int argc, char* argv[]) CPluginManager::Shutdown(); SConfig::Shutdown(); - EventHandler::Shutdown(); LogManager::Shutdown(); cmdline_parser_free (&args_info); diff --git a/Source/Core/DolphinWX/Src/SConscript b/Source/Core/DolphinWX/Src/SConscript index c34feaf2a1..c047775e26 100644 --- a/Source/Core/DolphinWX/Src/SConscript +++ b/Source/Core/DolphinWX/Src/SConscript @@ -12,7 +12,7 @@ files = [ libs = [ 'core', 'lzo2', 'discio', 'bdisasm', 'videocommon', - 'inputuicommon', 'inputcommon', 'common', 'lua', 'z', 'sfml-network', + 'inputcommon', 'common', 'lua', 'z', 'sfml-network', 'SDL' ] @@ -51,7 +51,7 @@ if wxenv['HAVE_WX']: 'wxNEEDS_CHARPP', ], - libs = [ 'debwx', 'debugger_ui_util'] + libs + libs = [ 'debwx', 'debugger_ui_util', 'inputuicommon'] + libs else: files+= [ 'cmdline.c', diff --git a/Source/Core/InputCommon/Src/UDPWrapper.cpp b/Source/Core/InputCommon/Src/UDPWrapper.cpp index 70a3d9ddf8..1442c2353e 100644 --- a/Source/Core/InputCommon/Src/UDPWrapper.cpp +++ b/Source/Core/InputCommon/Src/UDPWrapper.cpp @@ -84,6 +84,8 @@ UDPWrapper::~UDPWrapper() } +#if defined(HAVE_WX) && HAVE_WX + #define _connect_macro_(b, f, c, s) (b)->Connect(wxID_ANY, (c), wxCommandEventHandler( f ), (wxObject*)0, (wxEvtHandler*)s) class UDPConfigDiag : public wxDialog @@ -173,3 +175,4 @@ void UDPWrapper::Configure(wxWindow * parent) diag->ShowModal(); diag->Destroy(); } +#endif diff --git a/Source/Core/InputCommon/Src/UDPWrapper.h b/Source/Core/InputCommon/Src/UDPWrapper.h index 43432688d9..12e7abb99a 100644 --- a/Source/Core/InputCommon/Src/UDPWrapper.h +++ b/Source/Core/InputCommon/Src/UDPWrapper.h @@ -6,6 +6,7 @@ #include "IniFile.h" #include +#if defined(HAVE_WX) && HAVE_WX #include #include #include @@ -16,6 +17,7 @@ #include #include #include +#endif #include "UDPWiimote.h" @@ -31,7 +33,9 @@ public: virtual void LoadConfig(IniFile::Section *sec, const std::string& defdev = "", const std::string& base = "" ); virtual void SaveConfig(IniFile::Section *sec, const std::string& defdev = "", const std::string& base = "" ); void Refresh(); +#if defined(HAVE_WX) && HAVE_WX void Configure(wxWindow * parent); +#endif virtual ~UDPWrapper(); }; diff --git a/Source/Plugins/Plugin_Wiimote/Src/SConscript b/Source/Plugins/Plugin_Wiimote/Src/SConscript index d7c3c4e20d..6a7bf23f1a 100644 --- a/Source/Plugins/Plugin_Wiimote/Src/SConscript +++ b/Source/Plugins/Plugin_Wiimote/Src/SConscript @@ -7,28 +7,29 @@ wmenv = env.Clone() name = "Plugin_Wiimote" files = [ - "Config.cpp", - "DataReports.cpp", - "EmuDefinitions.cpp", - "EmuDynamics.cpp", - "EmuMain.cpp", - "EmuPad.cpp", - "EmuSubroutines.cpp", - "Encryption.cpp", - "main.cpp", - "Rumble.cpp", + "Config.cpp", + "DataReports.cpp", + "EmuDefinitions.cpp", + "EmuDynamics.cpp", + "EmuMain.cpp", + "EmuPad.cpp", + "EmuSubroutines.cpp", + "Encryption.cpp", + "main.cpp", + "Rumble.cpp", "UDPWiimote.cpp" ] -if wmenv['HAVE_WX']: - files += [ - "ConfigBasicDlg.cpp", - "ConfigPadDlg.cpp", - "ConfigGamepad.cpp", - "FillReport.cpp", - ] +libs = [ 'inputcommon', 'common', 'SDL' ] -libs = [ 'inputuicommon', 'inputcommon', 'common', 'SDL' ] +if wmenv['HAVE_WX']: + libs = [ 'inputuicommon' ] + libs + files += [ + "ConfigBasicDlg.cpp", + "ConfigPadDlg.cpp", + "ConfigGamepad.cpp", + "FillReport.cpp", + ] cxxflags = [ ] diff --git a/Source/Plugins/Plugin_WiimoteNew/Src/SConscript b/Source/Plugins/Plugin_WiimoteNew/Src/SConscript index 633e9f0e56..ce717b340f 100644 --- a/Source/Plugins/Plugin_WiimoteNew/Src/SConscript +++ b/Source/Plugins/Plugin_WiimoteNew/Src/SConscript @@ -7,27 +7,30 @@ name = "Plugin_WiimoteNew" wiinewenv = env.Clone() files = [ - 'WiimoteEmu/WiimoteEmu.cpp', - 'WiimoteEmu/Attachment/Classic.cpp', - 'WiimoteEmu/Attachment/Attachment.cpp', - 'WiimoteEmu/Attachment/Nunchuk.cpp', - 'WiimoteEmu/Attachment/UDPNunchuk.cpp', - 'WiimoteEmu/Attachment/Drums.cpp', - 'WiimoteEmu/Attachment/Guitar.cpp', - 'WiimoteEmu/EmuSubroutines.cpp', - 'WiimoteEmu/Encryption.cpp', - 'WiimoteEmu/Speaker.cpp', - 'WiimoteNew.cpp', - 'WiimoteConfigDiag.cpp', + 'WiimoteEmu/WiimoteEmu.cpp', + 'WiimoteEmu/Attachment/Classic.cpp', + 'WiimoteEmu/Attachment/Attachment.cpp', + 'WiimoteEmu/Attachment/Nunchuk.cpp', + 'WiimoteEmu/Attachment/UDPNunchuk.cpp', + 'WiimoteEmu/Attachment/Drums.cpp', + 'WiimoteEmu/Attachment/Guitar.cpp', + 'WiimoteEmu/EmuSubroutines.cpp', + 'WiimoteEmu/Encryption.cpp', + 'WiimoteEmu/Speaker.cpp', + 'WiimoteNew.cpp' ] -libs = [ 'inputuicommon', 'inputcommon', 'common', 'SDL' ] +libs = [ 'inputcommon', 'common', 'SDL' ] cxxflags = [ ] +if wiinewenv['HAVE_WX']: + libs = [ 'inputuicommon' ] + libs + files += [ 'WiimoteConfigDiag.cpp' ] + if wiinewenv['HAVE_WIIUSE']: cxxflags += [ '-DHAVE_WIIUSE' ] - files += [ "WiimoteReal/WiimoteReal.cpp" ] + files += [ 'WiimoteReal/WiimoteReal.cpp' ] libs += [ 'wiiuse' ] wiinewenv.Append( diff --git a/Source/Plugins/Plugin_WiimoteNew/Src/WiimoteNew.cpp b/Source/Plugins/Plugin_WiimoteNew/Src/WiimoteNew.cpp index 73eff317f3..c137147017 100644 --- a/Source/Plugins/Plugin_WiimoteNew/Src/WiimoteNew.cpp +++ b/Source/Plugins/Plugin_WiimoteNew/Src/WiimoteNew.cpp @@ -2,13 +2,13 @@ #include "Common.h" #include "pluginspecs_wiimote.h" -#include "WiimoteConfigDiag.h" #include "WiimoteReal/WiimoteReal.h" #include "ControllerInterface/ControllerInterface.h" #include "WiimoteEmu/WiimoteEmu.h" #if defined(HAVE_WX) && HAVE_WX +#include "WiimoteConfigDiag.h" #include "../../InputUICommon/Src/ConfigDiag.h" #endif #include "../../InputCommon/Src/InputConfig.h"