mirror of
https://github.com/WinampDesktop/winamp.git
synced 2025-06-21 07:25:39 -04:00
Build: Add Mac dependencies and fix packaging
This commit is contained in:
@ -30,6 +30,7 @@
|
||||
#include <mach/mach_time.h>
|
||||
#include <mach/semaphore.h>
|
||||
#include <mach/task.h>
|
||||
#else
|
||||
#include <pthread_np.h>
|
||||
#endif
|
||||
#endif
|
||||
@ -382,7 +383,7 @@ void* Threading::Thread::ThreadProc(void* param)
|
||||
|
||||
bool Threading::Thread::Start(EntryPoint func)
|
||||
{
|
||||
pxAssertRel(!m_native_handle, "Can't start an already-started thread");
|
||||
AssertMsg(!m_native_handle, "Can't start an already-started thread");
|
||||
|
||||
std::unique_ptr<EntryPoint> func_clone(std::make_unique<EntryPoint>(std::move(func)));
|
||||
|
||||
@ -550,6 +551,8 @@ void Threading::SetNameOfCurrentThread(const char* name)
|
||||
// Extract of manpage: "The name can be up to 16 bytes long, and should be
|
||||
// null-terminated if it contains fewer bytes."
|
||||
prctl(PR_SET_NAME, name, 0, 0, 0);
|
||||
#elif defined(__APPLE__)
|
||||
pthread_setname_np(name);
|
||||
#else
|
||||
pthread_set_name_np(pthread_self(), name);
|
||||
#endif
|
||||
|
Reference in New Issue
Block a user