mirror of https://github.com/PCSX2/pcsx2.git
pcsx2:freebsd: Fix build
This commit is contained in:
parent
5f6658ae9a
commit
e10ed744bc
|
@ -20,7 +20,7 @@
|
||||||
# undef Yield
|
# undef Yield
|
||||||
#elif defined(__linux__)
|
#elif defined(__linux__)
|
||||||
# include <libaio.h>
|
# include <libaio.h>
|
||||||
#elif defined(__APPLE__)
|
#elif defined(__POSIX__)
|
||||||
# include <aio.h>
|
# include <aio.h>
|
||||||
#endif
|
#endif
|
||||||
#include <memory>
|
#include <memory>
|
||||||
|
|
|
@ -397,6 +397,12 @@ set(pcsx2OSXSources
|
||||||
Darwin/DarwinFlatFileReader.cpp
|
Darwin/DarwinFlatFileReader.cpp
|
||||||
)
|
)
|
||||||
|
|
||||||
|
set(pcsx2FreeBSDSources
|
||||||
|
Linux/LnxConsolePipe.cpp
|
||||||
|
Linux/LnxKeyCodes.cpp
|
||||||
|
Darwin/DarwinFlatFileReader.cpp
|
||||||
|
)
|
||||||
|
|
||||||
# Linux headers
|
# Linux headers
|
||||||
set(pcsx2LinuxHeaders
|
set(pcsx2LinuxHeaders
|
||||||
)
|
)
|
||||||
|
@ -615,6 +621,12 @@ if(APPLE)
|
||||||
${pcsx2LinuxHeaders})
|
${pcsx2LinuxHeaders})
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
|
if(${CMAKE_SYSTEM_NAME} MATCHES "FreeBSD")
|
||||||
|
set(Platform
|
||||||
|
${pcsx2FreeBSDSources}
|
||||||
|
${pcsx2LinuxHeaders})
|
||||||
|
endif()
|
||||||
|
|
||||||
set(pcsx2FinalSources
|
set(pcsx2FinalSources
|
||||||
${Common}
|
${Common}
|
||||||
${Platform}
|
${Platform}
|
||||||
|
|
|
@ -58,13 +58,13 @@ void yuv2rgb_reference(void)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#if defined(_M_X86_32)
|
||||||
// TODO OSX optimize me
|
// TODO OSX optimize me
|
||||||
#ifdef __APPLE__
|
#if defined(__clang__) && !defined(__linux__)
|
||||||
void yuv2rgb_sse2() {
|
void yuv2rgb_sse2() {
|
||||||
yuv2rgb_reference();
|
yuv2rgb_reference();
|
||||||
}
|
}
|
||||||
|
#else
|
||||||
#elif defined(_M_X86_32)
|
|
||||||
// Everything below is bit accurate to the IPU specification (except maybe rounding).
|
// Everything below is bit accurate to the IPU specification (except maybe rounding).
|
||||||
// Know the specification before you touch it.
|
// Know the specification before you touch it.
|
||||||
#define SSE_BYTES(x) {x, x, x, x, x, x, x, x, x, x, x, x, x, x, x, x}
|
#define SSE_BYTES(x) {x, x, x, x, x, x, x, x, x, x, x, x, x, x, x, x}
|
||||||
|
@ -411,3 +411,4 @@ ihatemsvc:
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
#endif
|
||||||
|
|
|
@ -96,13 +96,7 @@ typedef FnType_Void* Fnptr_Void;
|
||||||
|
|
||||||
#else // must be GCC or Clang
|
#else // must be GCC or Clang
|
||||||
|
|
||||||
# include <sys/types.h>
|
#include <sys/types.h>
|
||||||
# include <sys/timeb.h>
|
|
||||||
|
|
||||||
// Definitions added Feb 16, 2006 by efp
|
|
||||||
# ifndef __declspec
|
|
||||||
# define __declspec(x)
|
|
||||||
# endif
|
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
|
@ -1017,11 +1017,11 @@ void Pcsx2App::ProgramLog_PostEvent( wxEvent& evt )
|
||||||
|
|
||||||
static void __concall ConsoleToFile_Newline()
|
static void __concall ConsoleToFile_Newline()
|
||||||
{
|
{
|
||||||
#ifdef __linux__
|
#if defined(__unix__)
|
||||||
if ((g_Conf) && (g_Conf->EmuOptions.ConsoleToStdio)) ConsoleWriter_Stdout.Newline();
|
if ((g_Conf) && (g_Conf->EmuOptions.ConsoleToStdio)) ConsoleWriter_Stdout.Newline();
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef __linux__
|
#if defined(__unix__)
|
||||||
fputc( '\n', emuLog );
|
fputc( '\n', emuLog );
|
||||||
#else
|
#else
|
||||||
fputs( "\r\n", emuLog );
|
fputs( "\r\n", emuLog );
|
||||||
|
@ -1030,7 +1030,7 @@ static void __concall ConsoleToFile_Newline()
|
||||||
|
|
||||||
static void __concall ConsoleToFile_DoWrite( const wxString& fmt )
|
static void __concall ConsoleToFile_DoWrite( const wxString& fmt )
|
||||||
{
|
{
|
||||||
#ifdef __linux__
|
#if defined(__unix__)
|
||||||
if ((g_Conf) && (g_Conf->EmuOptions.ConsoleToStdio)) ConsoleWriter_Stdout.WriteRaw(fmt);
|
if ((g_Conf) && (g_Conf->EmuOptions.ConsoleToStdio)) ConsoleWriter_Stdout.WriteRaw(fmt);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
|
@ -222,7 +222,7 @@ void GSPanel::OnMouseEvent( wxMouseEvent& evt )
|
||||||
DoShowMouse();
|
DoShowMouse();
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifdef __linux__
|
#if defined(__unix__)
|
||||||
// HACK2: In gsopen2 there is one event buffer read by both wx/gui and pad plugin. Wx deletes
|
// 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.
|
// the event before the pad see it. So you send key event directly to the pad.
|
||||||
if( (PADWriteEvent != NULL) && (GSopen2 != NULL) ) {
|
if( (PADWriteEvent != NULL) && (GSopen2 != NULL) ) {
|
||||||
|
@ -285,7 +285,7 @@ void GSPanel::OnKeyDownOrUp( wxKeyEvent& evt )
|
||||||
// to the APP level message handler, which in turn routes them right back here -- yes it's
|
// to the APP level message handler, which in turn routes them right back here -- yes it's
|
||||||
// silly, but oh well).
|
// silly, but oh well).
|
||||||
|
|
||||||
#ifdef __linux__
|
#if defined(__unix__)
|
||||||
// HACK2: In gsopen2 there is one event buffer read by both wx/gui and pad plugin. Wx deletes
|
// 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.
|
// the event before the pad see it. So you send key event directly to the pad.
|
||||||
if( (PADWriteEvent != NULL) && (GSopen2 != NULL) ) {
|
if( (PADWriteEvent != NULL) && (GSopen2 != NULL) ) {
|
||||||
|
@ -367,7 +367,7 @@ void GSPanel::OnFocus( wxFocusEvent& evt )
|
||||||
else
|
else
|
||||||
DoShowMouse();
|
DoShowMouse();
|
||||||
|
|
||||||
#ifdef __linux__
|
#if defined(__unix__)
|
||||||
// HACK2: In gsopen2 there is one event buffer read by both wx/gui and pad plugin. Wx deletes
|
// 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.
|
// the event before the pad see it. So you send key event directly to the pad.
|
||||||
if( (PADWriteEvent != NULL) && (GSopen2 != NULL) ) {
|
if( (PADWriteEvent != NULL) && (GSopen2 != NULL) ) {
|
||||||
|
@ -385,7 +385,7 @@ void GSPanel::OnFocusLost( wxFocusEvent& evt )
|
||||||
evt.Skip();
|
evt.Skip();
|
||||||
m_HasFocus = false;
|
m_HasFocus = false;
|
||||||
DoShowMouse();
|
DoShowMouse();
|
||||||
#ifdef __linux__
|
#if defined(__unix__)
|
||||||
// HACK2: In gsopen2 there is one event buffer read by both wx/gui and pad plugin. Wx deletes
|
// 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.
|
// the event before the pad see it. So you send key event directly to the pad.
|
||||||
if( (PADWriteEvent != NULL) && (GSopen2 != NULL) ) {
|
if( (PADWriteEvent != NULL) && (GSopen2 != NULL) ) {
|
||||||
|
|
|
@ -503,7 +503,7 @@ MainEmuFrame::MainEmuFrame(wxWindow* parent, const wxString& title)
|
||||||
// ------------------------------------------------------------------------
|
// ------------------------------------------------------------------------
|
||||||
|
|
||||||
m_menuMisc.Append( &m_MenuItem_Console );
|
m_menuMisc.Append( &m_MenuItem_Console );
|
||||||
#ifdef __linux__
|
#if defined(__unix__)
|
||||||
m_menuMisc.Append( &m_MenuItem_Console_Stdio );
|
m_menuMisc.Append( &m_MenuItem_Console_Stdio );
|
||||||
#endif
|
#endif
|
||||||
//Todo: Though not many people need this one :p
|
//Todo: Though not many people need this one :p
|
||||||
|
@ -695,7 +695,7 @@ void MainEmuFrame::ApplyConfigToGui(AppConfig& configToApply, int flags)
|
||||||
menubar.Check( MenuId_EnableCheats, configToApply.EmuOptions.EnableCheats );
|
menubar.Check( MenuId_EnableCheats, configToApply.EmuOptions.EnableCheats );
|
||||||
menubar.Check( MenuId_EnableWideScreenPatches, configToApply.EmuOptions.EnableWideScreenPatches );
|
menubar.Check( MenuId_EnableWideScreenPatches, configToApply.EmuOptions.EnableWideScreenPatches );
|
||||||
menubar.Check( MenuId_EnableHostFs, configToApply.EmuOptions.HostFs );
|
menubar.Check( MenuId_EnableHostFs, configToApply.EmuOptions.HostFs );
|
||||||
#ifdef __linux__
|
#if defined(__unix__)
|
||||||
menubar.Check( MenuId_Console_Stdio, configToApply.EmuOptions.ConsoleToStdio );
|
menubar.Check( MenuId_Console_Stdio, configToApply.EmuOptions.ConsoleToStdio );
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
|
@ -362,7 +362,7 @@ void i18n_SetLanguagePath()
|
||||||
// default location for windows
|
// default location for windows
|
||||||
wxLocale::AddCatalogLookupPathPrefix( wxGetCwd() );
|
wxLocale::AddCatalogLookupPathPrefix( wxGetCwd() );
|
||||||
// additional location for linux
|
// additional location for linux
|
||||||
#ifdef __linux__
|
#ifdef __unix__
|
||||||
wxLocale::AddCatalogLookupPathPrefix( PathDefs::GetLangs().ToString() );
|
wxLocale::AddCatalogLookupPathPrefix( PathDefs::GetLangs().ToString() );
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue