File tree Expand file tree Collapse file tree 1 file changed +19
-2
lines changed
Expand file tree Collapse file tree 1 file changed +19
-2
lines changed Original file line number Diff line number Diff line change @@ -618,12 +618,29 @@ else ifeq ($(platform), miyoo)
618618# Emscripten
619619else ifeq ($(platform), emscripten)
620620 TARGET := $(TARGET_NAME)_libretro_$(platform).bc
621+ pthread ?= 0
621622 fpic := -fPIC
622623 NO_MMAP = 1
624+ # we can use -lz for emscripten's built-in zlib port
625+ WANT_ZLIB=0
623626 CFLAGS += -DNO_DYLIB -DNO_SOCKET
624627 CFLAGS += -msimd128 -ftree-vectorize
625- LIBPTHREAD :=
626- NO_PTHREAD=1
628+ # when compiling with pthreads...
629+ ifneq ($(pthread), 0)
630+ # use -lpthread
631+ LIBPTHREAD := -lpthread
632+ NO_PTHREAD=0
633+ # but we don't want to include libretro-common's rthread object files here
634+ USE_RTHREADS=0
635+ USE_ASYNC_CDROM=0
636+ # so we disable some uses of threads within pcsx_rearmed.
637+ # is this a good solution? I don't know!
638+ else
639+ LIBPTHREAD :=
640+ USE_RTHREADS=0
641+ USE_ASYNC_CDROM=0
642+ NO_PTHREAD=1
643+ endif
627644 DYNAREC =
628645 STATIC_LINKING = 1
629646 HAVE_PHYSICAL_CDROM = 0
You can’t perform that action at this time.
0 commit comments