mirror of
https://github.com/cemu-project/Cemu.git
synced 2025-07-05 22:41:18 +12:00
Initial macOS port bringup (#52)
This commit is contained in:
parent
a2abffd37b
commit
974edaa649
84 changed files with 157 additions and 122 deletions
|
@ -78,7 +78,7 @@ void CafeInit()
|
|||
rpxPathStart = 0;
|
||||
}
|
||||
|
||||
std::string_view rpxFileName = std::basic_string_view<char>(_pathToExecutable.data() + rpxPathStart, _pathToExecutable.data() + _pathToExecutable.size());
|
||||
std::string_view rpxFileName(_pathToExecutable.data() + rpxPathStart, _pathToExecutable.size() - rpxPathStart);
|
||||
|
||||
argStorageIndex = 0;
|
||||
_coreinitInfo->argc = 0;
|
||||
|
|
|
@ -424,7 +424,7 @@ typedef struct
|
|||
|
||||
static_assert(sizeof(UCParamStruct_t) == 0x54); // unsure
|
||||
|
||||
#if BOOST_OS_LINUX
|
||||
#if BOOST_OS_LINUX || BOOST_OS_MACOS
|
||||
#define _strcmpi strcasecmp
|
||||
#endif
|
||||
|
||||
|
|
|
@ -63,7 +63,8 @@ namespace coreinit
|
|||
bool negativeAlignment = alignment < 0;
|
||||
if (negativeAlignment)
|
||||
alignment = -alignment;
|
||||
if (!std::has_single_bit<uint32>((uint32)alignment))
|
||||
uint32 bits = (uint32)alignment;
|
||||
if (bits == 0 || (bits & (bits - 1)) != 0)
|
||||
{
|
||||
cemuLog_log(LogType::APIErrors, "MEMGetAllocatableSizeForFrmHeapEx(): Invalid alignment");
|
||||
return 0;
|
||||
|
|
|
@ -455,7 +455,7 @@ void export_curl_multi_fdset(PPCInterpreter_t* hCPU)
|
|||
ppcDefineParamMEMPTR(exceptionFd, wu_fd_set, 3);
|
||||
ppcDefineParamU32BEPtr(maxFd, 4);
|
||||
|
||||
#if BOOST_OS_LINUX > 0
|
||||
#if BOOST_OS_LINUX || BOOST_OS_MACOS
|
||||
cemuLog_log(LogType::Force, "curl_multi_fdset(...) - todo");
|
||||
|
||||
osLib_returnFromFunction(hCPU, 0);
|
||||
|
|
|
@ -242,7 +242,7 @@ namespace save
|
|||
}
|
||||
catch (const std::exception& ex)
|
||||
{
|
||||
#if BOOST_OS_WINDOWS > 0
|
||||
#if BOOST_OS_WINDOWS
|
||||
std::wstringstream errorMsg;
|
||||
errorMsg << L"Couldn't move your save files!" << std::endl << std::endl;
|
||||
errorMsg << L"Error: " << ex.what() << std::endl << std::endl;
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
#include <bitset>
|
||||
#include "nsyshid.h"
|
||||
|
||||
#if BOOST_OS_WINDOWS > 0
|
||||
#if BOOST_OS_WINDOWS
|
||||
|
||||
#include <setupapi.h>
|
||||
#include <initguid.h>
|
||||
|
|
|
@ -6,7 +6,7 @@
|
|||
|
||||
#include "Common/socket.h"
|
||||
|
||||
#if BOOST_OS_WINDOWS > 0
|
||||
#if BOOST_OS_WINDOWS
|
||||
|
||||
#define WU_AF_INET 2
|
||||
|
||||
|
@ -2085,7 +2085,7 @@ void nsysnet_load()
|
|||
osLib_addFunction("nsysnet", "NSSLExportInternalClientCertificate", nsysnet::export_NSSLExportInternalClientCertificate);
|
||||
}
|
||||
|
||||
#if BOOST_OS_LINUX
|
||||
#if BOOST_OS_LINUX || BOOST_OS_MACOS
|
||||
void nsysnet_notifyCloseSharedSocket(SOCKET existingSocket)
|
||||
{
|
||||
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
#include <set>
|
||||
#include <vector>
|
||||
|
||||
#if BOOST_OS_WINDOWS > 0
|
||||
#if BOOST_OS_WINDOWS
|
||||
#include <WinSock2.h>
|
||||
#else
|
||||
#include <sys/socket.h>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue