mirror of https://github.com/mgba-emu/mgba.git
Wii: Use generic VFileOpen
This commit is contained in:
parent
52c66de694
commit
2f2e539871
|
@ -182,7 +182,7 @@ elseif(UNIX)
|
||||||
source_group("POSIX-specific code" FILES ${OS_SRC})
|
source_group("POSIX-specific code" FILES ${OS_SRC})
|
||||||
elseif(WII)
|
elseif(WII)
|
||||||
list(APPEND VFS_SRC ${CMAKE_SOURCE_DIR}/src/util/vfs/vfs-file.c)
|
list(APPEND VFS_SRC ${CMAKE_SOURCE_DIR}/src/util/vfs/vfs-file.c)
|
||||||
add_definitions(-DCOLOR_16_BIT -DCOLOR_5_6_5)
|
add_definitions(-DCOLOR_16_BIT -DCOLOR_5_6_5 -DUSE_VFS_FILE)
|
||||||
file(GLOB OS_SRC ${CMAKE_SOURCE_DIR}/src/platform/wii/wii-*.c)
|
file(GLOB OS_SRC ${CMAKE_SOURCE_DIR}/src/platform/wii/wii-*.c)
|
||||||
list(APPEND OS_LIB fat ogc)
|
list(APPEND OS_LIB fat ogc)
|
||||||
source_group("Wii-specific code" FILES ${OS_SRC})
|
source_group("Wii-specific code" FILES ${OS_SRC})
|
||||||
|
|
|
@ -247,7 +247,7 @@ static void GBAWiiFrame(void) {
|
||||||
}
|
}
|
||||||
|
|
||||||
bool GBAWiiLoadGame(const char* path) {
|
bool GBAWiiLoadGame(const char* path) {
|
||||||
rom = VFileFOpen(path, "rb");
|
rom = VFileOpen(path, O_RDONLY);
|
||||||
|
|
||||||
if (!rom) {
|
if (!rom) {
|
||||||
return false;
|
return false;
|
||||||
|
@ -256,7 +256,7 @@ bool GBAWiiLoadGame(const char* path) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
save = VFileFOpen("test.sav", "w+b");
|
save = VFileOpen("test.sav", O_RDWR | O_CREAT);
|
||||||
|
|
||||||
GBALoadROM(&gba, rom, save, path);
|
GBALoadROM(&gba, rom, save, path);
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue