mirror of
https://github.com/wiiu-env/RPXLoadingModule.git
synced 2024-11-10 12:15:07 +01:00
Use WUMS 0.3.2 and update Dockerfile
This commit is contained in:
parent
49530dde60
commit
f78fc61290
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/libfunctionpatcher:20220904 /artifacts $DEVKITPRO
|
||||
COPY --from=wiiuenv/wiiumodulesystem:20220904 /artifacts $DEVKITPRO
|
||||
COPY --from=wiiuenv/libwuhbutils:20220903 /artifacts $DEVKITPRO
|
||||
COPY --from=wiiuenv/libcontentredirection:20220903 /artifacts $DEVKITPRO
|
||||
COPY --from=wiiuenv/wiiumodulesystem:20230106 /artifacts $DEVKITPRO
|
||||
COPY --from=wiiuenv/libwuhbutils:20220904 /artifacts $DEVKITPRO
|
||||
COPY --from=wiiuenv/libcontentredirection:20221010 /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
|
||||
|
11
Makefile
11
Makefile
@ -38,7 +38,7 @@ CFLAGS += $(INCLUDE) -D__WIIU__ -D__WUT__
|
||||
CXXFLAGS := $(CFLAGS) -std=c++20
|
||||
|
||||
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)
|
||||
CXXFLAGS += -DDEBUG -g
|
||||
@ -77,7 +77,6 @@ export DEPSDIR := $(CURDIR)/$(BUILD)
|
||||
CFILES := $(foreach dir,$(SOURCES),$(notdir $(wildcard $(dir)/*.c)))
|
||||
CPPFILES := $(foreach dir,$(SOURCES),$(notdir $(wildcard $(dir)/*.cpp)))
|
||||
SFILES := $(foreach dir,$(SOURCES),$(notdir $(wildcard $(dir)/*.s)))
|
||||
DEFFILES := $(foreach dir,$(SOURCES),$(notdir $(wildcard $(dir)/*.def)))
|
||||
BINFILES := $(foreach dir,$(DATA),$(notdir $(wildcard $(dir)/*.*)))
|
||||
|
||||
#-------------------------------------------------------------------------------
|
||||
@ -95,7 +94,7 @@ endif
|
||||
#-------------------------------------------------------------------------------
|
||||
|
||||
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 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
|
||||
#-------------------------------------------------------------------------------
|
||||
%.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
|
||||
#---------------------------------------------------------------------------------
|
||||
|
@ -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_USE_WUT_DEVOPTAB();
|
||||
|
||||
extern "C" ContentRedirectionApiErrorType CRGetVersion(ContentRedirectionVersion *);
|
||||
extern "C" WUHBUtilsApiErrorType WUU_GetVersion(WUHBUtilsVersion *);
|
||||
WUMS_DEPENDS_ON(homebrew_content_redirection);
|
||||
WUMS_DEPENDS_ON(homebrew_wuhb_utils);
|
||||
WUMS_DEPENDS_ON(homebrew_functionpatcher);
|
||||
|
||||
WUMS_INITIALIZE() {
|
||||
initLogging();
|
||||
@ -35,20 +36,12 @@ WUMS_INITIALIZE() {
|
||||
DEBUG_FUNCTION_LINE("Patch functions finished");
|
||||
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;
|
||||
if ((error = ContentRedirection_InitLibrary()) != CONTENT_REDIRECTION_RESULT_SUCCESS) {
|
||||
DEBUG_FUNCTION_LINE_ERR("Failed to init ContentRedirection. Error %d", error);
|
||||
OSFatal("Failed to init ContentRedirection.");
|
||||
}
|
||||
|
||||
// But then use libwuhbutils instead.
|
||||
WUHBUtilsStatus error2;
|
||||
if ((error2 = WUHBUtils_InitLibrary()) != WUHB_UTILS_RESULT_SUCCESS) {
|
||||
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