1
0
mirror of https://github.com/libretro/RetroArch synced 2024-07-08 12:15:49 +00:00

Add CDVDFS support back

This commit is contained in:
Francisco Javier Trujillo Mata 2020-04-29 20:16:21 +02:00
parent 45896eb26e
commit 06606407f4
5 changed files with 21 additions and 11 deletions

3
.gitignore vendored
View File

@ -174,7 +174,8 @@ retroarch_switch.nso
# PS2
ps2/irx/*.c
ps2/libcdvd/lib/
*.irx
ps2/libcdfs/lib/
# Wayland
gfx/common/wayland/idle-inhibit-unstable-v1.c

View File

@ -1,4 +1,4 @@
BUILD_FOR_PCSX2 = 0
BUILD_FOR_PCSX2 = 1
DEBUG = 0
HAVE_KERNEL_PRX = 0
HAVE_LOGGER = 0
@ -11,7 +11,6 @@ PS2_IP = 192.168.1.150
TARGET = retroarchps2.elf
TARGET_RELEASE = retroarchps2-release.elf
# Compile the IRXs first
IRX_DIR = ps2/irx
IRX_FILES = $(wildcard ps2/irx/*.c)
@ -29,18 +28,17 @@ ifeq ($(MUTE_WARNINGS), 1)
endif
INCDIR = -I$(PS2DEV)/gsKit/include -I$(PS2SDK)/ports/include
INCDIR += -Ips2 -Ips2/include -Ilibretro-common/include -Ideps -Ideps/stb -Ideps/7zip
INCDIR += -Ips2/include -Ilibretro-common/include -Ideps -Ideps/stb -Ideps/7zip
INCDIR += -Ideps/pthreads -Ideps/pthreads/platform/ps2 -Ideps/pthreads/platform/helper
GPVAL = -G0
CFLAGS = $(OPTIMIZE_LV) $(DISABLE_WARNINGS) -ffast-math -fsingle-precision-constant
ASFLAGS = $(CFLAGS)
RARCH_DEFINES += -DPS2 -DUSE_IOP_CTYPE_MACRO -D_MIPS_ARCH_R5900 -DHAVE_ZLIB -DHAVE_NO_BUILTINZLIB -DHAVE_RPNG -DHAVE_RJPEG
RARCH_DEFINES += -DHAVE_GRIFFIN=1 -DRARCH_INTERNAL -DRARCH_CONSOLE -DHAVE_MENU -DHAVE_CONFIGFILE -DHAVE_RGUI -DHAVE_FILTERS_BUILTIN -DHAVE_7ZIP -DHAVE_CC_RESAMPLER
RARCH_DEFINES += -DPS2 -DHAVE_GRIFFIN=1 -DRARCH_INTERNAL -DRARCH_CONSOLE -DHAVE_MENU -DHAVE_CONFIGFILE -DHAVE_RGUI
RARCH_DEFINES += -DHAVE_ZLIB -DHAVE_NO_BUILTINZLIB -DHAVE_RPNG -DHAVE_RJPEG -DHAVE_FILTERS_BUILTIN -DHAVE_7ZIP -DHAVE_CC_RESAMPLER
LIBDIR =
LDFLAGS += -L$(PS2SDK)/ports/lib -L$(PS2DEV)/gsKit/lib -L$(PS2SDK)/ee/lib -L.
LIBS += -lretro_ps2 -lgskit -ldmakit -lgskit_toolkit -laudsrv -lpadx -lmtap -lmc -lhdd -lsdl -lfileXio -lz
LDFLAGS += -L$(PS2DEV)/gsKit/lib -L$(PS2SDK)/ports/lib -L.
LIBS += -lretro_ps2 -lgskit -ldmakit -lgskit_toolkit -laudsrv -lpadx -lmtap -lmc -lhdd -lfileXio -lz
LIBS += -lpatches -lpoweroff
ifeq ($(BUILD_FOR_PCSX2), 1)
@ -69,6 +67,7 @@ CFLAGS += $(RARCH_DEFINES)
EE_OBJS += $(IRX_DIR)/freemtap_irx.o $(IRX_DIR)/freepad_irx.o $(IRX_DIR)/freesio2_irx.o $(IRX_DIR)/iomanX_irx.o
EE_OBJS += $(IRX_DIR)/fileXio_irx.o $(IRX_DIR)/mcman_irx.o $(IRX_DIR)/mcserv_irx.o $(IRX_DIR)/usbd_irx.o
EE_OBJS += $(IRX_DIR)/usbhdfsd_irx.o $(IRX_DIR)/freesd_irx.o $(IRX_DIR)/audsrv_irx.o $(IRX_DIR)/poweroff_irx.o
EE_OBJS += $(IRX_DIR)/cdfs_irx.o
# Missing objecst on the PS2SDK
EE_OBJS += ps2/compat_files/ps2_devices.o

View File

@ -39,9 +39,13 @@ static void create_path_names(void)
char cwd[FILENAME_MAX];
int bootDeviceID;
#if defined(BUILD_FOR_PCSX2)
strlcpy(cwd, rootDevicePath(BOOT_DEVICE_MC0), sizeof(cwd));
#else
getcwd(cwd, sizeof(cwd));
bootDeviceID=getBootDeviceID(cwd);
strlcpy(cwd, rootDevicePath(bootDeviceID), sizeof(cwd));
#endif
strcat(cwd, "RETROARCH");
strlcpy(eboot_path, cwd, sizeof(eboot_path));
@ -181,6 +185,9 @@ static void frontend_ps2_init(void *data)
SifExecModuleBuffer(&freesd_irx, size_freesd_irx, 0, NULL, NULL);
SifExecModuleBuffer(&audsrv_irx, size_audsrv_irx, 0, NULL, NULL);
/* CDVD */
SifExecModuleBuffer(&cdfs_irx, size_cdfs_irx, 0, NULL, NULL);
if (mcInit(MC_TYPE_XMC)) {
RARCH_ERR("mcInit library not initalizated\n");
}

View File

@ -57,6 +57,9 @@ extern unsigned int size_usbd_irx;
extern unsigned char usbhdfsd_irx;
extern unsigned int size_usbhdfsd_irx;
extern unsigned char cdfs_irx;
extern unsigned int size_cdfs_irx;
extern unsigned char audsrv_irx;
extern unsigned int size_audsrv_irx;

View File

@ -5,8 +5,8 @@ IRX_DIR = $(PS2SDK)/iop/irx
#IRX modules
# IRX modules - modules have to be in IRX_DIR
IRX_FILES += freemtap.irx freepad.irx freesio2.irx iomanX.irx fileXio.irx mcman.irx mcserv.irx usbd.irx usbhdfsd.irx
IRX_FILES += freesd.irx audsrv.irx poweroff.irx
IRX_C_FILES = $(IRX_FILES:.irx=_irx.c)
IRX_FILES += freesd.irx audsrv.irx poweroff.irx cdfs.irx
IRX_C_FILES = $(IRX_FILES:.irx=_irx.c)
all: irxs