diff --git a/Binary/mac/Dolphin.ini b/Binary/mac/Dolphin.ini index 530b6894f7..4b60bacb0b 100644 --- a/Binary/mac/Dolphin.ini +++ b/Binary/mac/Dolphin.ini @@ -3,3 +3,22 @@ GFXPlugin = Plugins/libzeroogl.so DSPPlugin = Plugins/libdsphle.so PadPlugin = Plugins/libPlugin_nJoy_SDL.so WiiMotePlugin = Plugins/libPlugin_Wiimote.so +[General] +LastFilename = +GCMPathes = 0 +[Core] +GFXPlugin = Plugins/libzeroogl.so +DSPPlugin = Plugins/libdsphle.so +PadPlugin = Plugins/libPlugin_nJoy_SDL.so +WiiMotePlugin = Plugins/libPlugin_Wiimote.so +HLEBios = True +UseDynarec = True +UseDualCore = False +SkipIdle = True +LockThreads = True +DefaultGCM = +DVDRoot = +OptimizeQuantizers = True +SelectedLanguage = 0 +RunCompareServer = False +RunCompareClient = False diff --git a/SConstruct b/SConstruct index 316a374ec9..fe5e40366a 100644 --- a/SConstruct +++ b/SConstruct @@ -173,8 +173,9 @@ if not env['osx64']: if not conf.CheckSDL('1.0.0'): Exit(1) -if not conf.CheckPKG('ao'): - Exit(1) +if not env['osx64']: + if not conf.CheckPKG('ao'): + Exit(1) # handling wx flags CCFLAGS should be created before if not env['nowx']: @@ -198,15 +199,16 @@ if not env['nowx']: compileFlags += ['-DUSE_WX',] #osx 64bit need this -#if env['osx64']: -# compileFlags += ['\-arch x86_64',] +if env['osx64']: + compileFlags += ['-arch' , 'x86_64', '-DOSX64'] #get sdl stuff if not env['osx64']: env.ParseConfig('sdl-config --cflags --libs') # lib ao (needed for sound plugins) -env.ParseConfig('pkg-config --cflags --libs ao') +if not env['osx64']: + env.ParseConfig('pkg-config --cflags --libs ao') # add methods from utils to env env.AddMethod(utils.filterWarnings) diff --git a/Source/Core/Common/Src/Common.h b/Source/Core/Common/Src/Common.h index 1d38fcccaa..d30141d94b 100644 --- a/Source/Core/Common/Src/Common.h +++ b/Source/Core/Common/Src/Common.h @@ -21,6 +21,10 @@ #define _CRTDBG_MAP_ALLOC #define _CRTDBG_MAP_ALLOC_NEW +#ifdef OSX64 +#define MAP_32BIT 0 +#endif + #define CHECK_HEAP_INTEGRITY() #ifdef _WIN32 diff --git a/Source/Core/DolphinWX/Src/BootManager.cpp b/Source/Core/DolphinWX/Src/BootManager.cpp index cfee19905f..ffb4edfab7 100644 --- a/Source/Core/DolphinWX/Src/BootManager.cpp +++ b/Source/Core/DolphinWX/Src/BootManager.cpp @@ -27,7 +27,7 @@ #include "VolumeCreator.h" #include "Config.h" #include "Core.h" -#if !defined(_LP64) && !defined(__APPLE__) +#if !defined(OSX64) #include "Frame.h" #include "CodeWindow.h" #endif @@ -36,7 +36,7 @@ static std::string s_DataBasePath_EUR = "Data_EUR"; static std::string s_DataBasePath_USA = "Data_USA"; static std::string s_DataBasePath_JAP = "Data_JAP"; -#if !defined(_LP64) && !defined(__APPLE__) +#if !defined(OSX64) extern CFrame* main_frame; extern CCodeWindow* g_pCodeWindow; #endif @@ -51,7 +51,7 @@ bool BootCore(const std::string& _rFilename) { SCoreStartupParameter StartUp = SConfig::GetInstance().m_LocalCoreStartupParameter; -#if !defined(_LP64) && !defined(__APPLE__) +#if !defined(OSX64) if (g_pCodeWindow) { // StartUp.bUseDualCore = code_frame->UseDualCore(); @@ -68,7 +68,7 @@ bool BootCore(const std::string& _rFilename) SConfig::GetInstance().m_LastFilename = StartUp.m_strFilename; StartUp.bRunCompareClient = false; StartUp.bRunCompareServer = false; -#if !defined(_LP64) && !defined(__APPLE__) +#if !defined(OSX64) StartUp.bEnableDebugging = g_pCodeWindow ? true : false; // RUNNING_DEBUG #endif //osx 64 std::string BaseDataPath; @@ -93,7 +93,7 @@ bool BootCore(const std::string& _rFilename) ini.Get("Core", "SkipIdle", &StartUp.bSkipIdle, StartUp.bSkipIdle); ini.Get("Core", "OptimizeQuantizers", &StartUp.bOptimizeQuantizers, StartUp.bOptimizeQuantizers); } -#if !defined(_LP64) && !defined(__APPLE__) +#if !defined(OSX64) if(main_frame) StartUp.hMainWindow = main_frame->GetRenderHandle(); #endif @@ -104,7 +104,7 @@ bool BootCore(const std::string& _rFilename) return(false); } -#if !defined(_LP64) && !defined(__APPLE__) +#if !defined(OSX64) Core::SetState(g_pCodeWindow ? Core::CORE_PAUSE : Core::CORE_RUN); #else Core::SetState(Core::CORE_RUN); diff --git a/Source/Core/DolphinWX/Src/Globals.h b/Source/Core/DolphinWX/Src/Globals.h index 2610c0c5ee..3cd59c9d3a 100644 --- a/Source/Core/DolphinWX/Src/Globals.h +++ b/Source/Core/DolphinWX/Src/Globals.h @@ -86,7 +86,7 @@ enum //#include //#ifndef WX_PRECOMP -#if !defined(__APPLE__) +#if !defined(OSX64) #include //#endif diff --git a/Source/Core/DolphinWX/Src/ISOFile.h b/Source/Core/DolphinWX/Src/ISOFile.h index bcdb2b7a5d..c9acdf4f06 100644 --- a/Source/Core/DolphinWX/Src/ISOFile.h +++ b/Source/Core/DolphinWX/Src/ISOFile.h @@ -36,7 +36,7 @@ public: bool IsCompressed() const {return m_BlobCompressed;} u64 GetFileSize() const {return m_FileSize;} u64 GetVolumeSize() const {return m_VolumeSize;} -#if !defined(__APPLE__) +#if !defined(OSX64) const wxImage& GetImage() const {return m_Image;} #endif @@ -52,7 +52,7 @@ private: DiscIO::IVolume::ECountry m_Country; -#if !defined(__APPLE__) +#if !defined(OSX64) wxImage m_Image; #endif bool m_Valid; diff --git a/Source/Core/DolphinWX/Src/MainNoGUI.cpp b/Source/Core/DolphinWX/Src/MainNoGUI.cpp index b979f35591..b124a478ac 100644 --- a/Source/Core/DolphinWX/Src/MainNoGUI.cpp +++ b/Source/Core/DolphinWX/Src/MainNoGUI.cpp @@ -78,7 +78,7 @@ void Host_SysMessage(const char *fmt, ...) } // Include SDL header so it can hijack main(). -#if !defined(_LP64) && !defined(__APPLE__) +#if !defined(OSX64) #include #endif int main(int argc, char* argv[]) diff --git a/Source/Core/DolphinWX/Src/SConscript b/Source/Core/DolphinWX/Src/SConscript index f85f6c2f12..2747d5dc5d 100644 --- a/Source/Core/DolphinWX/Src/SConscript +++ b/Source/Core/DolphinWX/Src/SConscript @@ -29,10 +29,10 @@ libs = [ 'core', 'minilzo', 'discio', 'bdisasm', 'videocommon', 'common', 'z' ] -if not env['osx64']: - libs = [ 'debwx' ] + libs wxenv = env.Clone() -wxenv.Append( +if not wxenv['osx64']: + libs = [ 'debwx' ] + libs + wxenv.Append( CPPDEFINES = [ 'USE_XPM_BITMAPS', 'wxNEEDS_CHARPP', @@ -42,6 +42,19 @@ wxenv.Append( ], LIBS = libs ) +else: + wxenv.Append( + CPPDEFINES = [ + 'USE_XPM_BITMAPS', + 'wxNEEDS_CHARPP', + ], + LINKFLAGS = [ + '-pthread', + '-arch', + 'x86_64' + ], + LIBS = libs + ) if sys.platform == 'darwin': exeGUI = '../../../../Binary/mac/Dolphin.app/Contents/MacOS/Dolphin' @@ -72,6 +85,6 @@ else: exeNoGUI = '../../../../Binary/linux/DolphinNoGUI' objects = [ wxenv.Object(srcFile) for srcFile in files ] -if not env['osx64']: +if not wxenv['osx64']: wxenv.Program(exeGUI, objects + [ 'Main.cpp' ]) wxenv.Program(exeNoGUI, objects + [ 'MainNoGUI.cpp' ]) diff --git a/Source/Plugins/Plugin_DSP_NULL/Src/SConscript b/Source/Plugins/Plugin_DSP_NULL/Src/SConscript index aca7f8cbab..7158f1f3ea 100644 --- a/Source/Plugins/Plugin_DSP_NULL/Src/SConscript +++ b/Source/Plugins/Plugin_DSP_NULL/Src/SConscript @@ -23,8 +23,16 @@ files = [ ] dspenv = env.Clone() -dspenv.Append( +if not dspenv['osx64']: + dspenv.Append( CXXFLAGS = [ '-fPIC' ], LIBS = [ 'common' ], ) +else: + dspenv.Append( + CXXFLAGS = [ '-fPIC','-arch', 'x86_64' ], + LINKFLAGS = [ '-arch', 'x86_64' ], + LIBS = [ 'common' ], + ) + dspenv.SharedLibrary(output, files) diff --git a/Source/Plugins/Plugin_PadSimple/Src/PadSimple.cpp b/Source/Plugins/Plugin_PadSimple/Src/PadSimple.cpp index 2557057f6e..1b55d32101 100644 --- a/Source/Plugins/Plugin_PadSimple/Src/PadSimple.cpp +++ b/Source/Plugins/Plugin_PadSimple/Src/PadSimple.cpp @@ -23,7 +23,9 @@ #include "PadSimple.h" #include "IniFile.h" +#if !defined(OSX64) #include "GUI/ConfigDlg.h" +#endif #ifdef _WIN32 #include "XInput.h" @@ -163,7 +165,7 @@ void DllConfig(HWND _hParent) ConfigDialog frame(&win); frame.ShowModal(); win.SetHWND(0); -#else +#elif !defined(OSX64) ConfigDialog frame(NULL); frame.ShowModal(); #endif diff --git a/Source/Plugins/Plugin_PadSimple/Src/SConscript b/Source/Plugins/Plugin_PadSimple/Src/SConscript index 145f0e5b64..ecff811a4b 100644 --- a/Source/Plugins/Plugin_PadSimple/Src/SConscript +++ b/Source/Plugins/Plugin_PadSimple/Src/SConscript @@ -10,11 +10,21 @@ else: files = [ "PadSimple.cpp", - "XInputBase.cpp", - "GUI/ConfigDlg.cpp", ] - padenv = env.Clone() + +if not padenv['osx64']: + file += [ + "GUI/ConfigDlg.cpp", + "XInputBase.cpp", + ] + padenv.Append(LIBS = [ 'common' ]) -if not env['osx64']: - padenv.SharedLibrary(output, files) + +if padenv['osx64']: + padenv.Append( + CXXFLAGS = [ '-arch', 'x86_64' ], + LINKFLAGS = [ '-arch', 'x86_64' ], + ) + +padenv.SharedLibrary(output, files)