Reorganized folder layout, cleaned Makefile (we do not need Python)

This commit is contained in:
Aurora 2016-03-23 20:23:27 +01:00
parent af451b4997
commit 0a9cd09cc3
3 changed files with 13 additions and 23 deletions

View File

@ -4,25 +4,16 @@ CC := arm-none-eabi-gcc
AS := arm-none-eabi-as
LD := arm-none-eabi-ld
OC := arm-none-eabi-objcopy
OPENSSL := openssl
PYTHON3 := python
PYTHON_VER_MAJOR := $(word 2, $(subst ., , $(shell python --version 2>&1)))
ifneq ($(PYTHON_VER_MAJOR), 3)
PYTHON3 := py -3
endif
name := AuReiNand
dir_source := source
dir_data := data
dir_build := build
dir_mset := CakeHax
dir_out := out
dir_emu := emunand
dir_reboot := reboot
dir_ninjhax := CakeBrah
dir_patches := patches
dir_loader := loader
dir_mset := CakeHax
dir_ninjhax := CakeBrah
dir_build := build
dir_out := out
ASFLAGS := -mlittle-endian -mcpu=arm946e-s -march=armv5te
CFLAGS := -Wall -Wextra -MMD -MP -marm $(ASFLAGS) -fno-builtin -fshort-wchar -std=c11 -Wno-main -O2 -ffast-math
@ -52,9 +43,12 @@ clean:
@rm -rf $(dir_out) $(dir_build)
@$(MAKE) -C $(dir_loader) clean
$(dir_out):
@mkdir -p "$(dir_out)/aurei/payloads"
$(dir_out)/$(name).dat: $(dir_build)/main.bin $(dir_out)
@$(MAKE) $(FLAGS) -C $(dir_mset) launcher
dd if=$(dir_build)/main.bin of=$@ bs=512 seek=144
@dd if=$(dir_build)/main.bin of=$@ bs=512 seek=144
$(dir_out)/arm9loaderhax.bin: $(dir_build)/main.bin $(dir_out)
@cp -av $(dir_build)/main.bin $@
@ -65,15 +59,11 @@ $(dir_out)/3ds/$(name): $(dir_out)
@mv $(dir_out)/$(name).3dsx $@
@mv $(dir_out)/$(name).smdh $@
$(dir_out):
@mkdir -p "$(dir_out)/aurei/payloads"
$(dir_build)/patches.h: $(dir_emu)/emuCode.s $(dir_reboot)/rebootCode.s
$(dir_build)/patches.h: $(dir_patches)/emunand.s $(dir_patches)/reboot.s
@mkdir -p "$(dir_build)"
@armips $<
@mv emunand.bin $(dir_build)
@armips $(word 2,$^)
@mv reboot.bin $(dir_build)
@mv emunand.bin reboot.bin $(dir_build)
@bin2c -o $@ -n emunand $(dir_build)/emunand.bin -n reboot $(dir_build)/reboot.bin
$(dir_build)/loader.h: $(dir_loader)/Makefile