Add initial macOS support.

This commit is contained in:
squidbus
2024-07-09 02:18:34 -07:00
committed by TheTurtle
parent 36d528743a
commit 66fa29059c
29 changed files with 523 additions and 26 deletions

View File

@@ -12,7 +12,10 @@ int PS4_SYSV_ABI scePthreadKeyCreate(OrbisPthreadKey* key, PthreadKeyDestructor
return ORBIS_KERNEL_ERROR_EINVAL;
}
int result = pthread_key_create(key, nullptr);
pthread_key_t thread_key;
int result = pthread_key_create(&thread_key, nullptr);
*key = static_cast<OrbisPthreadKey>(thread_key);
if (destructor) {
auto thread = scePthreadSelf();
thread->key_destructors.emplace_back(*key, destructor);