From ba4d39a0caf2e7f1ed761cdd2296963133309765 Mon Sep 17 00:00:00 2001 From: Michael Scire Date: Tue, 16 Oct 2018 19:41:06 -0700 Subject: [PATCH] Atmosphere: add make dist --- .gitignore | 4 ++++ Makefile | 30 +++++++++++++++++++++++++++-- common/defaults/BCT.ini | 8 ++++++++ common/defaults/loader.ini | 4 ++++ common/include/atmosphere/version.h | 6 +++--- 5 files changed, 47 insertions(+), 5 deletions(-) create mode 100644 common/defaults/BCT.ini create mode 100644 common/defaults/loader.ini diff --git a/.gitignore b/.gitignore index e39d9f114..f55c55a62 100644 --- a/.gitignore +++ b/.gitignore @@ -61,6 +61,10 @@ Module.symvers Mkfile.old dkms.conf +# Distribution files +*.tgz +*.zip + .**/ # NOTE: make sure to make exceptions to this pattern when needed! diff --git a/Makefile b/Makefile index 014cb646c..20b621a00 100644 --- a/Makefile +++ b/Makefile @@ -1,10 +1,36 @@ -TOPTARGETS := all clean +TOPTARGETS := all clean dist -all: fusee +all: fusee creport fusee: $(MAKE) -C $@ all +creport: + $(MAKE) -C stratosphere/creport all + clean: $(MAKE) -C fusee clean + +dist: fusee creport + $(eval MAJORVER = $(shell grep '\ATMOSPHERE_RELEASE_VERSION_MAJOR\b' common/include/atmosphere/version.h \ + | tr -s [:blank:] \ + | cut -d' ' -f3)) + $(eval MINORVER = $(shell grep '\ATMOSPHERE_RELEASE_VERSION_MINOR\b' common/include/atmosphere/version.h \ + | tr -s [:blank:] \ + | cut -d' ' -f3)) + $(eval MICROVER = $(shell grep '\ATMOSPHERE_RELEASE_VERSION_MICRO\b' common/include/atmosphere/version.h \ + | tr -s [:blank:] \ + | cut -d' ' -f3)) + $(eval AMSVER = $(MAJORVER).$(MINORVER).$(MICROVER)) + rm -rf atmosphere-$(AMSVER) + mkdir atmosphere-$(AMSVER) + mkdir atmosphere-$(AMSVER)/atmosphere + mkdir -p atmosphere-$(AMSVER)/atmosphere/titles/0100000000000036 + cp fusee/fusee-secondary/fusee-secondary.bin atmosphere-$(AMSVER)/fusee-secondary.bin + cp common/defaults/BCT.ini atmosphere-$(AMSVER)/BCT.ini + cp common/defaults/loader.ini atmosphere-$(AMSVER)/atmosphere/loader.ini + cp stratosphere/creport/creport.nsp atmosphere-$(AMSVER)/atmosphere/titles/0100000000000036/exefs.nsp + cd atmosphere-$(AMSVER); zip -r ../atmosphere-$(AMSVER).zip ./*; cd ../; + rm -r atmosphere-$(AMSVER) + .PHONY: $(TOPTARGETS) fusee diff --git a/common/defaults/BCT.ini b/common/defaults/BCT.ini new file mode 100644 index 000000000..d609b740e --- /dev/null +++ b/common/defaults/BCT.ini @@ -0,0 +1,8 @@ +BCT0 +[stage1] +stage2_path = fusee-secondary.bin +stage2_addr = 0xF0000000 +stage2_entrypoint = 0xF0000000 + +[exosphere] +target_firmware = 6 \ No newline at end of file diff --git a/common/defaults/loader.ini b/common/defaults/loader.ini new file mode 100644 index 000000000..1049ef9dd --- /dev/null +++ b/common/defaults/loader.ini @@ -0,0 +1,4 @@ +[config] +hbl_tid=010000000000100D +hbl_path=atmosphere/hbl.nsp +override_key=!R \ No newline at end of file diff --git a/common/include/atmosphere/version.h b/common/include/atmosphere/version.h index 58dd3a50c..6c0c59fbe 100644 --- a/common/include/atmosphere/version.h +++ b/common/include/atmosphere/version.h @@ -17,8 +17,8 @@ #ifndef ATMOSPHERE_VERSION_H #define ATMOSPHERE_VERSION_H -#define ATMOSPHERE_RELEASE_VERSION_MAJOR 0 -#define ATMOSPHERE_RELEASE_VERSION_MINOR 7 -#define ATMOSPHERE_RELEASE_VERSION_MICRO 0 +#define ATMOSPHERE_RELEASE_VERSION_MAJOR 0 +#define ATMOSPHERE_RELEASE_VERSION_MINOR 7 +#define ATMOSPHERE_RELEASE_VERSION_MICRO 0 #endif \ No newline at end of file