From d93cebf84b4d417930b8b50278faafe1318e7fd3 Mon Sep 17 00:00:00 2001 From: Glenn Rice Date: Mon, 19 Apr 2010 03:06:18 +0000 Subject: [PATCH] Build fix for the NoGUI build. Also removed a few compiler warning while I was at it. git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@5387 8ced0084-cf51-0410-be5f-012b33b47a6e --- Source/Core/DolphinWX/Src/MainNoGUI.cpp | 2 ++ Source/Plugins/InputPluginCommon/Src/SConscript | 12 +++++++++--- Source/Plugins/Plugin_GCPadNew/Src/GCPadNew.cpp | 2 +- .../Plugins/Plugin_VideoOGL/Src/TextureMngr.cpp | 15 ++++++++------- .../Plugins/Plugin_WiimoteNew/Src/WiimoteNew.cpp | 2 +- 5 files changed, 21 insertions(+), 12 deletions(-) diff --git a/Source/Core/DolphinWX/Src/MainNoGUI.cpp b/Source/Core/DolphinWX/Src/MainNoGUI.cpp index ee0f03d248..3a3b7a4f51 100644 --- a/Source/Core/DolphinWX/Src/MainNoGUI.cpp +++ b/Source/Core/DolphinWX/Src/MainNoGUI.cpp @@ -130,6 +130,8 @@ void Host_Message(int Id) #endif } +void Host_UpdateTitle(const char* title){}; + void Host_UpdateLogDisplay(){} diff --git a/Source/Plugins/InputPluginCommon/Src/SConscript b/Source/Plugins/InputPluginCommon/Src/SConscript index 0aff7caf13..1bdf26a744 100644 --- a/Source/Plugins/InputPluginCommon/Src/SConscript +++ b/Source/Plugins/InputPluginCommon/Src/SConscript @@ -3,13 +3,19 @@ Import('env') files = [ - 'Config.cpp', - 'ConfigDiagBitmaps.cpp', - 'ConfigDiag.cpp', + 'Config.cpp', 'ControllerEmu.cpp', 'IniFile.cpp', ] +if env['HAVE_WX']: + files += [ + 'ConfigDiagBitmaps.cpp', + 'ConfigDiag.cpp', + ] + + + env_inputpc = env.Clone() env_inputpc.Append(CXXFLAGS = [ '-fPIC' ]) env_inputpc.StaticLibrary(env['local_libs'] + "inputplugincommon", files) diff --git a/Source/Plugins/Plugin_GCPadNew/Src/GCPadNew.cpp b/Source/Plugins/Plugin_GCPadNew/Src/GCPadNew.cpp index 7251ac2ed6..6cbb374a0d 100644 --- a/Source/Plugins/Plugin_GCPadNew/Src/GCPadNew.cpp +++ b/Source/Plugins/Plugin_GCPadNew/Src/GCPadNew.cpp @@ -8,7 +8,7 @@ #if defined(HAVE_WX) && HAVE_WX #include "ConfigDiag.h" #endif -#include "Config.h" +#include "../../InputPluginCommon/Src/Config.h" #if defined(HAVE_X11) && HAVE_X11 #include diff --git a/Source/Plugins/Plugin_VideoOGL/Src/TextureMngr.cpp b/Source/Plugins/Plugin_VideoOGL/Src/TextureMngr.cpp index 55fd0712ce..075b3c48b3 100644 --- a/Source/Plugins/Plugin_VideoOGL/Src/TextureMngr.cpp +++ b/Source/Plugins/Plugin_VideoOGL/Src/TextureMngr.cpp @@ -16,6 +16,7 @@ // http://code.google.com/p/dolphin-emu/ #include +#include #include "Globals.h" #include "CommonPaths.h" @@ -268,9 +269,9 @@ TextureMngr::TCacheEntry* TextureMngr::Load(int texstage, u32 address, int width int expandedWidth = (width + bsw) & (~bsw); int expandedHeight = (height + bsh) & (~bsh); - u64 hash_value; + u64 hash_value = 0; u32 texID = address; - u64 texHash; + u64 texHash = 0; u32 FullFormat = tex_format; if ((tex_format == GX_TF_C4) || (tex_format == GX_TF_C8) || (tex_format == GX_TF_C14X2)) FullFormat = (tex_format | (tlutfmt << 16)); @@ -396,9 +397,9 @@ TextureMngr::TCacheEntry* TextureMngr::Load(int texstage, u32 address, int width TexLevels = (isPow2 && UseNativeMips && tex_format != GX_TF_CMPR) ? (int)(log((double)TexLevels)/log((double)2)) + 1 : (isPow2?0:1); if(TexLevels > maxlevel && maxlevel > 0) TexLevels = maxlevel; - int gl_format; - int gl_iformat; - int gl_type; + int gl_format = 0; + int gl_iformat = 0; + int gl_type = 0; entry.bHaveMipMaps = UseNativeMips; if (dfmt != PC_TEX_FMT_DXT1) { @@ -503,10 +504,10 @@ TextureMngr::TCacheEntry* TextureMngr::Load(int texstage, u32 address, int width //this is not a problem as the level are filtered by lod min and max value if (dfmt != PC_TEX_FMT_DXT1) { - if (expandedWidth != currentWidth) + if (expandedWidth != (int)currentWidth) glPixelStorei(GL_UNPACK_ROW_LENGTH, expandedWidth); glTexImage2D(target, level, gl_iformat, currentWidth, currentHeight, 0, gl_format, gl_type, temp); - if (expandedWidth != currentWidth) // reset + if (expandedWidth != (int)currentWidth) // reset glPixelStorei(GL_UNPACK_ROW_LENGTH, 0); } else diff --git a/Source/Plugins/Plugin_WiimoteNew/Src/WiimoteNew.cpp b/Source/Plugins/Plugin_WiimoteNew/Src/WiimoteNew.cpp index a1e0e0a936..0d241551ea 100644 --- a/Source/Plugins/Plugin_WiimoteNew/Src/WiimoteNew.cpp +++ b/Source/Plugins/Plugin_WiimoteNew/Src/WiimoteNew.cpp @@ -8,7 +8,7 @@ #if defined(HAVE_WX) && HAVE_WX #include "ConfigDiag.h" #endif -#include "Config.h" +#include "../../InputPluginCommon/Src/Config.h" #if defined(HAVE_X11) && HAVE_X11 #include