mirror of
https://github.com/wiiu-env/RPXLoadingModule.git
synced 2024-11-22 01:49:15 +01:00
Use WUMS 0.3.2 and update Dockerfile
This commit is contained in:
parent
40688d9275
commit
d50e438024
10
Dockerfile
10
Dockerfile
@ -1,11 +1,11 @@
|
|||||||
FROM wiiuenv/devkitppc:20220806
|
FROM wiiuenv/devkitppc:20221228
|
||||||
|
|
||||||
COPY --from=wiiuenv/librpxloader:20220903 /artifacts $DEVKITPRO
|
COPY --from=wiiuenv/librpxloader:20220903 /artifacts $DEVKITPRO
|
||||||
COPY --from=wiiuenv/libfunctionpatcher:20220904 /artifacts $DEVKITPRO
|
COPY --from=wiiuenv/libfunctionpatcher:20220904 /artifacts $DEVKITPRO
|
||||||
COPY --from=wiiuenv/wiiumodulesystem:20220904 /artifacts $DEVKITPRO
|
COPY --from=wiiuenv/wiiumodulesystem:20230106 /artifacts $DEVKITPRO
|
||||||
COPY --from=wiiuenv/libwuhbutils:20220903 /artifacts $DEVKITPRO
|
COPY --from=wiiuenv/libwuhbutils:20220904 /artifacts $DEVKITPRO
|
||||||
COPY --from=wiiuenv/libcontentredirection:20220903 /artifacts $DEVKITPRO
|
COPY --from=wiiuenv/libcontentredirection:20221010 /artifacts $DEVKITPRO
|
||||||
COPY --from=wiiuenv/libromfs_wiiu:20220904 /artifacts $DEVKITPRO
|
COPY --from=wiiuenv/libromfs_wiiu:20220904 /artifacts $DEVKITPRO
|
||||||
COPY --from=wiiuenv/libmocha:20220903 /artifacts $DEVKITPRO
|
COPY --from=wiiuenv/libmocha:20220919 /artifacts $DEVKITPRO
|
||||||
|
|
||||||
WORKDIR project
|
WORKDIR project
|
||||||
|
11
Makefile
11
Makefile
@ -38,7 +38,7 @@ CFLAGS += $(INCLUDE) -D__WIIU__ -D__WUT__
|
|||||||
CXXFLAGS := $(CFLAGS) -std=c++20
|
CXXFLAGS := $(CFLAGS) -std=c++20
|
||||||
|
|
||||||
ASFLAGS := -g $(ARCH)
|
ASFLAGS := -g $(ARCH)
|
||||||
LDFLAGS = -g $(ARCH) $(RPXSPECS) -Wl,-Map,$(notdir $*.map) -T$(WUMS_ROOT)/share/libfunctionpatcher.ld -Tcontentredirection.ld -Twuhbutils.ld $(WUMSSPECS)
|
LDFLAGS = -g $(ARCH) $(RPXSPECS) -Wl,-Map,$(notdir $*.map) -T$(WUMS_ROOT)/share/libfunctionpatcher.ld $(WUMSSPECS)
|
||||||
|
|
||||||
ifeq ($(DEBUG),1)
|
ifeq ($(DEBUG),1)
|
||||||
CXXFLAGS += -DDEBUG -g
|
CXXFLAGS += -DDEBUG -g
|
||||||
@ -77,7 +77,6 @@ export DEPSDIR := $(CURDIR)/$(BUILD)
|
|||||||
CFILES := $(foreach dir,$(SOURCES),$(notdir $(wildcard $(dir)/*.c)))
|
CFILES := $(foreach dir,$(SOURCES),$(notdir $(wildcard $(dir)/*.c)))
|
||||||
CPPFILES := $(foreach dir,$(SOURCES),$(notdir $(wildcard $(dir)/*.cpp)))
|
CPPFILES := $(foreach dir,$(SOURCES),$(notdir $(wildcard $(dir)/*.cpp)))
|
||||||
SFILES := $(foreach dir,$(SOURCES),$(notdir $(wildcard $(dir)/*.s)))
|
SFILES := $(foreach dir,$(SOURCES),$(notdir $(wildcard $(dir)/*.s)))
|
||||||
DEFFILES := $(foreach dir,$(SOURCES),$(notdir $(wildcard $(dir)/*.def)))
|
|
||||||
BINFILES := $(foreach dir,$(DATA),$(notdir $(wildcard $(dir)/*.*)))
|
BINFILES := $(foreach dir,$(DATA),$(notdir $(wildcard $(dir)/*.*)))
|
||||||
|
|
||||||
#-------------------------------------------------------------------------------
|
#-------------------------------------------------------------------------------
|
||||||
@ -95,7 +94,7 @@ endif
|
|||||||
#-------------------------------------------------------------------------------
|
#-------------------------------------------------------------------------------
|
||||||
|
|
||||||
export OFILES_BIN := $(addsuffix .o,$(BINFILES))
|
export OFILES_BIN := $(addsuffix .o,$(BINFILES))
|
||||||
export OFILES_SRC := $(DEFFILES:.def=.o) $(CPPFILES:.cpp=.o) $(CFILES:.c=.o) $(SFILES:.s=.o)
|
export OFILES_SRC := $(CPPFILES:.cpp=.o) $(CFILES:.c=.o) $(SFILES:.s=.o)
|
||||||
export OFILES := $(OFILES_BIN) $(OFILES_SRC)
|
export OFILES := $(OFILES_BIN) $(OFILES_SRC)
|
||||||
export HFILES_BIN := $(addsuffix .h,$(subst .,_,$(BINFILES)))
|
export HFILES_BIN := $(addsuffix .h,$(subst .,_,$(BINFILES)))
|
||||||
|
|
||||||
@ -139,11 +138,7 @@ $(OFILES_SRC) : $(HFILES_BIN)
|
|||||||
#-------------------------------------------------------------------------------
|
#-------------------------------------------------------------------------------
|
||||||
# you need a rule like this for each extension you use as binary data
|
# you need a rule like this for each extension you use as binary data
|
||||||
#-------------------------------------------------------------------------------
|
#-------------------------------------------------------------------------------
|
||||||
%.o: %.def
|
|
||||||
$(SILENTMSG) $(notdir $<)
|
|
||||||
$(SILENTCMD)rplimportgen $< $*.s $*.ld $(ERROR_FILTER)
|
|
||||||
$(SILENTCMD)$(CC) -x assembler-with-cpp $(ASFLAGS) -c $*.s -o $@ $(ERROR_FILTER)
|
|
||||||
|
|
||||||
#---------------------------------------------------------------------------------
|
#---------------------------------------------------------------------------------
|
||||||
%_bin.h %.bin.o : %.bin
|
%_bin.h %.bin.o : %.bin
|
||||||
#---------------------------------------------------------------------------------
|
#---------------------------------------------------------------------------------
|
||||||
|
@ -1,4 +0,0 @@
|
|||||||
:NAME homebrew_content_redirection
|
|
||||||
|
|
||||||
:TEXT
|
|
||||||
CRGetVersion
|
|
13
src/main.cpp
13
src/main.cpp
@ -21,8 +21,9 @@
|
|||||||
WUMS_MODULE_EXPORT_NAME("homebrew_rpx_loader");
|
WUMS_MODULE_EXPORT_NAME("homebrew_rpx_loader");
|
||||||
WUMS_USE_WUT_DEVOPTAB();
|
WUMS_USE_WUT_DEVOPTAB();
|
||||||
|
|
||||||
extern "C" ContentRedirectionApiErrorType CRGetVersion(ContentRedirectionVersion *);
|
WUMS_DEPENDS_ON(homebrew_content_redirection);
|
||||||
extern "C" WUHBUtilsApiErrorType WUU_GetVersion(WUHBUtilsVersion *);
|
WUMS_DEPENDS_ON(homebrew_wuhb_utils);
|
||||||
|
WUMS_DEPENDS_ON(homebrew_functionpatcher);
|
||||||
|
|
||||||
WUMS_INITIALIZE() {
|
WUMS_INITIALIZE() {
|
||||||
initLogging();
|
initLogging();
|
||||||
@ -35,20 +36,12 @@ WUMS_INITIALIZE() {
|
|||||||
DEBUG_FUNCTION_LINE("Patch functions finished");
|
DEBUG_FUNCTION_LINE("Patch functions finished");
|
||||||
gReplacementInfo = {};
|
gReplacementInfo = {};
|
||||||
|
|
||||||
// Call this function to make sure the Content Redirection will be loaded before this module is module.
|
|
||||||
CRGetVersion(nullptr);
|
|
||||||
|
|
||||||
// Call this function to make sure the WUHBUtils will be loaded before this module is module.
|
|
||||||
WUU_GetVersion(nullptr);
|
|
||||||
|
|
||||||
// But then use libcontentredirection instead.
|
|
||||||
ContentRedirectionStatus error;
|
ContentRedirectionStatus error;
|
||||||
if ((error = ContentRedirection_InitLibrary()) != CONTENT_REDIRECTION_RESULT_SUCCESS) {
|
if ((error = ContentRedirection_InitLibrary()) != CONTENT_REDIRECTION_RESULT_SUCCESS) {
|
||||||
DEBUG_FUNCTION_LINE_ERR("Failed to init ContentRedirection. Error %d", error);
|
DEBUG_FUNCTION_LINE_ERR("Failed to init ContentRedirection. Error %d", error);
|
||||||
OSFatal("Failed to init ContentRedirection.");
|
OSFatal("Failed to init ContentRedirection.");
|
||||||
}
|
}
|
||||||
|
|
||||||
// But then use libwuhbutils instead.
|
|
||||||
WUHBUtilsStatus error2;
|
WUHBUtilsStatus error2;
|
||||||
if ((error2 = WUHBUtils_InitLibrary()) != WUHB_UTILS_RESULT_SUCCESS) {
|
if ((error2 = WUHBUtils_InitLibrary()) != WUHB_UTILS_RESULT_SUCCESS) {
|
||||||
DEBUG_FUNCTION_LINE_ERR("Failed to init WUHBUtils. Error %d", error2);
|
DEBUG_FUNCTION_LINE_ERR("Failed to init WUHBUtils. Error %d", error2);
|
||||||
|
@ -1,4 +0,0 @@
|
|||||||
:NAME homebrew_wuhb_utils
|
|
||||||
|
|
||||||
:TEXT
|
|
||||||
WUU_GetVersion
|
|
Loading…
Reference in New Issue
Block a user