Skip to content

Commit

Permalink
Added 2xrsa and FIRM entrypoints
Browse files Browse the repository at this point in the history
  • Loading branch information
d0k3 committed May 20, 2017
1 parent dd2963b commit 3f501cf
Show file tree
Hide file tree
Showing 4 changed files with 26 additions and 1 deletion.
8 changes: 8 additions & 0 deletions .gitmodules
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,11 @@
[submodule "CakeHax"]
path = CakeHax
url = https://github.com/dukesrg/CakeHax.git
[submodule "2xrsa"]
path = 2xrsa
url = https://github.com/b1l1s/2xrsa.git
ignore = dirty
[submodule "firmtool"]
path = firmtool
url = https://github.com/TuxSH/firmtool.git
ignore = dirty
1 change: 1 addition & 0 deletions 2xrsa
Submodule 2xrsa added at c3f93c
17 changes: 16 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,7 @@ export INCLUDE := $(foreach dir,$(INCLUDES),-I$(CURDIR)/$(dir)) \

export LIBPATHS := $(foreach dir,$(LIBDIRS),-L$(dir)/lib)

.PHONY: common clean all gateway binary cakehax cakerop brahma release
.PHONY: common clean all gateway firm 2xrsa binary cakehax cakerop brahma release

#---------------------------------------------------------------------------------
all: binary
Expand All @@ -119,10 +119,18 @@ submodules:
binary: common
@make --no-print-directory -C $(BUILD) -f $(CURDIR)/Makefile

firm: binary
@firmtool/firmtool build $(OUTPUT).firm -n 0x23F00000 -e 0 -D $(OUTPUT).bin -A 0x23F00000 -C NDMA -i

gateway: binary
@cp resources/LauncherTemplate.dat $(OUTPUT_D)/Launcher.dat
@dd if=$(OUTPUT).bin of=$(OUTPUT_D)/Launcher.dat bs=1497296 seek=1 conv=notrunc

2xrsa: binary
@make --no-print-directory -C 2xrsa
@mv $(OUTPUT).bin $(OUTPUT_D)/arm9.bin
@mv $(CURDIR)/2xrsa/bin/arm11.bin $(OUTPUT_D)/arm11.bin

cakehax: submodules binary
@make dir_out=$(OUTPUT_D) name=$(TARGET).dat -C CakeHax bigpayload
@dd if=$(OUTPUT).bin of=$(OUTPUT).dat bs=512 seek=160
Expand All @@ -143,11 +151,16 @@ brahma: submodules binary
release:
@rm -fr $(BUILD) $(OUTPUT_D) $(RELEASE)
@make --no-print-directory binary
@-make --no-print-directory firm
@-make --no-print-directory 2xrsa
@-make --no-print-directory cakerop
@-make --no-print-directory brahma
@[ -d $(RELEASE) ] || mkdir -p $(RELEASE)
@[ -d $(RELEASE)/$(TARGET) ] || mkdir -p $(RELEASE)/$(TARGET)
@cp $(OUTPUT).bin $(RELEASE)
@-cp $(OUTPUT).firm $(RELEASE)
@-cp $(OUTPUT_D)/arm9.bin $(RELEASE)
@-cp $(OUTPUT_D)/arm11.bin $(RELEASE)
@-cp $(OUTPUT).dat $(RELEASE)
@-cp $(OUTPUT).nds $(RELEASE)
@-cp $(OUTPUT).3dsx $(RELEASE)/$(TARGET)
Expand All @@ -163,6 +176,8 @@ clean:
@-make clean --no-print-directory -C CakesROP
@echo clean BrahmaLoader...
@-make clean --no-print-directory -C BrahmaLoader
@echo clean 2xrsa...
@-make clean --no-print-directory -C 2xrsa
@echo clean SafeB9SInstaller...
@rm -fr $(BUILD) $(OUTPUT_D) $(RELEASE)

Expand Down
1 change: 1 addition & 0 deletions firmtool
Submodule firmtool added at 375e66

1 comment on commit 3f501cf

@Valeri0p
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remember that the last 2xrsa implementation on safeA9LHinstaller was pretty unstable in the arm11 section...
Just saying, I trust You and your skills ;)

Please sign in to comment.