cdrom: minor tweak from pcercuei master github/master
authornotaz <notasas@gmail.com>
Sun, 23 Nov 2025 23:55:44 +0000 (01:55 +0200)
committernotaz <notasas@gmail.com>
Sun, 23 Nov 2025 23:56:47 +0000 (01:56 +0200)
https://github.com/notaz/pcsx_rearmed/pull/390#issuecomment-3568471649

libpcsxcore/cdrom-async.c

index ec5c854..9df3115 100644 (file)
@@ -89,7 +89,9 @@ static int c11_threads_cb_wrapper(void *cb)
 #include "../frontend/libretro-rthreads.h"
 #endif
 
+#ifdef HAVE_LIBRETRO
 #include "retro_timers.h"
+#endif
 
 struct cached_buf {
    u32 lba;
@@ -151,8 +153,10 @@ static void lbacache_do(u32 lba)
          memcpy(acdrom.buf_cache[i].buf_sub, buf_sub, sizeof(buf_sub));
    }
    slock_unlock(acdrom.buf_lock);
+#ifdef HAVE_LIBRETRO
    if (g_cd_handle)
       retro_sleep(0); // why does the main thread stall without this?
+#endif
 }
 
 static int lbacache_get(unsigned int lba, void *buf, void *sub_buf)