From dd5cf85f694dc44c3f282494783dd23fe358fe38 Mon Sep 17 00:00:00 2001 From: cathery Date: Tue, 8 Dec 2020 16:44:45 +0300 Subject: [PATCH] Quieter makefiles --- Makefile | 26 +++++++++++++------------- source/AppletCompanion/Makefile | 17 +++-------------- source/Makefile | 18 ++++++++++++------ source/Sysmodule/Makefile | 7 +++---- 4 files changed, 31 insertions(+), 37 deletions(-) diff --git a/Makefile b/Makefile index abb4adb..6b081d0 100644 --- a/Makefile +++ b/Makefile @@ -5,24 +5,24 @@ OUT_DIR := out COMMON_DIR := common all: build - rm -rf $(OUT_DIR) - mkdir -p $(OUT_DIR)/atmosphere/contents/690000000000000D/flags - mkdir -p $(OUT_DIR)/config/sys-con - mkdir -p $(OUT_DIR)/switch/ - touch $(OUT_DIR)/atmosphere/contents/690000000000000D/flags/boot2.flag - cp $(SOURCE_DIR)/Sysmodule/sys-con.nsp $(OUT_DIR)/atmosphere/contents/690000000000000D/exefs.nsp - cp $(SOURCE_DIR)/AppletCompanion/sys-con.nro $(OUT_DIR)/switch/sys-con.nro - cp -r $(COMMON_DIR)/. $(OUT_DIR)/ + @rm -rf $(OUT_DIR) + @mkdir -p $(OUT_DIR)/atmosphere/contents/690000000000000D/flags + @mkdir -p $(OUT_DIR)/config/sys-con + @mkdir -p $(OUT_DIR)/switch/ + @touch $(OUT_DIR)/atmosphere/contents/690000000000000D/flags/boot2.flag + @cp $(SOURCE_DIR)/Sysmodule/sys-con.nsp $(OUT_DIR)/atmosphere/contents/690000000000000D/exefs.nsp + @cp $(SOURCE_DIR)/AppletCompanion/sys-con.nro $(OUT_DIR)/switch/sys-con.nro + @cp -r $(COMMON_DIR)/. $(OUT_DIR)/ @echo [DONE] sys-con compiled successfully. All files have been placed in $(OUT_DIR)/ build: - $(MAKE) -C $(SOURCE_DIR) + @$(MAKE) --no-print-directory -C $(SOURCE_DIR) clean: - $(MAKE) -C $(SOURCE_DIR) clean - rm -rf $(OUT_DIR) + @$(MAKE) --no-print-directory -C $(SOURCE_DIR) clean + @rm -rf $(OUT_DIR) mrproper: - $(MAKE) -C $(SOURCE_DIR) mrproper - rm -rf $(OUT_DIR) + @$(MAKE) --no-print-directory -C $(SOURCE_DIR) mrproper + @rm -rf $(OUT_DIR) \ No newline at end of file diff --git a/source/AppletCompanion/Makefile b/source/AppletCompanion/Makefile index 8cff2d7..46772f1 100644 --- a/source/AppletCompanion/Makefile +++ b/source/AppletCompanion/Makefile @@ -161,31 +161,26 @@ endif all: $(BUILD) $(BUILD): - @echo building applet companion ... @[ -d $@ ] || mkdir -p $@ @$(MAKE) --no-print-directory \ -C $@ -f $(CURDIR)/Makefile \ - makeNRO + applet clean: - @echo cleaning applet companion ... @rm -fr $(BUILD) $(TARGET).nro $(TARGET).nacp $(TARGET).elf # Makefile commands #--------------------------------------------------------------------------------- else -.PHONY: makeNRO makeNSP +.PHONY: applet DEPENDS := $(OFILES:.o=.d) #--------------------------------------------------------------------------------- # main targets #--------------------------------------------------------------------------------- -makeNRO: $(OUTPUT).nro - -makeNSP: $(OUTPUT).nsp - #TODO: add an option to make exefs.nsp instead of $(OUTPUT).nsp +applet: $(OUTPUT).nro ifeq ($(strip $(NO_NACP)),) $(OUTPUT).nro : $(OUTPUT).elf $(OUTPUT).nacp @@ -193,12 +188,6 @@ else $(OUTPUT).nro : $(OUTPUT).elf endif - - -$(OUTPUT).nsp : $(OUTPUT).nso $(OUTPUT).npdm - -$(OUTPUT).nso : $(OUTPUT).elf - $(OUTPUT).elf : $(OFILES) $(OFILES_SRC) : $(HFILES_BIN) diff --git a/source/Makefile b/source/Makefile index 812881d..8460df3 100644 --- a/source/Makefile +++ b/source/Makefile @@ -6,17 +6,23 @@ TOPTARGETS := all clean mrproper all: $(COMPONENTS) libstratosphere: - $(MAKE) -C $@ + @echo Building libstratosphere... + @$(MAKE) --no-print-directory -C $@ AppletCompanion: - $(MAKE) -C $@ + @echo Building applet companion... + @$(MAKE) --no-print-directory -C $@ Sysmodule: libstratosphere - $(MAKE) -C $@ + @echo Building sysmodule... + @$(MAKE) --no-print-directory -C $@ clean: - $(MAKE) -C AppletCompanion clean - $(MAKE) -C Sysmodule clean + @echo Cleaning applet companion... + @$(MAKE) --no-print-directory -C AppletCompanion clean + @echo Cleaning sysmodule... + @$(MAKE) --no-print-directory -C Sysmodule clean mrproper: clean - $(MAKE) -C libstratosphere clean \ No newline at end of file + @echo Cleaning libstratosphere... + @$(MAKE) --no-print-directory -C libstratosphere clean \ No newline at end of file diff --git a/source/Sysmodule/Makefile b/source/Sysmodule/Makefile index 939f496..d775de8 100644 --- a/source/Sysmodule/Makefile +++ b/source/Sysmodule/Makefile @@ -88,24 +88,23 @@ all: $(BUILD) $(BUILD): @[ -d $@ ] || mkdir -p $@ - @$(MAKE) --no-print-directory -C $(BUILD) -f $(CURDIR)/Makefile + @$(MAKE) --no-print-directory -C $(BUILD) -f $(CURDIR)/Makefile sysmodule #--------------------------------------------------------------------------------- clean: - @echo clean ... @rm -fr $(BUILD) $(TARGET).nsp $(TARGET).npdm $(TARGET).nso $(TARGET).elf #--------------------------------------------------------------------------------- else -.PHONY: all +.PHONY: sysmodule DEPENDS := $(OFILES:.o=.d) #--------------------------------------------------------------------------------- # main targets #--------------------------------------------------------------------------------- -all : $(OUTPUT).nsp +sysmodule : $(OUTPUT).nsp ifeq ($(strip $(APP_JSON)),) $(OUTPUT).nsp : $(OUTPUT).nso