core: Fix windows build
This commit is contained in:
parent
8a093aed63
commit
a561c58edc
|
@ -327,7 +327,6 @@ s32 PS4_SYSV_ABI sceVideoOutUnregisterBuffers(s32 handle, s32 attributeIndex) {
|
||||||
}
|
}
|
||||||
|
|
||||||
void videoOutRegisterLib(Core::Loader::SymbolsResolver* sym) {
|
void videoOutRegisterLib(Core::Loader::SymbolsResolver* sym) {
|
||||||
using namespace Core;
|
|
||||||
LIB_FUNCTION("SbU3dwp80lQ", "libSceVideoOut", 1, "libSceVideoOut", 0, 0,
|
LIB_FUNCTION("SbU3dwp80lQ", "libSceVideoOut", 1, "libSceVideoOut", 0, 0,
|
||||||
sceVideoOutGetFlipStatus);
|
sceVideoOutGetFlipStatus);
|
||||||
LIB_FUNCTION("U46NwOiJpys", "libSceVideoOut", 1, "libSceVideoOut", 0, 0, sceVideoOutSubmitFlip);
|
LIB_FUNCTION("U46NwOiJpys", "libSceVideoOut", 1, "libSceVideoOut", 0, 0, sceVideoOutSubmitFlip);
|
||||||
|
|
|
@ -8,11 +8,11 @@ namespace Core::FileSys {
|
||||||
|
|
||||||
constexpr int RESERVED_HANDLES = 3; // First 3 handles are stdin,stdout,stderr
|
constexpr int RESERVED_HANDLES = 3; // First 3 handles are stdin,stdout,stderr
|
||||||
|
|
||||||
void MntPoints::Mount(const std::string& host_folder, const std::string& guest_folder) {
|
void MntPoints::Mount(const std::filesystem::path& host_folder, const std::string& guest_folder) {
|
||||||
std::scoped_lock lock{m_mutex};
|
std::scoped_lock lock{m_mutex};
|
||||||
|
|
||||||
MntPair pair;
|
MntPair pair;
|
||||||
pair.host_path = host_folder;
|
pair.host_path = host_folder.string();
|
||||||
pair.guest_path = guest_folder;
|
pair.guest_path = guest_folder;
|
||||||
|
|
||||||
m_mnt_pairs.push_back(pair);
|
m_mnt_pairs.push_back(pair);
|
||||||
|
|
|
@ -21,7 +21,7 @@ public:
|
||||||
MntPoints() = default;
|
MntPoints() = default;
|
||||||
virtual ~MntPoints() = default;
|
virtual ~MntPoints() = default;
|
||||||
|
|
||||||
void Mount(const std::string& host_folder, const std::string& guest_folder);
|
void Mount(const std::filesystem::path& host_folder, const std::string& guest_folder);
|
||||||
void Unmount(const std::string& path);
|
void Unmount(const std::string& path);
|
||||||
void UnmountAll();
|
void UnmountAll();
|
||||||
std::string GetHostDirectory(const std::string& guest_directory);
|
std::string GetHostDirectory(const std::string& guest_directory);
|
||||||
|
|
|
@ -178,7 +178,7 @@ static std::string_view GetMachine(e_machine_es machine) {
|
||||||
|
|
||||||
Elf::~Elf() = default;
|
Elf::~Elf() = default;
|
||||||
|
|
||||||
void Elf::Open(const std::string& file_name) {
|
void Elf::Open(const std::filesystem::path& file_name) {
|
||||||
m_f.Open(file_name, FileAccessMode::Read);
|
m_f.Open(file_name, FileAccessMode::Read);
|
||||||
if (!m_f.ReadObject(m_self)) {
|
if (!m_f.ReadObject(m_self)) {
|
||||||
LOG_ERROR(Loader, "Unable to read self header!");
|
LOG_ERROR(Loader, "Unable to read self header!");
|
||||||
|
|
|
@ -457,7 +457,7 @@ public:
|
||||||
Elf() = default;
|
Elf() = default;
|
||||||
~Elf();
|
~Elf();
|
||||||
|
|
||||||
void Open(const std::string& file_name);
|
void Open(const std::filesystem::path& file_name);
|
||||||
bool IsSelfFile() const;
|
bool IsSelfFile() const;
|
||||||
bool IsElfFile() const;
|
bool IsElfFile() const;
|
||||||
void DebugDump();
|
void DebugDump();
|
||||||
|
|
|
@ -5,6 +5,10 @@
|
||||||
#include "common/types.h"
|
#include "common/types.h"
|
||||||
#include "core/tls.h"
|
#include "core/tls.h"
|
||||||
|
|
||||||
|
#ifdef _WIN32
|
||||||
|
#include <windows.h>
|
||||||
|
#endif
|
||||||
|
|
||||||
namespace Core {
|
namespace Core {
|
||||||
|
|
||||||
thread_local u8 TLS[1024];
|
thread_local u8 TLS[1024];
|
||||||
|
@ -124,7 +128,6 @@ static LONG WINAPI ExceptionHandler(PEXCEPTION_POINTERS pExp) noexcept {
|
||||||
default:
|
default:
|
||||||
return EXCEPTION_CONTINUE_SEARCH;
|
return EXCEPTION_CONTINUE_SEARCH;
|
||||||
}
|
}
|
||||||
Flush();
|
|
||||||
return EXCEPTION_CONTINUE_SEARCH;
|
return EXCEPTION_CONTINUE_SEARCH;
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
|
@ -43,7 +43,7 @@ int main(int argc, char* argv[]) {
|
||||||
|
|
||||||
auto* mnt = Common::Singleton<Core::FileSys::MntPoints>::Instance();
|
auto* mnt = Common::Singleton<Core::FileSys::MntPoints>::Instance();
|
||||||
std::filesystem::path p = std::string(path);
|
std::filesystem::path p = std::string(path);
|
||||||
mnt->Mount(config_dir / "app0", "/app0");
|
mnt->Mount(p.parent_path(), "/app0");
|
||||||
|
|
||||||
auto linker = Common::Singleton<Core::Linker>::Instance();
|
auto linker = Common::Singleton<Core::Linker>::Instance();
|
||||||
Core::Libraries::InitHLELibs(&linker->getHLESymbols());
|
Core::Libraries::InitHLELibs(&linker->getHLESymbols());
|
||||||
|
|
Loading…
Reference in New Issue