From 3d37a6ce278252262066c8d10e45ffee1375f4d2 Mon Sep 17 00:00:00 2001 From: Ryan Houdek Date: Sun, 3 Aug 2014 13:11:22 -0500 Subject: [PATCH] Removes the usage of __LINUX__ define This is defined and set it a ton of different places. It's checked in a whole lot more Instead just use __linux__ like a real project should --- common/include/PS2Edefs.h | 2 +- common/include/PS2Eext.h | 2 +- common/include/Pcsx2Defs.h | 9 +++------ common/include/Pcsx2Types.h | 6 +++--- common/include/Utilities/MemcpyFast.h | 2 +- common/include/Utilities/PageFaultSource.h | 2 +- common/include/Utilities/Threading.h | 2 +- common/include/intrin_x86.h | 4 ++-- common/src/Utilities/Console.cpp | 8 ++++---- common/src/Utilities/Linux/LnxThreads.cpp | 2 +- common/src/Utilities/ThreadTools.cpp | 2 +- common/src/Utilities/vssprintf.cpp | 2 +- common/src/Utilities/wxHelpers.cpp | 4 ++-- common/src/Utilities/x86/MemcpyVibes.cpp | 2 +- common/src/x86emitter/cpudetect.cpp | 6 +++--- pcsx2/CDVD/zlib_indexed.h | 4 ++-- pcsx2/DebugTools/DisR5900asm.cpp | 2 +- pcsx2/Gte.cpp | 2 +- pcsx2/Memory.h | 2 +- pcsx2/NakedAsm.h | 2 +- pcsx2/PluginManager.cpp | 4 ++-- pcsx2/gui/AppMain.cpp | 2 +- pcsx2/gui/ConsoleLogger.cpp | 6 +++--- pcsx2/gui/CpuUsageProvider.cpp | 2 +- pcsx2/gui/Debugger/DebuggerLists.cpp | 4 ++-- pcsx2/gui/FrameForGS.cpp | 10 +++++----- pcsx2/gui/MainFrame.cpp | 4 ++-- pcsx2/gui/Panels/MemoryCardListPanel.cpp | 2 +- pcsx2/gui/Panels/PluginSelectorPanel.cpp | 2 +- pcsx2/gui/RecentIsoList.cpp | 4 ++-- pcsx2/gui/i18n.cpp | 2 +- pcsx2/vtlb.cpp | 4 ++-- pcsx2/x86/iR3000A.cpp | 2 +- pcsx2/x86/microVU_Misc.h | 2 +- pcsx2/x86/sVU_zerorec.cpp | 4 ++-- pcsx2/x86/sVU_zerorec.h | 4 ++-- plugins/CDVDiso/src/Linux/Makefile | 2 +- plugins/CDVDisoEFP/src/Linux/CD.h | 5 ----- plugins/CDVDisoEFP/src/Linux/CDVDiso.c | 5 ----- plugins/CDVDisoEFP/src/Linux/DVD.h | 5 ----- plugins/CDVDisoEFP/src/Linux/device.h | 5 ----- plugins/CDVDisoEFP/src/Linux/devicebox.c | 5 ----- plugins/CDVDisoEFP/src/PS2Edefs.h | 4 ++-- plugins/CDVDisoEFP/src/PS2Etypes.h | 6 +----- plugins/CDVDisoEFP/src/ecma119.c | 6 ------ plugins/CDVDisoEFP/src/ecma119.h | 6 ------ plugins/CDVDisoEFP/src/imagetype.c | 5 ----- plugins/CDVDisoEFP/src/imagetype.h | 6 ------ plugins/CDVDisoEFP/src/ini.h | 6 ------ plugins/CDVDisoEFP/src/isocompress.c | 6 ------ plugins/CDVDisoEFP/src/isofile.c | 5 ----- plugins/CDVDisoEFP/src/multifile.c | 5 ----- plugins/CDVDisoEFP/src/multifile.h | 6 ------ plugins/CDVDisoEFP/src/toc.c | 5 ----- plugins/CDVDisoEFP/src/toc.h | 6 ------ plugins/CDVDisoEFP/src/version.c | 6 ------ plugins/CDVDisoEFP/src/version.h | 6 ------ plugins/CDVDlinuz/Src/Linux/CD.h | 12 ------------ plugins/CDVDlinuz/Src/Linux/CDVDlinuz.c | 6 ------ plugins/CDVDlinuz/Src/Linux/DVD.h | 12 ------------ plugins/CDVDlinuz/Src/Linux/conf.h | 12 ------------ plugins/CDVDlinuz/Src/Linux/device.h | 10 ---------- plugins/CDVDlinuz/Src/PS2Edefs.h | 4 ++-- plugins/CDVDlinuz/Src/PS2Etypes.h | 2 +- plugins/CDVDlinuz/Src/buffer.c | 12 ------------ plugins/CDVDlinuz/Src/ini.h | 12 ------------ plugins/CDVDlinuz/Src/version.c | 12 ------------ plugins/CDVDlinuz/Src/version.h | 12 ------------ plugins/CDVDpeops/CDVDiso.c | 2 +- plugins/CDVDpeops/PS2Edefs.h | 4 ++-- plugins/CDVDpeops/PS2Etypes.h | 2 +- plugins/GSnull/GS.cpp | 2 +- plugins/GSnull/GS.h | 2 +- plugins/cdvdGigaherz/src/FileStream.cpp | 6 +++--- plugins/dev9ghzdrk/PS2Edefs.h | 4 ++-- plugins/dev9ghzdrk/PS2Etypes.h | 2 +- plugins/onepad/controller.h | 2 +- plugins/onepad/keyboard.cpp | 6 +++--- plugins/onepad/keyboard.h | 2 +- plugins/onepad/onepad.cpp | 6 +++--- plugins/onepad/onepad.h | 2 +- plugins/spu2-x/src/Config.h | 2 +- plugins/spu2-x/src/Global.h | 4 +--- plugins/spu2-x/src/Mixer.cpp | 2 +- plugins/spu2-x/src/PS2E-spu2.cpp | 4 ++-- plugins/spu2-x/src/PS2E-spu2.h | 4 ++-- plugins/spu2-x/src/SndOut.cpp | 4 ++-- plugins/spu2-x/src/SndOut.h | 2 +- plugins/spu2-x/src/SndOut_Portaudio.cpp | 2 +- plugins/spu2-x/src/Wavedump_wav.cpp | 4 ++-- plugins/zerogs/opengl/common/PS2Edefs.h | 2 +- plugins/zerogs/opengl/common/PS2Etypes.h | 14 +++++--------- plugins/zerospu2/Targets/SoundTargets.cpp | 2 +- plugins/zerospu2/Targets/SoundTargets.h | 2 +- plugins/zerospu2/misc.h | 2 +- plugins/zerospu2/zerospu2.cpp | 2 +- plugins/zerospu2/zeroworker.cpp | 2 +- plugins/zzogl-pg-cg/opengl/GSmain.cpp | 2 +- plugins/zzogl-pg-cg/opengl/Profile.h | 2 +- plugins/zzogl-pg-cg/opengl/ZZLog.h | 2 +- plugins/zzogl-pg-cg/opengl/targets.cpp | 2 +- plugins/zzogl-pg/opengl/GSmain.cpp | 2 +- plugins/zzogl-pg/opengl/Profile.h | 2 +- plugins/zzogl-pg/opengl/ZZLog.h | 2 +- plugins/zzogl-pg/opengl/targets.cpp | 2 +- tools/bin2cpp/bin2cpp.cpp | 4 ---- 106 files changed, 121 insertions(+), 337 deletions(-) diff --git a/common/include/PS2Edefs.h b/common/include/PS2Edefs.h index 3b2feea96e..2260212140 100644 --- a/common/include/PS2Edefs.h +++ b/common/include/PS2Edefs.h @@ -41,7 +41,7 @@ * Since this is still beta things may change. * OSflags: - __LINUX__ (linux OS) + __linux__ (linux OS) _WIN32 (win32 OS) * common return values (for ie. GSinit): diff --git a/common/include/PS2Eext.h b/common/include/PS2Eext.h index c7df9db28c..2886f84138 100644 --- a/common/include/PS2Eext.h +++ b/common/include/PS2Eext.h @@ -161,7 +161,7 @@ struct PluginConf } }; -#ifdef __LINUX__ +#ifdef __linux__ static void SysMessage(const char *fmt, ...) { diff --git a/common/include/Pcsx2Defs.h b/common/include/Pcsx2Defs.h index 1efab3d502..1c36b13590 100644 --- a/common/include/Pcsx2Defs.h +++ b/common/include/Pcsx2Defs.h @@ -19,11 +19,8 @@ // Indicate that this is the wx port to the plugins. #define WX_PCSX2 -// some distributions are lower case -#if defined (__linux__) || defined(__CYGWIN__) -#if !defined(__LINUX__) -# define __LINUX__ -#endif +#ifdef __CYGWIN__ +#define __linux__ #endif #include "Pcsx2Types.h" @@ -77,7 +74,7 @@ extern "C" unsigned __int64 __xgetbv(int); // restaints must be enforced). // #ifndef C_ASSERT - #ifdef __LINUX__ + #ifdef __linux__ # define C_ASSERT(e) static_assert(e, "this is a nice message to explain the failure ;)") #else # define C_ASSERT(e) typedef char __C_ASSERT__[(e)?1:-1] diff --git a/common/include/Pcsx2Types.h b/common/include/Pcsx2Types.h index d1a42bd190..03d74de68d 100644 --- a/common/include/Pcsx2Types.h +++ b/common/include/Pcsx2Types.h @@ -50,7 +50,7 @@ typedef unsigned int uint; #else // _MSC_VER*/ -#ifdef __LINUX__ +#ifdef __linux__ #ifdef HAVE_STDINT_H #include "stdint.h" @@ -96,10 +96,10 @@ typedef union _LARGE_INTEGER long long QuadPart; } LARGE_INTEGER; -#endif // __LINUX__ +#endif // __linux__ #endif //_MSC_VER -#if !defined(__LINUX__) || !defined(HAVE_STDINT_H) +#if !defined(__linux__) || !defined(HAVE_STDINT_H) #if defined(__x86_64__) typedef u64 uptr; typedef s64 sptr; diff --git a/common/include/Utilities/MemcpyFast.h b/common/include/Utilities/MemcpyFast.h index 800c1071b6..837554953d 100644 --- a/common/include/Utilities/MemcpyFast.h +++ b/common/include/Utilities/MemcpyFast.h @@ -15,7 +15,7 @@ #pragma once -#ifdef __LINUX__ +#ifdef __linux__ # include "lnx_memzero.h" diff --git a/common/include/Utilities/PageFaultSource.h b/common/include/Utilities/PageFaultSource.h index a4d971b010..899fcf0f6b 100644 --- a/common/include/Utilities/PageFaultSource.h +++ b/common/include/Utilities/PageFaultSource.h @@ -332,7 +332,7 @@ protected: uint _calcBlockBitArrayLength() const; }; -#ifdef __LINUX__ +#ifdef __linux__ # define PCSX2_PAGEFAULT_PROTECT # define PCSX2_PAGEFAULT_EXCEPT diff --git a/common/include/Utilities/Threading.h b/common/include/Utilities/Threading.h index 16411e29f4..846c84711c 100644 --- a/common/include/Utilities/Threading.h +++ b/common/include/Utilities/Threading.h @@ -408,7 +408,7 @@ namespace Threading ScopedLock m_lock; volatile __aligned(4) bool& m_bool; -#ifdef __LINUX__ +#ifdef __linux__ ScopedLockBool(Mutex& mutexToLock, volatile bool& isLockedBool) #else ScopedLockBool(Mutex& mutexToLock, volatile __aligned(4) bool& isLockedBool) diff --git a/common/include/intrin_x86.h b/common/include/intrin_x86.h index 658ad518d2..8d1143c2e3 100644 --- a/common/include/intrin_x86.h +++ b/common/include/intrin_x86.h @@ -845,7 +845,7 @@ static __inline__ __attribute__((always_inline)) unsigned long long __xgetbv(uns // gcc 4.8 define __rdtsc but unfortunately the compiler crash... // The redefine allow to skip the gcc __rdtsc version -- Gregory -#ifdef __LINUX__ +#ifdef __linux__ static __inline__ __attribute__((always_inline)) unsigned long long __pcsx2__rdtsc(void) #else static __inline__ __attribute__((always_inline)) unsigned long long __rdtsc(void) @@ -858,7 +858,7 @@ static __inline__ __attribute__((always_inline)) unsigned long long __rdtsc(void /*** Interrupts ***/ -#ifndef __LINUX__ +#ifndef __linux__ static __inline__ __attribute__((always_inline)) void __debugbreak(void) { __asm__("int $3"); diff --git a/common/src/Utilities/Console.cpp b/common/src/Utilities/Console.cpp index 7dc36552c0..ad0ec55578 100644 --- a/common/src/Utilities/Console.cpp +++ b/common/src/Utilities/Console.cpp @@ -104,7 +104,7 @@ const IConsoleWriter ConsoleWriter_Null = // Console_Stdout // -------------------------------------------------------------------------------------- -#ifdef __LINUX__ +#ifdef __linux__ static __fi const wxChar* GetLinuxConsoleColor(ConsoleColors color) { switch(color) @@ -165,15 +165,15 @@ static void __concall ConsoleStdout_Newline() static void __concall ConsoleStdout_DoSetColor( ConsoleColors color ) { -#ifdef __LINUX__ +#ifdef __linux__ wxPrintf(L"\033[0m"); - wxPrintf(GetLinuxConsoleColor(color)); + wxPrintf(GetLinuxConsoleColor(color)); #endif } static void __concall ConsoleStdout_SetTitle( const wxString& title ) { -#ifdef __LINUX__ +#ifdef __linux__ wxPrintf(L"\033]0;%s\007", title.c_str()); #endif } diff --git a/common/src/Utilities/Linux/LnxThreads.cpp b/common/src/Utilities/Linux/LnxThreads.cpp index c3921caac5..924d3b20c2 100644 --- a/common/src/Utilities/Linux/LnxThreads.cpp +++ b/common/src/Utilities/Linux/LnxThreads.cpp @@ -23,7 +23,7 @@ // to remove an unneeded dependency. //#include "x86emitter/tools.h" -#if !defined(__LINUX__) && !defined(__WXMAC__) +#if !defined(__linux__) && !defined(__WXMAC__) # pragma message( "LnxThreads.cpp should only be compiled by projects or makefiles targeted at Linux/Mac distros.") diff --git a/common/src/Utilities/ThreadTools.cpp b/common/src/Utilities/ThreadTools.cpp index e74585d522..ac3c7e0c00 100644 --- a/common/src/Utilities/ThreadTools.cpp +++ b/common/src/Utilities/ThreadTools.cpp @@ -16,7 +16,7 @@ #include "PrecompiledHeader.h" -#ifdef __LINUX__ +#ifdef __linux__ # include // for pthread_kill, which is in pthread.h on w32-pthreads #endif diff --git a/common/src/Utilities/vssprintf.cpp b/common/src/Utilities/vssprintf.cpp index 8af6151aaf..79452c8b01 100644 --- a/common/src/Utilities/vssprintf.cpp +++ b/common/src/Utilities/vssprintf.cpp @@ -51,7 +51,7 @@ #define is_digit(c) ((c) >= '0' && (c) <= '9') -#ifdef __LINUX__ +#ifdef __linux__ #define _CVTBUFSIZE (309+40) #endif diff --git a/common/src/Utilities/wxHelpers.cpp b/common/src/Utilities/wxHelpers.cpp index 345a02fe2c..a0d189e3b4 100644 --- a/common/src/Utilities/wxHelpers.cpp +++ b/common/src/Utilities/wxHelpers.cpp @@ -19,7 +19,7 @@ #include "Threading.h" #include "IniInterface.h" -#ifdef __LINUX__ +#ifdef __linux__ // I do not know if it is a GCC issue or a bug in wxwidget ! // Anyway the code isn't used (m_hasContextHelp always false) so I remove // it for linux. The 'vtable' issue appears with the include of @@ -474,7 +474,7 @@ int pxGetCharHeight( const wxWindow* wind, int rows ) if( !wind ) return 0; wxClientDC dc(wx_const_cast(wxWindow*, wind)); dc.SetFont( wind->GetFont() ); -#ifdef __LINUX__ +#ifdef __linux__ // It seems there is a bad detection of the size of the font (non standard dpi ???). Font are cut in top or bottom. // Add a correction factor to leave enough room. Visualy 1.7 seems fine but feel free to tune it -- Gregory return (dc.GetCharHeight() * 1.7 + 1 ) * rows; diff --git a/common/src/Utilities/x86/MemcpyVibes.cpp b/common/src/Utilities/x86/MemcpyVibes.cpp index d6a29f466d..6d4ff9f934 100644 --- a/common/src/Utilities/x86/MemcpyVibes.cpp +++ b/common/src/Utilities/x86/MemcpyVibes.cpp @@ -159,7 +159,7 @@ __fi void memcpy_vibes(void * dest, const void * src, int size) { // Since MemcpyVibes is already in the project, I'll just tuck the Linux version of memcpy_amd_qwc here for the moment, // to get around compilation issues with having it in the headers. -#ifdef __LINUX__ +#ifdef __linux__ // This can be moved later, but Linux doesn't even compile memcpyFast.cpp, so I figured I'd stick it here for now. // Quadword Copy! Count is in QWCs (128 bits). Neither source nor dest need to be aligned. diff --git a/common/src/x86emitter/cpudetect.cpp b/common/src/x86emitter/cpudetect.cpp index d909cc9482..f04434c485 100644 --- a/common/src/x86emitter/cpudetect.cpp +++ b/common/src/x86emitter/cpudetect.cpp @@ -25,7 +25,7 @@ __aligned16 x86capabilities x86caps; static __pagealigned u8 recSSE[__pagesize]; static __pagealigned u8 targetFXSAVE[512]; -#ifdef __LINUX__ +#ifdef __linux__ # include # include #endif @@ -104,7 +104,7 @@ s64 x86capabilities::_CPUSpeedHz( u64 time ) const do { timeStart = GetCPUTicks(); -#ifdef __LINUX__ +#ifdef __linux__ startCycle = __pcsx2__rdtsc(); #else startCycle = __rdtsc(); @@ -113,7 +113,7 @@ s64 x86capabilities::_CPUSpeedHz( u64 time ) const do { timeStop = GetCPUTicks(); -#ifdef __LINUX__ +#ifdef __linux__ endCycle = __pcsx2__rdtsc(); #else endCycle = __rdtsc(); diff --git a/pcsx2/CDVD/zlib_indexed.h b/pcsx2/CDVD/zlib_indexed.h index 5fa431c41b..f11eecb086 100644 --- a/pcsx2/CDVD/zlib_indexed.h +++ b/pcsx2/CDVD/zlib_indexed.h @@ -101,7 +101,7 @@ Comments) 1950 to 1952 in the files http://tools.ietf.org/html/rfc1950 #include #include #include -#ifdef __LINUX__ +#ifdef __linux__ #include #else #include @@ -475,4 +475,4 @@ extract_ret: return ret; } -#endif /* __ZLIB_INDEXED_H__ */ \ No newline at end of file +#endif /* __ZLIB_INDEXED_H__ */ diff --git a/pcsx2/DebugTools/DisR5900asm.cpp b/pcsx2/DebugTools/DisR5900asm.cpp index 01dd2b27dc..a92474ca85 100644 --- a/pcsx2/DebugTools/DisR5900asm.cpp +++ b/pcsx2/DebugTools/DisR5900asm.cpp @@ -16,7 +16,7 @@ #include "PrecompiledHeader.h" -#ifdef __LINUX__ +#ifdef __linux__ #include #endif diff --git a/pcsx2/Gte.cpp b/pcsx2/Gte.cpp index e5d0a48bb4..be521bfad7 100644 --- a/pcsx2/Gte.cpp +++ b/pcsx2/Gte.cpp @@ -229,7 +229,7 @@ __inline void MTC2(unsigned long value, int reg) { } else { psxRegs.CP2D.r[31] = 32; } -#elif defined(__LINUX__) || defined(__MINGW32__) +#elif defined(__linux__) || defined(__MINGW32__) if (a > 0) { __asm__ ("bsrl %1, %0\n" : "=r"(a) : "r"(a) ); psxRegs.CP2D.r[31] = 31 - a; diff --git a/pcsx2/Memory.h b/pcsx2/Memory.h index 2833a94e87..883aebd136 100644 --- a/pcsx2/Memory.h +++ b/pcsx2/Memory.h @@ -15,7 +15,7 @@ #pragma once -#ifdef __LINUX__ +#ifdef __linux__ #include #endif diff --git a/pcsx2/NakedAsm.h b/pcsx2/NakedAsm.h index 0446e243c8..4589bccc02 100644 --- a/pcsx2/NakedAsm.h +++ b/pcsx2/NakedAsm.h @@ -17,7 +17,7 @@ #ifndef NAKED_ASM_H #define NAKED_ASM_H -#ifdef __LINUX__ +#ifdef __linux__ extern "C" { diff --git a/pcsx2/PluginManager.cpp b/pcsx2/PluginManager.cpp index 19947d9277..4b27665cf2 100644 --- a/pcsx2/PluginManager.cpp +++ b/pcsx2/PluginManager.cpp @@ -853,7 +853,7 @@ SysCorePlugins::PluginStatus_t::PluginStatus_t( PluginsEnum_t _pid, const wxStri _PS2EgetLibName GetLibName = (_PS2EgetLibName) Lib.GetSymbol( L"PS2EgetLibName" ); _PS2EgetLibVersion2 GetLibVersion2 = (_PS2EgetLibVersion2) Lib.GetSymbol( L"PS2EgetLibVersion2" ); -#ifdef __LINUX__ +#ifdef __linux__ _PS2EsetEmuVersion SetEmuVersion = NULL; #else _PS2EsetEmuVersion SetEmuVersion = (_PS2EsetEmuVersion) Lib.GetSymbol( L"PS2EsetEmuVersion" ); @@ -1188,7 +1188,7 @@ void SysCorePlugins::Open() // If GS doesn't support GSopen2, need to wait until call to GSopen // returns to populate pDsp. If it does, can initialize other plugins // at same time as GS, as long as GSopen2 does not subclass its window. -#ifdef __LINUX__ +#ifdef __linux__ // On linux, application have also a channel (named display) to communicate with the // Xserver. The safe rule is 1 thread, 1 channel. In our case we use the display in // several places. Save yourself of multithread headache. Wait few seconds the end of diff --git a/pcsx2/gui/AppMain.cpp b/pcsx2/gui/AppMain.cpp index 8469af7231..aa74093e9a 100644 --- a/pcsx2/gui/AppMain.cpp +++ b/pcsx2/gui/AppMain.cpp @@ -353,7 +353,7 @@ public: return Path::Combine( GetDataDir(), L"Langs" ); } -#ifdef __LINUX__ +#ifdef __linux__ wxString GetUserLocalDataDir() const { // I got memory corruption inside wxGetEnv when I heavily toggle the GS renderer (F9). It seems wxGetEnv diff --git a/pcsx2/gui/ConsoleLogger.cpp b/pcsx2/gui/ConsoleLogger.cpp index ed75ad910a..8ad4d5ad58 100644 --- a/pcsx2/gui/ConsoleLogger.cpp +++ b/pcsx2/gui/ConsoleLogger.cpp @@ -1019,11 +1019,11 @@ void Pcsx2App::ProgramLog_PostEvent( wxEvent& evt ) static void __concall ConsoleToFile_Newline() { -#ifdef __LINUX__ +#ifdef __linux__ if ((g_Conf) && (g_Conf->EmuOptions.ConsoleToStdio)) ConsoleWriter_Stdout.Newline(); #endif -#ifdef __LINUX__ +#ifdef __linux__ fputc( '\n', emuLog ); #else fputs( "\r\n", emuLog ); @@ -1032,7 +1032,7 @@ static void __concall ConsoleToFile_Newline() static void __concall ConsoleToFile_DoWrite( const wxString& fmt ) { -#ifdef __LINUX__ +#ifdef __linux__ if ((g_Conf) && (g_Conf->EmuOptions.ConsoleToStdio)) ConsoleWriter_Stdout.WriteRaw(fmt); #endif diff --git a/pcsx2/gui/CpuUsageProvider.cpp b/pcsx2/gui/CpuUsageProvider.cpp index f2ba2f5574..4ee87d0a89 100644 --- a/pcsx2/gui/CpuUsageProvider.cpp +++ b/pcsx2/gui/CpuUsageProvider.cpp @@ -18,7 +18,7 @@ #include "CpuUsageProvider.h" #include "System.h" -#ifndef __LINUX__ +#ifndef __linux__ #include "SysThreads.h" #endif diff --git a/pcsx2/gui/Debugger/DebuggerLists.cpp b/pcsx2/gui/Debugger/DebuggerLists.cpp index fb70350d23..876b2270d1 100644 --- a/pcsx2/gui/Debugger/DebuggerLists.cpp +++ b/pcsx2/gui/Debugger/DebuggerLists.cpp @@ -75,7 +75,7 @@ GenericListViewColumn breakpointColumns[BPL_COLUMNCOUNT] = { BreakpointList::BreakpointList(wxWindow* parent, DebugInterface* _cpu, CtrlDisassemblyView* _disassembly) : wxListView(parent,wxID_ANY,wxDefaultPosition,wxDefaultSize,wxLC_VIRTUAL|wxLC_REPORT|wxLC_SINGLE_SEL|wxNO_BORDER), cpu(_cpu), disasm(_disassembly) { -#ifdef __LINUX__ +#ifdef __linux__ // On linux wx failed to resize properly the page. I don't know why so for the moment I just create a static size page // Far from ideal but at least I can use the memory window! this->SetSize(wxSize(1000, 200)); @@ -429,4 +429,4 @@ void BreakpointList::mouseEvent(wxMouseEvent& evt) void BreakpointList::listEvent(wxListEvent& evt) { showMenu(clickPos); -} \ No newline at end of file +} diff --git a/pcsx2/gui/FrameForGS.cpp b/pcsx2/gui/FrameForGS.cpp index cdcedae9f6..bfc522f1a2 100644 --- a/pcsx2/gui/FrameForGS.cpp +++ b/pcsx2/gui/FrameForGS.cpp @@ -206,7 +206,7 @@ void GSPanel::OnMouseEvent( wxMouseEvent& evt ) DoShowMouse(); } -#ifdef __LINUX__ +#ifdef __linux__ // HACK2: In gsopen2 there is one event buffer read by both wx/gui and pad plugin. Wx deletes // the event before the pad see it. So you send key event directly to the pad. if( (PADWriteEvent != NULL) && (GSopen2 != NULL) ) { @@ -269,7 +269,7 @@ void GSPanel::OnKeyDown( wxKeyEvent& evt ) // to the APP level message handler, which in turn routes them right back here -- yes it's // silly, but oh well). -#ifdef __LINUX__ +#ifdef __linux__ // HACK2: In gsopen2 there is one event buffer read by both wx/gui and pad plugin. Wx deletes // the event before the pad see it. So you send key event directly to the pad. if( (PADWriteEvent != NULL) && (GSopen2 != NULL) ) { @@ -325,7 +325,7 @@ void GSPanel::OnFocus( wxFocusEvent& evt ) else DoShowMouse(); -#ifdef __LINUX__ +#ifdef __linux__ // HACK2: In gsopen2 there is one event buffer read by both wx/gui and pad plugin. Wx deletes // the event before the pad see it. So you send key event directly to the pad. if( (PADWriteEvent != NULL) && (GSopen2 != NULL) ) { @@ -341,7 +341,7 @@ void GSPanel::OnFocusLost( wxFocusEvent& evt ) evt.Skip(); m_HasFocus = false; DoShowMouse(); -#ifdef __LINUX__ +#ifdef __linux__ // HACK2: In gsopen2 there is one event buffer read by both wx/gui and pad plugin. Wx deletes // the event before the pad see it. So you send key event directly to the pad. if( (PADWriteEvent != NULL) && (GSopen2 != NULL) ) { @@ -527,7 +527,7 @@ GSPanel* GSFrame::GetViewport() void GSFrame::OnUpdateTitle( wxTimerEvent& evt ) { -#ifdef __LINUX__ +#ifdef __linux__ // Important Linux note: When the title is set in fullscreen the window is redrawn. Unfortunately // an intermediate white screen appears too which leads to a very annoying flickering. if (IsFullScreen()) return; diff --git a/pcsx2/gui/MainFrame.cpp b/pcsx2/gui/MainFrame.cpp index da55b469eb..db0a907c34 100644 --- a/pcsx2/gui/MainFrame.cpp +++ b/pcsx2/gui/MainFrame.cpp @@ -490,7 +490,7 @@ MainEmuFrame::MainEmuFrame(wxWindow* parent, const wxString& title) // ------------------------------------------------------------------------ m_menuMisc.Append( &m_MenuItem_Console ); -#ifdef __LINUX__ +#ifdef __linux__ m_menuMisc.Append( &m_MenuItem_Console_Stdio ); #endif //Todo: Though not many people need this one :p @@ -681,7 +681,7 @@ void MainEmuFrame::ApplyConfigToGui(AppConfig& configToApply, int flags) menubar.Check( MenuId_EnableCheats, configToApply.EmuOptions.EnableCheats ); menubar.Check( MenuId_EnableWideScreenPatches, configToApply.EmuOptions.EnableWideScreenPatches ); menubar.Check( MenuId_EnableHostFs, configToApply.EmuOptions.HostFs ); -#ifdef __LINUX__ +#ifdef __linux__ menubar.Check( MenuId_Console_Stdio, configToApply.EmuOptions.ConsoleToStdio ); #endif diff --git a/pcsx2/gui/Panels/MemoryCardListPanel.cpp b/pcsx2/gui/Panels/MemoryCardListPanel.cpp index 8a4d468fd4..05ede4403e 100644 --- a/pcsx2/gui/Panels/MemoryCardListPanel.cpp +++ b/pcsx2/gui/Panels/MemoryCardListPanel.cpp @@ -252,7 +252,7 @@ protected: public: McdDataObject(int viewIndex = -1) -#ifdef __LINUX__ +#ifdef __linux__ // XXX: On linux drag and drop doesn't work. I think wxDF_PRIVATE is a MS extension. // Besides it will raise on assertion on wx3.0. // diff --git a/pcsx2/gui/Panels/PluginSelectorPanel.cpp b/pcsx2/gui/Panels/PluginSelectorPanel.cpp index 961a17cc9c..8ccaa39a64 100644 --- a/pcsx2/gui/Panels/PluginSelectorPanel.cpp +++ b/pcsx2/gui/Panels/PluginSelectorPanel.cpp @@ -30,7 +30,7 @@ // Allows us to force-disable threading for debugging/troubleshooting static const bool DisableThreading = -#ifdef __LINUX__ +#ifdef __linux__ true; // linux appears to have threading issues with loadlibrary. #else false; diff --git a/pcsx2/gui/RecentIsoList.cpp b/pcsx2/gui/RecentIsoList.cpp index 8b6cb7efdb..7198496542 100644 --- a/pcsx2/gui/RecentIsoList.cpp +++ b/pcsx2/gui/RecentIsoList.cpp @@ -76,7 +76,7 @@ void RecentIsoManager::OnChangedSelection( wxCommandEvent& evt ) ScopedCoreThreadPopup stopped_core; -#ifdef __LINUX__ +#ifdef __linux__ // Likely not what was intended, but it compiles for the moment... SwapOrReset_Iso( NULL, stopped_core, m_Items[i].Filename, GetMsg_IsoImageChanged()); #else @@ -126,7 +126,7 @@ void RecentIsoManager::Repopulate() // wxwidgets deletes the group, but when you start adding radio menu items again, // it trys to add them to a group that doesn't exist. Since the group doesn't exist, // it starts a new group, but it also spews a couple warnings about it in Linux. -#ifdef __LINUX__ +#ifdef __linux__ // FIXME is it still useful on v3 #if wxMAJOR_VERSION >= 3 m_Menu->Remove( m_Menu->Append( -1, "dummy" ) ); diff --git a/pcsx2/gui/i18n.cpp b/pcsx2/gui/i18n.cpp index c9633b5243..6361f2238b 100644 --- a/pcsx2/gui/i18n.cpp +++ b/pcsx2/gui/i18n.cpp @@ -374,7 +374,7 @@ void i18n_SetLanguagePath() // default location for windows wxLocale::AddCatalogLookupPathPrefix( wxGetCwd() ); // additional location for linux -#ifdef __LINUX__ +#ifdef __linux__ wxLocale::AddCatalogLookupPathPrefix( PathDefs::GetLangs().ToString() ); #endif diff --git a/pcsx2/vtlb.cpp b/pcsx2/vtlb.cpp index 54c6cd487c..05a9c7736f 100644 --- a/pcsx2/vtlb.cpp +++ b/pcsx2/vtlb.cpp @@ -380,7 +380,7 @@ static __ri void vtlb_Miss(u32 addr,u32 mode) // The exception terminate the program on linux which is very annoying // Just disable it for the moment -#ifdef __LINUX__ +#ifdef __linux__ if (0) #else if( IsDevBuild ) @@ -401,7 +401,7 @@ static __ri void vtlb_BusError(u32 addr,u32 mode) { // The exception terminate the program on linux which is very annoying // Just disable it for the moment -#ifdef __LINUX__ +#ifdef __linux__ if (0) #else if( IsDevBuild ) diff --git a/pcsx2/x86/iR3000A.cpp b/pcsx2/x86/iR3000A.cpp index 10664fed68..01f273ada3 100644 --- a/pcsx2/x86/iR3000A.cpp +++ b/pcsx2/x86/iR3000A.cpp @@ -422,7 +422,7 @@ static void iIopDumpBlock( int startpc, u8 * ptr ) f.Printf("\n"); } -#ifdef __LINUX__ +#ifdef __linux__ char command[256]; // dump the asm { diff --git a/pcsx2/x86/microVU_Misc.h b/pcsx2/x86/microVU_Misc.h index 226c1abe2e..00f31681d8 100644 --- a/pcsx2/x86/microVU_Misc.h +++ b/pcsx2/x86/microVU_Misc.h @@ -184,7 +184,7 @@ typedef Fntype_mVUrecInst* Fnptr_mVUrecInst; //------------------------------------------------------------------ // Define mVUquickSearch //------------------------------------------------------------------ -#ifndef __LINUX__ +#ifndef __linux__ extern __pagealigned u8 mVUsearchXMM[__pagesize]; typedef u32 (__fastcall *mVUCall)(void*, void*); #define mVUquickSearch(dest, src, size) ((((mVUCall)((void*)mVUsearchXMM))(dest, src)) == 0xf) diff --git a/pcsx2/x86/sVU_zerorec.cpp b/pcsx2/x86/sVU_zerorec.cpp index d08e6e6be6..6354a8bbff 100644 --- a/pcsx2/x86/sVU_zerorec.cpp +++ b/pcsx2/x86/sVU_zerorec.cpp @@ -664,7 +664,7 @@ void SuperVUDumpBlock(list& blocks, int vuindex) } // -#if 0 // __LINUX__ +#if 0 // __linux__ // dump the asm if ((*itblock)->pcode != NULL) @@ -904,7 +904,7 @@ static VuFunctionHeader* SuperVURecompileProgram(u32 startpc, int vuindex) s_pFnHeader->ranges.push_back(r); } -#if defined(PCSX2_DEBUG) && defined(__LINUX__) +#if defined(PCSX2_DEBUG) && defined(__linux__) // dump at the end to capture the actual code if ((s_vu && (vudump&1)) || (!s_vu && (vudump&16))) SuperVUDumpBlock(s_listBlocks, s_vu); #endif diff --git a/pcsx2/x86/sVU_zerorec.h b/pcsx2/x86/sVU_zerorec.h index c346610e18..07f5a9913f 100644 --- a/pcsx2/x86/sVU_zerorec.h +++ b/pcsx2/x86/sVU_zerorec.h @@ -20,13 +20,13 @@ #include "sVU_Micro.h" //Using assembly code from an external file. -#ifdef __LINUX__ +#ifdef __linux__ extern "C" { #endif extern void SuperVUExecuteProgram(u32 startpc, int vuindex); extern void SuperVUEndProgram(); extern void svudispfntemp(); -#ifdef __LINUX__ +#ifdef __linux__ } #endif diff --git a/plugins/CDVDiso/src/Linux/Makefile b/plugins/CDVDiso/src/Linux/Makefile index 02eeaea008..eb5b0f7948 100644 --- a/plugins/CDVDiso/src/Linux/Makefile +++ b/plugins/CDVDiso/src/Linux/Makefile @@ -4,7 +4,7 @@ CC = gcc PLUGIN = libCDVDiso.so CFG = cfgCDVDiso MKISO = mkiso -CFLAGS = -fPIC -Wall -g -I.. -I. -D__LINUX__ -D_FILE_OFFSET_BITS=64 -Wextra +CFLAGS = -fPIC -Wall -g -I.. -I. -D_FILE_OFFSET_BITS=64 -Wextra OBJS = ../CDVDisop.o Config.o Linux.o ../libiso.o CFGOBJS = conf.o interface.o support.o ${OBJS} LIBS = -lz -lbz2 -lstdc++ diff --git a/plugins/CDVDisoEFP/src/Linux/CD.h b/plugins/CDVDisoEFP/src/Linux/CD.h index 31ccd1c0e7..e93cd8fce0 100644 --- a/plugins/CDVDisoEFP/src/Linux/CD.h +++ b/plugins/CDVDisoEFP/src/Linux/CD.h @@ -20,11 +20,6 @@ #ifndef __CD_H__ #define __CD_H__ -#ifndef __LINUX__ -#ifdef __linux__ -#define __LINUX__ -#endif /* __linux__ */ -#endif /* No __LINUX__ */ #define CDVDdefs #include "../PS2Edefs.h" diff --git a/plugins/CDVDisoEFP/src/Linux/CDVDiso.c b/plugins/CDVDisoEFP/src/Linux/CDVDiso.c index 5d5788fdd4..32abc36adf 100644 --- a/plugins/CDVDisoEFP/src/Linux/CDVDiso.c +++ b/plugins/CDVDisoEFP/src/Linux/CDVDiso.c @@ -18,11 +18,6 @@ * PCSX2 members can be contacted through their website at www.pcsx2.net. */ #include // NULL -#ifndef __LINUX__ -#ifdef __linux__ -#define __LINUX__ -#endif /* __linux__ */ -#endif /* No __LINUX__ */ #define CDVDdefs #include "PS2Edefs.h" #include "conf.h" diff --git a/plugins/CDVDisoEFP/src/Linux/DVD.h b/plugins/CDVDisoEFP/src/Linux/DVD.h index 5f31bda40b..7f84240fe0 100644 --- a/plugins/CDVDisoEFP/src/Linux/DVD.h +++ b/plugins/CDVDisoEFP/src/Linux/DVD.h @@ -20,11 +20,6 @@ #ifndef __DVD_H__ #define __DVD_H__ -#ifndef __LINUX__ -#ifdef __linux__ -#define __LINUX__ -#endif /* __linux__ */ -#endif /* No __LINUX__ */ #define CDVDdefs #include "PS2Edefs.h" diff --git a/plugins/CDVDisoEFP/src/Linux/device.h b/plugins/CDVDisoEFP/src/Linux/device.h index eeb634c23b..c6e18f589d 100644 --- a/plugins/CDVDisoEFP/src/Linux/device.h +++ b/plugins/CDVDisoEFP/src/Linux/device.h @@ -21,11 +21,6 @@ #define __DEVICE_H__ #include // time_t -#ifndef __LINUX__ -#ifdef __linux__ -#define __LINUX__ -#endif /* __linux__ */ -#endif /* No __LINUX__ */ #define CDVDdefs #include "../PS2Edefs.h" diff --git a/plugins/CDVDisoEFP/src/Linux/devicebox.c b/plugins/CDVDisoEFP/src/Linux/devicebox.c index 439d9f4dcd..38301945ae 100644 --- a/plugins/CDVDisoEFP/src/Linux/devicebox.c +++ b/plugins/CDVDisoEFP/src/Linux/devicebox.c @@ -41,11 +41,6 @@ #include // gtk_vbox_new() #include // gtk_window_new() -#ifndef __LINUX__ -#ifdef __linux__ -#define __LINUX__ -#endif /* __linux__ */ -#endif /* No __LINUX__ */ #define CDVDdefs #include "PS2Edefs.h" diff --git a/plugins/CDVDisoEFP/src/PS2Edefs.h b/plugins/CDVDisoEFP/src/PS2Edefs.h index ae1ff20c55..a50c36fb79 100644 --- a/plugins/CDVDisoEFP/src/PS2Edefs.h +++ b/plugins/CDVDisoEFP/src/PS2Edefs.h @@ -14,7 +14,7 @@ * Since this is still beta things may change. * OSflags: - __LINUX__ (linux OS) + __linux__ (linux OS) _WIN32 (win32 OS) * common return values (for ie. GSinit): @@ -29,7 +29,7 @@ GetOpenFileName) */ #include "PS2Etypes.h" -#ifdef __LINUX__ +#ifdef __linux__ #define CALLBACK #else #include diff --git a/plugins/CDVDisoEFP/src/PS2Etypes.h b/plugins/CDVDisoEFP/src/PS2Etypes.h index f38b475205..0e9b999aea 100644 --- a/plugins/CDVDisoEFP/src/PS2Etypes.h +++ b/plugins/CDVDisoEFP/src/PS2Etypes.h @@ -5,10 +5,6 @@ #define ARRAYSIZE(x) (sizeof(x)/sizeof((x)[0])) #endif -#if defined (__linux__) // some distributions are lower case -#define __LINUX__ -#endif - // Basic types #if defined(_MSC_VER) typedef __int8 s8; @@ -39,7 +35,7 @@ typedef u64 uptr; #else typedef u32 uptr; #endif -#ifdef __LINUX__ +#ifdef __linux__ typedef union _LARGE_INTEGER { long long QuadPart; diff --git a/plugins/CDVDisoEFP/src/ecma119.c b/plugins/CDVDisoEFP/src/ecma119.c index ea5e50516b..f0f025f713 100644 --- a/plugins/CDVDisoEFP/src/ecma119.c +++ b/plugins/CDVDisoEFP/src/ecma119.c @@ -21,12 +21,6 @@ #include -// #ifndef __LINUX__ -// #ifdef __linux__ -// #define __LINUX__ -// #endif /* __linux__ */ -// #endif /* No __LINUX__ */ - // #define CDVDdefs // #include "PS2Edefs.h" diff --git a/plugins/CDVDisoEFP/src/ecma119.h b/plugins/CDVDisoEFP/src/ecma119.h index 8b1b990b5a..a700e65165 100644 --- a/plugins/CDVDisoEFP/src/ecma119.h +++ b/plugins/CDVDisoEFP/src/ecma119.h @@ -21,12 +21,6 @@ #ifndef ECMA119_H #define ECMA119_H -// #ifndef __LINUX__ -// #ifdef __linux__ -// #define __LINUX__ -// #endif /* __linux__ */ -// #endif /* No __LINUX__ */ - // #define CDVDdefs // #include "PS2Edefs.h" diff --git a/plugins/CDVDisoEFP/src/imagetype.c b/plugins/CDVDisoEFP/src/imagetype.c index 2079fe0732..9aefe4d503 100644 --- a/plugins/CDVDisoEFP/src/imagetype.c +++ b/plugins/CDVDisoEFP/src/imagetype.c @@ -20,11 +20,6 @@ #include // NULL #include // off64_t -// #ifndef __LINUX__ -// #ifdef __linux__ -// #define __LINUX__ -// #endif /* __linux__ */ -// #endif /* No __LINUX__ */ // #define CDVDdefs // #include "PS2Edefs.h" diff --git a/plugins/CDVDisoEFP/src/imagetype.h b/plugins/CDVDisoEFP/src/imagetype.h index daef553b69..69dbcff341 100644 --- a/plugins/CDVDisoEFP/src/imagetype.h +++ b/plugins/CDVDisoEFP/src/imagetype.h @@ -21,12 +21,6 @@ #ifndef IMAGETYPE_H #define IMAGETYPE_H -// #ifndef __LINUX__ -// #ifdef __linux__ -// #define __LINUX__ -// #endif /* __linux__ */ -// #endif /* No __LINUX__ */ - // #define CDVDdefs // #include "PS2Edefs.h" #include "isofile.h" diff --git a/plugins/CDVDisoEFP/src/ini.h b/plugins/CDVDisoEFP/src/ini.h index 9f1baa847d..9adee3921e 100644 --- a/plugins/CDVDisoEFP/src/ini.h +++ b/plugins/CDVDisoEFP/src/ini.h @@ -23,12 +23,6 @@ #define INI_H -// #ifndef __LINUX__ -// #ifdef __linux__ -// #define __LINUX__ -// #endif /* __linux__ */ -// #endif /* No __LINUX__ */ - // #define CDVDdefs // #include "PS2Edefs.h" diff --git a/plugins/CDVDisoEFP/src/isocompress.c b/plugins/CDVDisoEFP/src/isocompress.c index 552a7066f6..ef7fd955f4 100644 --- a/plugins/CDVDisoEFP/src/isocompress.c +++ b/plugins/CDVDisoEFP/src/isocompress.c @@ -20,12 +20,6 @@ #include // NULL -// #ifndef __LINUX__ -// #ifdef __linux__ -// #define __LINUX__ -// #endif /* __linux__ */ -// #endif /* No __LINUX__ */ - // #define CDVDdefs // #include "PS2Edefs.h" #include "logfile.h" diff --git a/plugins/CDVDisoEFP/src/isofile.c b/plugins/CDVDisoEFP/src/isofile.c index 9e745c9b2f..171bba21ac 100644 --- a/plugins/CDVDisoEFP/src/isofile.c +++ b/plugins/CDVDisoEFP/src/isofile.c @@ -22,11 +22,6 @@ #include // malloc() #include // off64_t -#ifndef __LINUX__ -#ifdef __linux__ -#define __LINUX__ -#endif /* __linux__ */ -#endif /* No __LINUX__ */ #define CDVDdefs #include "PS2Edefs.h" diff --git a/plugins/CDVDisoEFP/src/multifile.c b/plugins/CDVDisoEFP/src/multifile.c index bd3eb1c014..58ab76afa4 100644 --- a/plugins/CDVDisoEFP/src/multifile.c +++ b/plugins/CDVDisoEFP/src/multifile.c @@ -20,11 +20,6 @@ #include // NULL #include // off64_t -// #ifndef __LINUX__ -// #ifdef __linux__ -// #define __LINUX__ -// #endif /* __linux__ */ -// #endif /* No __LINUX__ */ // #define CDVDdefs // #include "PS2Edefs.h" diff --git a/plugins/CDVDisoEFP/src/multifile.h b/plugins/CDVDisoEFP/src/multifile.h index 44a44834d2..254ee62890 100644 --- a/plugins/CDVDisoEFP/src/multifile.h +++ b/plugins/CDVDisoEFP/src/multifile.h @@ -21,12 +21,6 @@ #ifndef MULTIFILE_H #define MULTIFILE_H -// #ifndef __LINUX__ -// #ifdef __linux__ -// #define __LINUX__ -// #endif /* __linux__ */ -// #endif /* No __LINUX__ */ - // #define CDVDdefs // #include "PS2Edefs.h" #include "isofile.h" diff --git a/plugins/CDVDisoEFP/src/toc.c b/plugins/CDVDisoEFP/src/toc.c index c8d3bb0790..1d1c1b0fe1 100644 --- a/plugins/CDVDisoEFP/src/toc.c +++ b/plugins/CDVDisoEFP/src/toc.c @@ -19,11 +19,6 @@ */ #include // NULL #include // off64_t -#ifndef __LINUX__ -#ifdef __linux__ -#define __LINUX__ -#endif /* __linux__ */ -#endif /* No __LINUX__ */ #define CDVDdefs #include "PS2Edefs.h" #include "logfile.h" diff --git a/plugins/CDVDisoEFP/src/toc.h b/plugins/CDVDisoEFP/src/toc.h index 16911f2e10..92788865ed 100644 --- a/plugins/CDVDisoEFP/src/toc.h +++ b/plugins/CDVDisoEFP/src/toc.h @@ -20,12 +20,6 @@ #ifndef TOC_H #define TOC_H -// #ifndef __LINUX__ -// #ifdef __linux__ -// #define __LINUX__ -// #endif /* __linux__ */ -// #endif /* No __LINUX__ */ - // #define CDVDdefs // #include "PS2Edefs.h" #include "isofile.h" diff --git a/plugins/CDVDisoEFP/src/version.c b/plugins/CDVDisoEFP/src/version.c index d476012fd8..e3fa9581a9 100644 --- a/plugins/CDVDisoEFP/src/version.c +++ b/plugins/CDVDisoEFP/src/version.c @@ -19,12 +19,6 @@ */ -#ifndef __LINUX__ -#ifdef __linux__ -#define __LINUX__ -#endif /* __linux__ */ -#endif /* No __LINUX__ */ - #define CDVDdefs #include "PS2Edefs.h" diff --git a/plugins/CDVDisoEFP/src/version.h b/plugins/CDVDisoEFP/src/version.h index 99c4249131..6fcd03bb59 100644 --- a/plugins/CDVDisoEFP/src/version.h +++ b/plugins/CDVDisoEFP/src/version.h @@ -21,12 +21,6 @@ #ifndef VERSION_H #define VERSION_H -#ifndef __LINUX__ -#ifdef __linux__ -#define __LINUX__ -#endif /* __linux__ */ -#endif /* No __LINUX__ */ - #define CDVDdefs #include "PS2Edefs.h" diff --git a/plugins/CDVDlinuz/Src/Linux/CD.h b/plugins/CDVDlinuz/Src/Linux/CD.h index 697d230524..167635b7d4 100644 --- a/plugins/CDVDlinuz/Src/Linux/CD.h +++ b/plugins/CDVDlinuz/Src/Linux/CD.h @@ -46,18 +46,6 @@ -#ifndef __LINUX__ - -#ifdef __linux__ - -#define __LINUX__ - -#endif /* __linux__ */ - -#endif /* No __LINUX__ */ - - - #define CDVDdefs #include "../PS2Edefs.h" diff --git a/plugins/CDVDlinuz/Src/Linux/CDVDlinuz.c b/plugins/CDVDlinuz/Src/Linux/CDVDlinuz.c index 1efd0f032b..198470a4b6 100644 --- a/plugins/CDVDlinuz/Src/Linux/CDVDlinuz.c +++ b/plugins/CDVDlinuz/Src/Linux/CDVDlinuz.c @@ -28,12 +28,6 @@ #include // time_t, time(), struct timeval #include // stat() -#ifndef __LINUX__ -#ifdef __linux__ -#define __LINUX__ -#endif /* __linux__ */ -#endif /* No __LINUX__ */ - #define CDVDdefs #include "PS2Edefs.h" // #include "PS2Etypes.h" diff --git a/plugins/CDVDlinuz/Src/Linux/DVD.h b/plugins/CDVDlinuz/Src/Linux/DVD.h index 24e067a0e2..b2d423b2d0 100644 --- a/plugins/CDVDlinuz/Src/Linux/DVD.h +++ b/plugins/CDVDlinuz/Src/Linux/DVD.h @@ -46,18 +46,6 @@ -#ifndef __LINUX__ - -#ifdef __linux__ - -#define __LINUX__ - -#endif /* __linux__ */ - -#endif /* No __LINUX__ */ - - - #define CDVDdefs #include "PS2Edefs.h" diff --git a/plugins/CDVDlinuz/Src/Linux/conf.h b/plugins/CDVDlinuz/Src/Linux/conf.h index 00aed42353..563b015f2e 100644 --- a/plugins/CDVDlinuz/Src/Linux/conf.h +++ b/plugins/CDVDlinuz/Src/Linux/conf.h @@ -46,18 +46,6 @@ -#ifndef __LINUX__ - -#ifdef __linux__ - -#define __LINUX__ - -#endif /* __linux__ */ - -#endif /* No __LINUX__ */ - - - #define CDVDdefs #include "../PS2Edefs.h" diff --git a/plugins/CDVDlinuz/Src/Linux/device.h b/plugins/CDVDlinuz/Src/Linux/device.h index 924d3d4cd3..93bebfb7c0 100644 --- a/plugins/CDVDlinuz/Src/Linux/device.h +++ b/plugins/CDVDlinuz/Src/Linux/device.h @@ -50,16 +50,6 @@ -#ifndef __LINUX__ - -#ifdef __linux__ - -#define __LINUX__ - -#endif /* __linux__ */ - -#endif /* No __LINUX__ */ - #define CDVDdefs #include "../PS2Edefs.h" diff --git a/plugins/CDVDlinuz/Src/PS2Edefs.h b/plugins/CDVDlinuz/Src/PS2Edefs.h index 483d45218a..afb989479a 100644 --- a/plugins/CDVDlinuz/Src/PS2Edefs.h +++ b/plugins/CDVDlinuz/Src/PS2Edefs.h @@ -14,7 +14,7 @@ * Since this is still beta things may change. * OSflags: - __LINUX__ (linux OS) + __linux__ (linux OS) _WIN32 (win32 OS) * common return values (for ie. GSinit): @@ -33,7 +33,7 @@ #include "PS2Etypes.h" -#ifdef __LINUX__ +#ifdef __linux__ #define CALLBACK #else #include diff --git a/plugins/CDVDlinuz/Src/PS2Etypes.h b/plugins/CDVDlinuz/Src/PS2Etypes.h index 4e59015022..e3cfa9e656 100644 --- a/plugins/CDVDlinuz/Src/PS2Etypes.h +++ b/plugins/CDVDlinuz/Src/PS2Etypes.h @@ -42,7 +42,7 @@ typedef u32 uptr; -#elif defined(__LINUX__) || defined(__MINGW32__) +#elif defined(__linux__) || defined(__MINGW32__) diff --git a/plugins/CDVDlinuz/Src/buffer.c b/plugins/CDVDlinuz/Src/buffer.c index a91791f096..7af08f5fe9 100644 --- a/plugins/CDVDlinuz/Src/buffer.c +++ b/plugins/CDVDlinuz/Src/buffer.c @@ -44,18 +44,6 @@ -#ifndef __LINUX__ - -#ifdef __linux__ - -#define __LINUX__ - -#endif /* __linux__ */ - -#endif /* No __LINUX__ */ - - - #define CDVDdefs #include "PS2Edefs.h" diff --git a/plugins/CDVDlinuz/Src/ini.h b/plugins/CDVDlinuz/Src/ini.h index 44fa4744c5..827d0f9480 100644 --- a/plugins/CDVDlinuz/Src/ini.h +++ b/plugins/CDVDlinuz/Src/ini.h @@ -48,18 +48,6 @@ -// #ifndef __LINUX__ - -// #ifdef __linux__ - -// #define __LINUX__ - -// #endif /* __linux__ */ - -// #endif /* No __LINUX__ */ - - - // #define CDVDdefs // #include "PS2Edefs.h" diff --git a/plugins/CDVDlinuz/Src/version.c b/plugins/CDVDlinuz/Src/version.c index 17e1be6d9f..2d9b1914ec 100644 --- a/plugins/CDVDlinuz/Src/version.c +++ b/plugins/CDVDlinuz/Src/version.c @@ -40,18 +40,6 @@ -#ifndef __LINUX__ - -#ifdef __linux__ - -#define __LINUX__ - -#endif /* __linux__ */ - -#endif /* No __LINUX__ */ - - - #define CDVDdefs #include "PS2Edefs.h" diff --git a/plugins/CDVDlinuz/Src/version.h b/plugins/CDVDlinuz/Src/version.h index 9b98b06c20..8c4eb58232 100644 --- a/plugins/CDVDlinuz/Src/version.h +++ b/plugins/CDVDlinuz/Src/version.h @@ -48,18 +48,6 @@ -#ifndef __LINUX__ - -#ifdef __linux__ - -#define __LINUX__ - -#endif /* __linux__ */ - -#endif /* No __LINUX__ */ - - - #define CDVDdefs #include "PS2Edefs.h" diff --git a/plugins/CDVDpeops/CDVDiso.c b/plugins/CDVDpeops/CDVDiso.c index 1553098fe7..b4ea4a013c 100644 --- a/plugins/CDVDpeops/CDVDiso.c +++ b/plugins/CDVDpeops/CDVDiso.c @@ -5,7 +5,7 @@ */ #include -#ifdef __LINUX__ +#ifdef __linux__ #define strnicmp strncasecmp #endif diff --git a/plugins/CDVDpeops/PS2Edefs.h b/plugins/CDVDpeops/PS2Edefs.h index 679f0acf1b..af37627358 100644 --- a/plugins/CDVDpeops/PS2Edefs.h +++ b/plugins/CDVDpeops/PS2Edefs.h @@ -14,7 +14,7 @@ * Since this is still beta things may change. * OSflags: - __LINUX__ (linux OS) + __linux__ (linux OS) __WIN32__ (win32 OS) * common return values (for ie. GSinit): @@ -33,7 +33,7 @@ #include "PS2Etypes.h" -#ifdef __LINUX__ +#ifdef __linux__ #define CALLBACK #else #include diff --git a/plugins/CDVDpeops/PS2Etypes.h b/plugins/CDVDpeops/PS2Etypes.h index 8855e172ce..7e524c7cd2 100644 --- a/plugins/CDVDpeops/PS2Etypes.h +++ b/plugins/CDVDpeops/PS2Etypes.h @@ -20,7 +20,7 @@ typedef u64 uptr; typedef u32 uptr; #endif -#elif defined(__LINUX__) || defined(__MINGW32__) +#elif defined(__linux__) || defined(__MINGW32__) typedef char s8; typedef short s16; diff --git a/plugins/GSnull/GS.cpp b/plugins/GSnull/GS.cpp index 3704bf6b2e..252d38b94c 100644 --- a/plugins/GSnull/GS.cpp +++ b/plugins/GSnull/GS.cpp @@ -46,7 +46,7 @@ const char* s_iniFilename = "GSnull.ini"; GSVars gs; // Because I haven't bothered to get GSOpen2 working in Windows yet in GSNull. -#ifdef __LINUX__ +#ifdef __linux__ #define USE_GSOPEN2 #endif diff --git a/plugins/GSnull/GS.h b/plugins/GSnull/GS.h index e63facdee0..7ee0f269f4 100644 --- a/plugins/GSnull/GS.h +++ b/plugins/GSnull/GS.h @@ -26,7 +26,7 @@ typedef struct _keyEvent keyEvent; # include "Windows/GSwin.h" #endif -#ifdef __LINUX__ +#ifdef __linux__ # include "Linux/GSLinux.h" #endif diff --git a/plugins/cdvdGigaherz/src/FileStream.cpp b/plugins/cdvdGigaherz/src/FileStream.cpp index 26288dfea1..72474c3d40 100644 --- a/plugins/cdvdGigaherz/src/FileStream.cpp +++ b/plugins/cdvdGigaherz/src/FileStream.cpp @@ -36,7 +36,7 @@ void FileStream::seek(s64 offset) void FileStream::seek(s64 offset, int ref_position) { int ret = _fseeki64(handle, offset, ref_position); -#ifdef __LINUX__ +#ifdef __linux__ if (ret) throw "Seek offset out of bounds."; #else if (ret) @@ -76,7 +76,7 @@ int FileStream::read(byte* b, int len) { if (b == NULL) { -#ifdef __LINUX__ +#ifdef __linux__ throw "NULL buffer passed."; #else throw new exception("NULL buffer passed."); @@ -85,7 +85,7 @@ int FileStream::read(byte* b, int len) if (len < 0) { -#ifdef __LINUX__ +#ifdef __linux__ throw "off<0 or len<0."; #else throw new exception("off<0 or len<0."); diff --git a/plugins/dev9ghzdrk/PS2Edefs.h b/plugins/dev9ghzdrk/PS2Edefs.h index cee29beccd..20b2d64136 100644 --- a/plugins/dev9ghzdrk/PS2Edefs.h +++ b/plugins/dev9ghzdrk/PS2Edefs.h @@ -29,7 +29,7 @@ * Since this is still beta things may change. * OSflags: - __LINUX__ (linux OS) + __linux__ (linux OS) __WIN32__ (win32 OS) * common return values (for ie. GSinit): @@ -48,7 +48,7 @@ #include "PS2Etypes.h" -#ifdef __LINUX__ +#ifdef __linux__ #define CALLBACK #else #include diff --git a/plugins/dev9ghzdrk/PS2Etypes.h b/plugins/dev9ghzdrk/PS2Etypes.h index 4ca24e46ed..ffc801e2c1 100644 --- a/plugins/dev9ghzdrk/PS2Etypes.h +++ b/plugins/dev9ghzdrk/PS2Etypes.h @@ -29,7 +29,7 @@ typedef unsigned __int16 u16; typedef unsigned __int32 u32; typedef unsigned __int64 u64; -#elif defined(__LINUX__) +#elif defined(__linux__) typedef char s8; typedef short s16; diff --git a/plugins/onepad/controller.h b/plugins/onepad/controller.h index 168946ba97..1f640dfe1e 100644 --- a/plugins/onepad/controller.h +++ b/plugins/onepad/controller.h @@ -22,7 +22,7 @@ #ifndef __CONTROLLER_H__ #define __CONTROLLER_H__ -#ifdef __LINUX__ +#ifdef __linux__ #define MAX_KEYS 24 #else #define MAX_KEYS 20 diff --git a/plugins/onepad/keyboard.cpp b/plugins/onepad/keyboard.cpp index 4448d29c3f..72ce19f0ae 100644 --- a/plugins/onepad/keyboard.cpp +++ b/plugins/onepad/keyboard.cpp @@ -28,7 +28,7 @@ #include #include "keyboard.h" -#ifndef __LINUX__ +#ifndef __linux__ char* KeysymToChar(int keysym) { LPWORD temp; @@ -40,7 +40,7 @@ char* KeysymToChar(int keysym) void SetAutoRepeat(bool autorep) { - #ifdef __LINUX__ + #ifdef __linux__ if (toggleAutoRepeat) { if (autorep) @@ -51,7 +51,7 @@ void SetAutoRepeat(bool autorep) #endif } -#ifdef __LINUX__ +#ifdef __linux__ static bool s_grab_input = false; static bool s_Shift = false; static unsigned int s_previous_mouse_x = 0; diff --git a/plugins/onepad/keyboard.h b/plugins/onepad/keyboard.h index 9f3eea2253..0b352b6f7b 100644 --- a/plugins/onepad/keyboard.h +++ b/plugins/onepad/keyboard.h @@ -24,7 +24,7 @@ #include "onepad.h" -#ifdef __LINUX__ +#ifdef __linux__ #include "Linux/linux.h" diff --git a/plugins/onepad/onepad.cpp b/plugins/onepad/onepad.cpp index f25cc7dafb..3a1c33ea50 100644 --- a/plugins/onepad/onepad.cpp +++ b/plugins/onepad/onepad.cpp @@ -28,7 +28,7 @@ #include "onepad.h" #include "svnrev.h" -#ifdef __LINUX__ +#ifdef __linux__ #include #endif #ifdef _MSC_VER @@ -260,7 +260,7 @@ EXPORT_C_(s32) PADopen(void *pDsp) pthread_spin_init(&mutex_KeyEvent, PTHREAD_PROCESS_PRIVATE); mutex_WasInit = true; -#ifdef __LINUX__ +#ifdef __linux__ JoystickInfo::EnumerateJoysticks(s_vjoysticks); #endif return _PADopen(pDsp); @@ -602,7 +602,7 @@ EXPORT_C_(keyEvent*) PADkeyEvent() return &s_event; } -#ifdef __LINUX__ +#ifdef __linux__ EXPORT_C_(void) PADWriteEvent(keyEvent &evt) { // This function call be called before PADopen. Therefore we cann't diff --git a/plugins/onepad/onepad.h b/plugins/onepad/onepad.h index 916415bc73..4013763c0d 100644 --- a/plugins/onepad/onepad.h +++ b/plugins/onepad/onepad.h @@ -47,7 +47,7 @@ using namespace std; #define PADdefs #include "PS2Edefs.h" -#ifdef __LINUX__ +#ifdef __linux__ #include "joystick.h" #endif #include "bitwise.h" diff --git a/plugins/spu2-x/src/Config.h b/plugins/spu2-x/src/Config.h index 9a9dc82730..68a8fbe03c 100644 --- a/plugins/spu2-x/src/Config.h +++ b/plugins/spu2-x/src/Config.h @@ -83,7 +83,7 @@ extern u32 OutputModule; extern int SndOutLatencyMS; extern int SynchMode; -#ifndef __LINUX__ +#ifndef __linux__ extern wchar_t dspPlugin[]; extern int dspPluginModule; diff --git a/plugins/spu2-x/src/Global.h b/plugins/spu2-x/src/Global.h index 96aa3dcfae..e08f48544c 100644 --- a/plugins/spu2-x/src/Global.h +++ b/plugins/spu2-x/src/Global.h @@ -39,9 +39,7 @@ namespace soundtouch #include #include -// This will be brought in later anyways, but if we bring it in now, it'll avoid -// warnings about redefining __LINUX__. -#include "Utilities/Dependencies.h" +#include "Utilities/Dependencies.h" #include "Pcsx2Defs.h" #include "Pcsx2Types.h" diff --git a/plugins/spu2-x/src/Mixer.cpp b/plugins/spu2-x/src/Mixer.cpp index 64c47bd44c..ba8ebe2ab1 100644 --- a/plugins/spu2-x/src/Mixer.cpp +++ b/plugins/spu2-x/src/Mixer.cpp @@ -819,7 +819,7 @@ static int p_cachestat_counter=0; // Gcc does not want to inline it when lto is enabled because some functions growth too much. // The function is big enought to see any speed impact. -- Gregory -#ifndef __LINUX__ +#ifndef __linux__ __forceinline #endif void Mix() diff --git a/plugins/spu2-x/src/PS2E-spu2.cpp b/plugins/spu2-x/src/PS2E-spu2.cpp index 93c7e5ad3f..ee7df1e9c6 100644 --- a/plugins/spu2-x/src/PS2E-spu2.cpp +++ b/plugins/spu2-x/src/PS2E-spu2.cpp @@ -446,7 +446,7 @@ EXPORT_C_(s32) SPU2open(void *pDsp) { SndBuffer::Init(); -#ifndef __LINUX__ +#ifndef __linux__ DspLoadLibrary(dspPlugin,dspPluginModule); #endif WaveDump::Open(); @@ -467,7 +467,7 @@ EXPORT_C_(void) SPU2close() FileLog("[%10d] SPU2 Close\n",Cycles); -#ifndef __LINUX__ +#ifndef __linux__ DspCloseLibrary(); #endif diff --git a/plugins/spu2-x/src/PS2E-spu2.h b/plugins/spu2-x/src/PS2E-spu2.h index 4516578714..bfd3b2e879 100644 --- a/plugins/spu2-x/src/PS2E-spu2.h +++ b/plugins/spu2-x/src/PS2E-spu2.h @@ -20,7 +20,7 @@ #include "Pcsx2Defs.h" #include "PS2Edefs.h" -#ifdef __LINUX__ +#ifdef __linux__ //Until I get around to putting in Linux svn code, this is an unknown svn version. #define SVN_REV_UNKNOWN #endif @@ -51,7 +51,7 @@ EXPORT_C_(void) SPU2irqCallback(void (*SPU2callback)()); #else // These defines are useless and gcc-4.6 complain about redefinition // so we remove them on linux -#ifndef __LINUX__ +#ifndef __linux__ EXPORT_C_(void) SPU2readDMA4Mem(u16 *pMem, u32 size); EXPORT_C_(void) SPU2writeDMA4Mem(u16 *pMem, u32 size); EXPORT_C_(void) SPU2interruptDMA4(); diff --git a/plugins/spu2-x/src/SndOut.cpp b/plugins/spu2-x/src/SndOut.cpp index abcf154b7b..b308e1eda9 100644 --- a/plugins/spu2-x/src/SndOut.cpp +++ b/plugins/spu2-x/src/SndOut.cpp @@ -95,7 +95,7 @@ SndOutModule* mods[]= #if defined(SPU2X_SDL) || defined(SPU2X_SDL2) SDLOut, #endif -#ifdef __LINUX__ +#ifdef __linux__ AlsaOut, #endif NULL // signals the end of our list @@ -467,7 +467,7 @@ void SndBuffer::Write( const StereoOut32& Sample ) ssFreeze--; memset( sndTempBuffer, 0, sizeof(StereoOut32) * SndOutPacketSize ); // Play silence } -#ifndef __LINUX__ +#ifndef __linux__ if( dspPluginEnabled ) { // Convert in, send to winamp DSP, and convert out. diff --git a/plugins/spu2-x/src/SndOut.h b/plugins/spu2-x/src/SndOut.h index 454ba942c6..a3a0899fcc 100644 --- a/plugins/spu2-x/src/SndOut.h +++ b/plugins/spu2-x/src/SndOut.h @@ -675,7 +675,7 @@ extern SndOutModule* PortaudioOut; #if defined(SPU2X_SDL) || defined(SPU2X_SDL2) extern SndOutModule * const SDLOut; #endif -#ifdef __LINUX__ +#ifdef __linux__ extern SndOutModule* AlsaOut; #endif diff --git a/plugins/spu2-x/src/SndOut_Portaudio.cpp b/plugins/spu2-x/src/SndOut_Portaudio.cpp index c0fb8f0dbd..bd1bfbbc53 100644 --- a/plugins/spu2-x/src/SndOut_Portaudio.cpp +++ b/plugins/spu2-x/src/SndOut_Portaudio.cpp @@ -578,7 +578,7 @@ public: { wxString api( L"EMPTYEMPTYEMPTY" ); m_Device = L"EMPTYEMPTYEMPTY"; -#ifdef __LINUX__ +#ifdef __linux__ // By default on linux use the ALSA API (+99% users) -- Gregory CfgReadStr( L"PORTAUDIO", L"HostApi", api, L"ALSA" ); #else diff --git a/plugins/spu2-x/src/Wavedump_wav.cpp b/plugins/spu2-x/src/Wavedump_wav.cpp index 62dbaebecc..6875b3aef6 100644 --- a/plugins/spu2-x/src/Wavedump_wav.cpp +++ b/plugins/spu2-x/src/Wavedump_wav.cpp @@ -16,7 +16,7 @@ */ #include "Global.h" -#ifdef __LINUX__ +#ifdef __linux__ #include "WavFile.h" #else #include "soundtouch/WavFile.h" @@ -53,7 +53,7 @@ namespace WaveDump for( int srcidx=0; srcidx #include #include // ftime(), struct timeb diff --git a/plugins/zerospu2/zerospu2.cpp b/plugins/zerospu2/zerospu2.cpp index 265bc1785f..e9b899852f 100644 --- a/plugins/zerospu2/zerospu2.cpp +++ b/plugins/zerospu2/zerospu2.cpp @@ -28,7 +28,7 @@ #include #include "soundtouch/SoundTouch.h" -#ifdef __LINUX__ +#ifdef __linux__ #include "WavFile.h" #else #include "soundtouch/WavFile.h" diff --git a/plugins/zerospu2/zeroworker.cpp b/plugins/zerospu2/zeroworker.cpp index 41a2dfeeb7..3a95164a4e 100644 --- a/plugins/zerospu2/zeroworker.cpp +++ b/plugins/zerospu2/zeroworker.cpp @@ -19,7 +19,7 @@ #include "zerospu2.h" #include "zeroworker.h" #include "soundtouch/SoundTouch.h" -#ifdef __LINUX__ +#ifdef __linux__ #include "WavFile.h" #else #include "soundtouch/WavFile.h" diff --git a/plugins/zzogl-pg-cg/opengl/GSmain.cpp b/plugins/zzogl-pg-cg/opengl/GSmain.cpp index 84097f417c..618a6dab13 100644 --- a/plugins/zzogl-pg-cg/opengl/GSmain.cpp +++ b/plugins/zzogl-pg-cg/opengl/GSmain.cpp @@ -623,7 +623,7 @@ s32 CALLBACK GSfreeze(int mode, freezeData *data) return 0; } -#ifdef __LINUX__ +#ifdef __linux__ struct Packet { diff --git a/plugins/zzogl-pg-cg/opengl/Profile.h b/plugins/zzogl-pg-cg/opengl/Profile.h index b6e17b7af3..9573629a9c 100644 --- a/plugins/zzogl-pg-cg/opengl/Profile.h +++ b/plugins/zzogl-pg-cg/opengl/Profile.h @@ -32,7 +32,7 @@ extern u64 luPerfFreq; // Copied from Utilities; remove later. -#ifdef __LINUX__ +#ifdef __linux__ #include #include // ftime(), struct timeb diff --git a/plugins/zzogl-pg-cg/opengl/ZZLog.h b/plugins/zzogl-pg-cg/opengl/ZZLog.h index 2dbc60b9e4..8028598ad6 100644 --- a/plugins/zzogl-pg-cg/opengl/ZZLog.h +++ b/plugins/zzogl-pg-cg/opengl/ZZLog.h @@ -26,7 +26,7 @@ extern void HandleGLError(); //Logging for errors that are called often should have a time counter. -#ifdef __LINUX__ +#ifdef __linux__ static u32 __attribute__((unused)) lasttime = 0; static u32 __attribute__((unused)) BigTime = 5000; static bool __attribute__((unused)) SPAM_PASS; diff --git a/plugins/zzogl-pg-cg/opengl/targets.cpp b/plugins/zzogl-pg-cg/opengl/targets.cpp index 8b134a72ef..483d524595 100644 --- a/plugins/zzogl-pg-cg/opengl/targets.cpp +++ b/plugins/zzogl-pg-cg/opengl/targets.cpp @@ -2741,7 +2741,7 @@ void FlushTransferRanges(const tex0Info* ptex) #endif -#ifdef __LINUX__ +#ifdef __linux__ //#define LOG_RESOLVE_PROFILE #endif diff --git a/plugins/zzogl-pg/opengl/GSmain.cpp b/plugins/zzogl-pg/opengl/GSmain.cpp index f282c4ca89..2409690560 100644 --- a/plugins/zzogl-pg/opengl/GSmain.cpp +++ b/plugins/zzogl-pg/opengl/GSmain.cpp @@ -641,7 +641,7 @@ EXPORT_C_(s32) GSfreeze(int mode, freezeData *data) return 0; } -#ifdef __LINUX__ +#ifdef __linux__ void _fread(void *ptr, size_t size, size_t nmemb, FILE *stream) { static uint32 read_cnt = 0; diff --git a/plugins/zzogl-pg/opengl/Profile.h b/plugins/zzogl-pg/opengl/Profile.h index 0c621f98ca..5ddf7aa724 100644 --- a/plugins/zzogl-pg/opengl/Profile.h +++ b/plugins/zzogl-pg/opengl/Profile.h @@ -32,7 +32,7 @@ extern u64 luPerfFreq; // Copied from Utilities; remove later. -#ifdef __LINUX__ +#ifdef __linux__ #include #include // ftime(), struct timeb diff --git a/plugins/zzogl-pg/opengl/ZZLog.h b/plugins/zzogl-pg/opengl/ZZLog.h index be5f1eb113..920fba490e 100644 --- a/plugins/zzogl-pg/opengl/ZZLog.h +++ b/plugins/zzogl-pg/opengl/ZZLog.h @@ -26,7 +26,7 @@ extern void HandleGLError(); //Logging for errors that are called often should have a time counter. -#ifdef __LINUX__ +#ifdef __linux__ static u32 __attribute__((unused)) lasttime = 0; static u32 __attribute__((unused)) BigTime = 5000; static bool __attribute__((unused)) SPAM_PASS; diff --git a/plugins/zzogl-pg/opengl/targets.cpp b/plugins/zzogl-pg/opengl/targets.cpp index 8d3dd32f36..0fd10f5571 100644 --- a/plugins/zzogl-pg/opengl/targets.cpp +++ b/plugins/zzogl-pg/opengl/targets.cpp @@ -511,7 +511,7 @@ void FlushTransferRanges(const tex0Info* ptex) #endif -#ifdef __LINUX__ +#ifdef __linux__ //#define LOG_RESOLVE_PROFILE #endif diff --git a/tools/bin2cpp/bin2cpp.cpp b/tools/bin2cpp/bin2cpp.cpp index 8aa2f5b5f4..85c40a10aa 100644 --- a/tools/bin2cpp/bin2cpp.cpp +++ b/tools/bin2cpp/bin2cpp.cpp @@ -36,10 +36,6 @@ #include #include -#if defined (__linux__) && !defined(__LINUX__) // some distributions are lower case -#define __LINUX__ -#endif - #if _MSC_VER # pragma warning(disable:4996) // The POSIX name for this item is deprecated. Instead, use the ISO C++ conformant name. #endif