// Linux 替身:dispatch/dispatch.h —— 实际定义见 compat_linux.h(-include 强制先含) // Linux stand-in: dispatch/dispatch.h -- the actual definitions are in compat_linux.h (force-included with -include) #pragma once #include // 只实现计数信号量(hle_audio 用);队列 / 定时 / 信号源在源码里按 __APPLE__ 分支 // Only the counting semaphore is implemented (used by hle_audio); queues / timers / signal sources branch on __APPLE__ in the sources typedef struct dm_dsema *dispatch_semaphore_t; typedef uint64_t dispatch_time_t; #define DISPATCH_TIME_NOW 0ull #define DISPATCH_TIME_FOREVER (~0ull) dispatch_semaphore_t dispatch_semaphore_create(long value); long dispatch_semaphore_signal(dispatch_semaphore_t s); long dispatch_semaphore_wait(dispatch_semaphore_t s, dispatch_time_t timeout); void dispatch_release(void *obj);