From 4f5fc898d7816bd0b0e9555d8c3e3925f3aea382 Mon Sep 17 00:00:00 2001 From: mrdudz Date: Thu, 26 Jun 2025 18:40:32 +0200 Subject: [PATCH 01/16] someone accidently checked this in, i guess --- test/asm/listing/Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/asm/listing/Makefile b/test/asm/listing/Makefile index 4321d3b95..9dc871dad 100644 --- a/test/asm/listing/Makefile +++ b/test/asm/listing/Makefile @@ -27,7 +27,7 @@ else endif ifdef QUIET -# .SILENT: + .SILENT: endif CA65 := $(if $(wildcard ../../../bin/ca65*),..$S..$S..$Sbin$Sca65,ca65) From 75aa45d41e745c569d6847c994c9a062b0a90739 Mon Sep 17 00:00:00 2001 From: mrdudz Date: Thu, 26 Jun 2025 18:42:01 +0200 Subject: [PATCH 02/16] when -s was used, implicitly use QUIET=1. also explicitly propagate QUIET to submakefile(s) --- test/Makefile | 44 ++++++++++++++++++++++++++------------------ test/asm/Makefile | 32 ++++++++++++++++++++------------ 2 files changed, 46 insertions(+), 30 deletions(-) diff --git a/test/Makefile b/test/Makefile index 94bc7e5ea..c6cff47a4 100644 --- a/test/Makefile +++ b/test/Makefile @@ -16,6 +16,14 @@ else RMDIR = $(RM) -r $1 endif +ifeq ($(SILENT),s) + QUIET := 1 +endif + +ifneq ($(QUIET),1) + QUIET := 0 +endif + WORKDIR = ../testwrk .PHONY: test continue mostlyclean clean success_message @@ -25,15 +33,15 @@ test: @$(MAKE) continue continue: - @$(MAKE) -C asm all - @$(MAKE) -C dasm all - @$(MAKE) -C val all - @$(MAKE) -C ref all - @$(MAKE) -C err all - @$(MAKE) -C standard all - @$(MAKE) -C standard_err all - @$(MAKE) -C misc all - @$(MAKE) -C todo all + @$(MAKE) -C asm all QUIET=$(QUIET) + @$(MAKE) -C dasm all QUIET=$(QUIET) + @$(MAKE) -C val all QUIET=$(QUIET) + @$(MAKE) -C ref all QUIET=$(QUIET) + @$(MAKE) -C err all QUIET=$(QUIET) + @$(MAKE) -C standard all QUIET=$(QUIET) + @$(MAKE) -C standard_err all QUIET=$(QUIET) + @$(MAKE) -C misc all QUIET=$(QUIET) + @$(MAKE) -C todo all QUIET=$(QUIET) @$(MAKE) success_message success_message: @@ -42,15 +50,15 @@ success_message: $(info ###################################) mostlyclean: - @$(MAKE) -C asm clean - @$(MAKE) -C dasm clean - @$(MAKE) -C val clean - @$(MAKE) -C ref clean - @$(MAKE) -C err clean - @$(MAKE) -C standard clean - @$(MAKE) -C standard_err clean - @$(MAKE) -C misc clean - @$(MAKE) -C todo clean + @$(MAKE) -C asm clean QUIET=$(QUIET) + @$(MAKE) -C dasm clean QUIET=$(QUIET) + @$(MAKE) -C val clean QUIET=$(QUIET) + @$(MAKE) -C ref clean QUIET=$(QUIET) + @$(MAKE) -C err clean QUIET=$(QUIET) + @$(MAKE) -C standard clean QUIET=$(QUIET) + @$(MAKE) -C standard_err clean QUIET=$(QUIET) + @$(MAKE) -C misc clean QUIET=$(QUIET) + @$(MAKE) -C todo clean QUIET=$(QUIET) clean: mostlyclean @$(call RMDIR,$(WORKDIR)) diff --git a/test/asm/Makefile b/test/asm/Makefile index 2d5ba764e..bfae97222 100644 --- a/test/asm/Makefile +++ b/test/asm/Makefile @@ -16,6 +16,14 @@ else RMDIR = $(RM) -r $1 endif +ifeq ($(SILENT),s) + QUIET := 1 +endif + +ifneq ($(QUIET),1) + QUIET := 0 +endif + WORKDIR = ../testwrk/asm .PHONY: all continue mostlyclean clean @@ -23,20 +31,20 @@ WORKDIR = ../testwrk/asm all: mostlyclean continue continue: mostlyclean - @$(MAKE) -C cpudetect all - @$(MAKE) -C opcodes all - @$(MAKE) -C listing all - @$(MAKE) -C val all - @$(MAKE) -C err all - @$(MAKE) -C misc all + @$(MAKE) --no-print-directory -C cpudetect all QUIET=$(QUIET) + @$(MAKE) --no-print-directory -C opcodes all QUIET=$(QUIET) + @$(MAKE) --no-print-directory -C listing all QUIET=$(QUIET) + @$(MAKE) --no-print-directory -C val all QUIET=$(QUIET) + @$(MAKE) --no-print-directory -C err all QUIET=$(QUIET) + @$(MAKE) --no-print-directory -C misc all QUIET=$(QUIET) mostlyclean: - @$(MAKE) -C cpudetect clean - @$(MAKE) -C opcodes clean - @$(MAKE) -C listing clean - @$(MAKE) -C val clean - @$(MAKE) -C err clean - @$(MAKE) -C misc clean + @$(MAKE) --no-print-directory -C cpudetect clean + @$(MAKE) --no-print-directory -C opcodes clean + @$(MAKE) --no-print-directory -C listing clean + @$(MAKE) --no-print-directory -C val clean + @$(MAKE) --no-print-directory -C err clean + @$(MAKE) --no-print-directory -C misc clean clean: mostlyclean @$(call RMDIR,$(WORKDIR)) From 73869a6f389c20b2b8e04998fcaee2f291cf0129 Mon Sep 17 00:00:00 2001 From: mrdudz Date: Thu, 26 Jun 2025 19:45:52 +0200 Subject: [PATCH 03/16] make propagating QUIET=1 down actually work, also set --no-print-directory depending on QUIET --- test/Makefile | 43 ++++++++++++++++++++++--------------------- test/asm/Makefile | 29 +++++++++++++++-------------- 2 files changed, 37 insertions(+), 35 deletions(-) diff --git a/test/Makefile b/test/Makefile index c6cff47a4..b647dbe33 100644 --- a/test/Makefile +++ b/test/Makefile @@ -17,11 +17,12 @@ else endif ifeq ($(SILENT),s) - QUIET := 1 + QUIET = 1 endif -ifneq ($(QUIET),1) - QUIET := 0 +ifdef QUIET + PQ = "QUIET=1" + PD = --no-print-directory endif WORKDIR = ../testwrk @@ -33,15 +34,15 @@ test: @$(MAKE) continue continue: - @$(MAKE) -C asm all QUIET=$(QUIET) - @$(MAKE) -C dasm all QUIET=$(QUIET) - @$(MAKE) -C val all QUIET=$(QUIET) - @$(MAKE) -C ref all QUIET=$(QUIET) - @$(MAKE) -C err all QUIET=$(QUIET) - @$(MAKE) -C standard all QUIET=$(QUIET) - @$(MAKE) -C standard_err all QUIET=$(QUIET) - @$(MAKE) -C misc all QUIET=$(QUIET) - @$(MAKE) -C todo all QUIET=$(QUIET) + @$(MAKE) $(PD) -C asm all $(PQ) + @$(MAKE) $(PD) -C dasm all $(PQ) + @$(MAKE) $(PD) -C val all $(PQ) + @$(MAKE) $(PD) -C ref all $(PQ) + @$(MAKE) $(PD) -C err all $(PQ) + @$(MAKE) $(PD) -C standard all $(PQ) + @$(MAKE) $(PD) -C standard_err all $(PQ) + @$(MAKE) $(PD) -C misc all $(PQ) + @$(MAKE) $(PD) -C todo all $(PQ) @$(MAKE) success_message success_message: @@ -50,15 +51,15 @@ success_message: $(info ###################################) mostlyclean: - @$(MAKE) -C asm clean QUIET=$(QUIET) - @$(MAKE) -C dasm clean QUIET=$(QUIET) - @$(MAKE) -C val clean QUIET=$(QUIET) - @$(MAKE) -C ref clean QUIET=$(QUIET) - @$(MAKE) -C err clean QUIET=$(QUIET) - @$(MAKE) -C standard clean QUIET=$(QUIET) - @$(MAKE) -C standard_err clean QUIET=$(QUIET) - @$(MAKE) -C misc clean QUIET=$(QUIET) - @$(MAKE) -C todo clean QUIET=$(QUIET) + @$(MAKE) $(PD) -C asm clean $(PQ) + @$(MAKE) $(PD) -C dasm clean $(PQ) + @$(MAKE) $(PD) -C val clean $(PQ) + @$(MAKE) $(PD) -C ref clean $(PQ) + @$(MAKE) $(PD) -C err clean $(PQ) + @$(MAKE) $(PD) -C standard clean $(PQ) + @$(MAKE) $(PD) -C standard_err clean $(PQ) + @$(MAKE) $(PD) -C misc clean $(PQ) + @$(MAKE) $(PD) -C todo clean $(PQ) clean: mostlyclean @$(call RMDIR,$(WORKDIR)) diff --git a/test/asm/Makefile b/test/asm/Makefile index bfae97222..8d959ecae 100644 --- a/test/asm/Makefile +++ b/test/asm/Makefile @@ -20,8 +20,9 @@ ifeq ($(SILENT),s) QUIET := 1 endif -ifneq ($(QUIET),1) - QUIET := 0 +ifdef QUIET + PQ = "QUIET=1" + PD = --no-print-directory endif WORKDIR = ../testwrk/asm @@ -31,20 +32,20 @@ WORKDIR = ../testwrk/asm all: mostlyclean continue continue: mostlyclean - @$(MAKE) --no-print-directory -C cpudetect all QUIET=$(QUIET) - @$(MAKE) --no-print-directory -C opcodes all QUIET=$(QUIET) - @$(MAKE) --no-print-directory -C listing all QUIET=$(QUIET) - @$(MAKE) --no-print-directory -C val all QUIET=$(QUIET) - @$(MAKE) --no-print-directory -C err all QUIET=$(QUIET) - @$(MAKE) --no-print-directory -C misc all QUIET=$(QUIET) + @$(MAKE) $(PD) -C cpudetect all $(PQ) + @$(MAKE) $(PD) -C opcodes all $(PQ) + @$(MAKE) $(PD) -C listing all $(PQ) + @$(MAKE) $(PD) -C val all $(PQ) + @$(MAKE) $(PD) -C err all $(PQ) + @$(MAKE) $(PD) -C misc all $(PQ) mostlyclean: - @$(MAKE) --no-print-directory -C cpudetect clean - @$(MAKE) --no-print-directory -C opcodes clean - @$(MAKE) --no-print-directory -C listing clean - @$(MAKE) --no-print-directory -C val clean - @$(MAKE) --no-print-directory -C err clean - @$(MAKE) --no-print-directory -C misc clean + @$(MAKE) $(PD) -C cpudetect clean $(PQ) + @$(MAKE) $(PD) -C opcodes clean $(PQ) + @$(MAKE) $(PD) -C listing clean $(PQ) + @$(MAKE) $(PD) -C val clean $(PQ) + @$(MAKE) $(PD) -C err clean $(PQ) + @$(MAKE) $(PD) -C misc clean $(PQ) clean: mostlyclean @$(call RMDIR,$(WORKDIR)) From 7a85575158ffc4e4325335a92cd3ae9192747b92 Mon Sep 17 00:00:00 2001 From: mrdudz Date: Thu, 26 Jun 2025 19:48:16 +0200 Subject: [PATCH 04/16] fix handling of QUIET in the "test" directory --- test/asm/cpudetect/Makefile | 10 +++++--- test/asm/err/Makefile | 2 ++ test/asm/listing/Makefile | 47 ++++++++++++++++++++++--------------- test/asm/misc/Makefile | 1 + test/asm/opcodes/Makefile | 3 +++ test/asm/val/Makefile | 4 ++-- test/dasm/Makefile | 5 ++++ test/err/Makefile | 5 +++- test/misc/Makefile | 39 +++++++++++++++--------------- test/ref/Makefile | 2 ++ test/standard/Makefile | 1 + test/standard_err/Makefile | 5 +++- test/todo/Makefile | 2 ++ test/val/Makefile | 9 +++---- 14 files changed, 86 insertions(+), 49 deletions(-) diff --git a/test/asm/cpudetect/Makefile b/test/asm/cpudetect/Makefile index fde19b17b..a77e5b576 100644 --- a/test/asm/cpudetect/Makefile +++ b/test/asm/cpudetect/Makefile @@ -20,8 +20,12 @@ else RMDIR = $(RM) -r $1 endif + ifdef QUIET .SILENT: + NULLOUT = >$(NULLDEV) + NULLERR = 2>$(NULLDEV) + CATERR = 2> $(WORKDIR)/$$@.errlog || (cat $(WORKDIR)/$$@.errlog && false) endif CA65 := $(if $(wildcard ../../../bin/ca65*),../../../bin/ca65,ca65) @@ -52,8 +56,8 @@ define CPUDETECT_template $(WORKDIR)/$1-cpudetect.bin: cpudetect.s $1-cpudetect.ref $(ISEQUAL) $(if $(QUIET),echo asm/$1-cpudetect.bin) - $(CA65) -t none --cpu $1 -l $$(@:.bin=.lst) -o $$(@:.bin=.o) $$< - $(LD65) -t none -o $$@ $$(@:.bin=.o) none.lib + $(CA65) -t none --cpu $1 -l $$(@:.bin=.lst) -o $$(@:.bin=.o) $$< $(CATERR) + $(LD65) -t none -o $$@ $$(@:.bin=.o) none.lib $(CATERR) $(ISEQUAL) $1-cpudetect.ref $$@ endef # CPUDETECT_template @@ -61,7 +65,7 @@ endef # CPUDETECT_template $(foreach cpu,$(CPUDETECT_CPUS),$(eval $(call CPUDETECT_template,$(cpu)))) $(WORKDIR)/%.o: %.s | $(WORKDIR) - $(CA65) -l $(@:.o=.lst) -o $@ $< + $(CA65) -l $(@:.o=.lst) -o $@ $< $(NULLOUT) $(CATERR) clean: @$(call RMDIR,$(WORKDIR)) diff --git a/test/asm/err/Makefile b/test/asm/err/Makefile index c1a8285e4..5c329138b 100644 --- a/test/asm/err/Makefile +++ b/test/asm/err/Makefile @@ -26,7 +26,9 @@ endif ifdef QUIET .SILENT: + NULLOUT = >$(NULLDEV) NULLERR = 2>$(NULLDEV) + CATERR = 2> $(WORKDIR)/$$@.errlog || (cat $(WORKDIR)/$$@.errlog && false) endif CA65 := $(if $(wildcard ../../../bin/ca65*),..$S..$S..$Sbin$Sca65,ca65) diff --git a/test/asm/listing/Makefile b/test/asm/listing/Makefile index 9dc871dad..9d815985d 100644 --- a/test/asm/listing/Makefile +++ b/test/asm/listing/Makefile @@ -17,6 +17,7 @@ ifdef CMD_EXE RMDIR = -rmdir /q /s $(subst /,\,$1) TRUE = exit 0 CAT = type $(subst /,\,$1) + NULLDEV = nul: else S = / EXE = @@ -24,10 +25,14 @@ else RMDIR = $(RM) -r $1 TRUE = true CAT = cat $1 + NULLDEV = /dev/null endif ifdef QUIET .SILENT: + NULLOUT = >$(NULLDEV) + NULLERR = 2>$(NULLDEV) + CATERR = 2> $(WORKDIR)/$$@.errlog || (cat $(WORKDIR)/$$@.errlog && false) endif CA65 := $(if $(wildcard ../../../bin/ca65*),..$S..$S..$Sbin$Sca65,ca65) @@ -82,48 +87,52 @@ endif endif ifneq ($(wildcard ref/$1.err-ref),) - $(ISEQUAL) ref/$1.err-ref $$(@:.bin=.err) + $(ISEQUAL) ref/$1.err-ref $$(@:.bin=.err) $(NULLERR) else - $(ISEQUAL) --empty $$(@:.bin=.err) + $(ISEQUAL) --empty $$(@:.bin=.err) $(NULLERR) endif ifneq ($(wildcard ref/$1.err2-ref),) - $(ISEQUAL) ref/$1.err2-ref $$(@:.bin=.err2) + $(ISEQUAL) ref/$1.err2-ref $$(@:.bin=.err2) $(NULLERR) else - $(ISEQUAL) --empty $$(@:.bin=.err2) + $(ISEQUAL) --empty $$(@:.bin=.err2) $(NULLERR) endif ifneq ($(wildcard ref/$1.bin-ref),) - $(ISEQUAL) --binary ref/$1.bin-ref $$@ + $(ISEQUAL) --binary ref/$1.bin-ref $$@ $(NULLERR) endif # rem $(indfo $(CAT) $(subst /,$$S,$$$(@:.bin=.ld65-err))) ifneq ($(wildcard ref/$1.ld65err-ref),) +ifndef QUIET @echo $(CAT) $$(@:.bin=.ld65-err) # FIXME: somehow this refuses to work in cmd.exe ifndef CMD_EXE $(call CAT,$$(@:.bin=.ld65-err)) -diff -u ref/$1.ld65err-ref $$(@:.bin=.ld65-err) endif - $(ISEQUAL) --wildcards ref/$1.ld65err-ref $$(@:.bin=.ld65-err) +endif + $(ISEQUAL) --wildcards ref/$1.ld65err-ref $$(@:.bin=.ld65-err) $(NULLERR) else ifneq ($(wildcard $(WORKDIR)/$1.ld65-err),) - $(ISEQUAL) --empty $$(@:.bin=.ld65-err) + $(ISEQUAL) --empty $$(@:.bin=.ld65-err) $(NULLERR) endif endif ifneq ($(wildcard ref/$1.ld65err2-ref),) +ifndef QUIET @echo $(CAT) $$(@:.bin=.ld65-err2) # FIXME: somehow this refuses to work in cmd.exe ifndef CMD_EXE $(call CAT,$$(@:.bin=.ld65-err2)) -diff -u ref/$1.ld65err2-ref $$(@:.bin=.ld65-err2) endif - $(ISEQUAL) --wildcards ref/$1.ld65err2-ref $$(@:.bin=.ld65-err2) +endif + $(ISEQUAL) --wildcards ref/$1.ld65err2-ref $$(@:.bin=.ld65-err2) $(NULLERR) else ifneq ($(wildcard $(WORKDIR)/$1.ld65-err2),) - $(ISEQUAL) --empty $$(@:.bin=.ld65-err2) + $(ISEQUAL) --empty $$(@:.bin=.ld65-err2) $(NULLERR) endif endif @@ -149,37 +158,37 @@ endif endif ifneq ($(wildcard ref/$1.err-ref),) - $(ISEQUAL) ref/$1.err-ref $$(@:.bin=.list-err) + $(ISEQUAL) ref/$1.err-ref $$(@:.bin=.list-err) $(NULLERR) else - $(ISEQUAL) --empty $$(@:.bin=.list-err) + $(ISEQUAL) --empty $$(@:.bin=.list-err) $(NULLERR) endif ifneq ($(wildcard ref/$1.ld65err-ref),) - $(ISEQUAL) --wildcards ref/$1.ld65err-ref $$(@:.bin=.list-ld65-err) + $(ISEQUAL) --wildcards ref/$1.ld65err-ref $$(@:.bin=.list-ld65-err) $(NULLERR) else ifneq ($(wildcard $(WORKDIR)/$1.list-ld65-err),) - $(ISEQUAL) --empty $$(@:.bin=.list-ld65-err) + $(ISEQUAL) --empty $$(@:.bin=.list-ld65-err) $(NULLERR) endif endif ifneq ($(wildcard ref/$1.err2-ref),) - $(ISEQUAL) ref/$1.err2-ref $$(@:.bin=.list-err2) + $(ISEQUAL) ref/$1.err2-ref $$(@:.bin=.list-err2) $(NULLERR) else - $(ISEQUAL) --empty $$(@:.bin=.list-err2) + $(ISEQUAL) --empty $$(@:.bin=.list-err2) $(NULLERR) endif ifneq ($(wildcard ref/$1.ld65err2-ref),) - $(ISEQUAL) --wildcards ref/$1.ld65err2-ref $$(@:.bin=.list-ld65-err2) + $(ISEQUAL) --wildcards ref/$1.ld65err2-ref $$(@:.bin=.list-ld65-err2) $(NULLERR) else ifneq ($(wildcard $(WORKDIR)/$1.list-ld65-err2),) - $(ISEQUAL) --empty $$(@:.bin=.list-ld65-err2) + $(ISEQUAL) --empty $$(@:.bin=.list-ld65-err2) $(NULLERR) endif endif # check if the result bin is the same as without listing file ifeq ($(wildcard control/$1.err),) ifeq ($(wildcard control/$1.err2),) - $(ISEQUAL) $$@ $$(@:.bin=.list-bin) + $(ISEQUAL) $$@ $$(@:.bin=.list-bin) $(NULLERR) endif endif @@ -187,7 +196,7 @@ ifneq ($(wildcard ref/$1.list-ref),) # we have a reference file, compare that, too # remove first line which contains a version number - $(ISEQUAL) --skip=1 ref/$1.list-ref $$(@:.bin=.list-lst) + $(ISEQUAL) --skip=1 ref/$1.list-ref $$(@:.bin=.list-lst) $(NULLERR) endif endef # LISTING_template diff --git a/test/asm/misc/Makefile b/test/asm/misc/Makefile index 1b2305cda..4f24aa041 100644 --- a/test/asm/misc/Makefile +++ b/test/asm/misc/Makefile @@ -30,6 +30,7 @@ ifdef QUIET .SILENT: NULLOUT = >$(NULLDEV) NULLERR = 2>$(NULLDEV) + CATERR = 2> $(WORKDIR)/$$@.errlog || (cat $(WORKDIR)/$$@.errlog && false) endif SIM65FLAGS = -x 200000000 diff --git a/test/asm/opcodes/Makefile b/test/asm/opcodes/Makefile index 70dd41c06..c0918499c 100644 --- a/test/asm/opcodes/Makefile +++ b/test/asm/opcodes/Makefile @@ -22,6 +22,9 @@ endif ifdef QUIET .SILENT: + NULLOUT = >$(NULLDEV) + NULLERR = 2>$(NULLDEV) + CATERR = 2> $(WORKDIR)/$$@.errlog || (cat $(WORKDIR)/$$@.errlog && false) endif CA65 := $(if $(wildcard ../../../bin/ca65*),../../../bin/ca65,ca65) diff --git a/test/asm/val/Makefile b/test/asm/val/Makefile index 08c000f95..fe27f97d1 100644 --- a/test/asm/val/Makefile +++ b/test/asm/val/Makefile @@ -51,8 +51,8 @@ define PRG_template $(WORKDIR)/%.$1.prg: %.s | $(WORKDIR) $(if $(QUIET),echo asm/val/$$*.$1.prg) - $(CA65) -t sim$1 -o $$(@:.prg=.o) $$< $(NULLERR) - $(LD65) -C sim6502-asmtest.cfg -o $$@ $$(@:.prg=.o) sim$1.lib $(NULLERR) + $(CA65) -t sim$1 -o $$(@:.prg=.o) $$< $(NULLOUT) $(NULLERR) + $(LD65) -C sim6502-asmtest.cfg -o $$@ $$(@:.prg=.o) sim$1.lib $(NULLOUT) $(NULLERR) $(SIM65) $(SIM65FLAGS) $$@ $(NULLOUT) endef # PRG_template diff --git a/test/dasm/Makefile b/test/dasm/Makefile index 29e97b9c1..9c19f575c 100644 --- a/test/dasm/Makefile +++ b/test/dasm/Makefile @@ -14,14 +14,19 @@ ifdef CMD_EXE EXE = .exe MKDIR = mkdir $(subst /,\,$1) RMDIR = -rmdir /q /s $(subst /,\,$1) + NULLDEV = nul: else EXE = MKDIR = mkdir -p $1 RMDIR = $(RM) -r $1 + NULLDEV = /dev/null endif ifdef QUIET .SILENT: + NULLOUT = >$(NULLDEV) + NULLERR = 2>$(NULLDEV) + CATERR = 2> $(WORKDIR)/$$@.errlog || (cat $(WORKDIR)/$$@.errlog && false) endif CL65 := $(if $(wildcard ../../bin/cl65*),../../bin/cl65,cl65) diff --git a/test/err/Makefile b/test/err/Makefile index a0cdc22ae..72b11cd1f 100644 --- a/test/err/Makefile +++ b/test/err/Makefile @@ -26,9 +26,12 @@ endif ifdef QUIET .SILENT: + NULLOUT = >$(NULLDEV) NULLERR = 2>$(NULLDEV) + CATERR = 2> $(WORKDIR)/$$@.errlog || (cat $(WORKDIR)/$$@.errlog && false) endif + CC65 := $(if $(wildcard ../../bin/cc65*),..$S..$Sbin$Scc65,cc65) WORKDIR = ../../testwrk/err @@ -45,7 +48,7 @@ $(WORKDIR): $(WORKDIR)/%.s: %.c | $(WORKDIR) $(if $(QUIET),echo err/$*.s) - $(NOT) $(CC65) -o $@ $< $(NULLERR) + $(NOT) $(CC65) -o $@ $< $(NULLOUT) $(CATERR) clean: @$(call RMDIR,$(WORKDIR)) diff --git a/test/misc/Makefile b/test/misc/Makefile index 989e8f83a..fb3730f5c 100644 --- a/test/misc/Makefile +++ b/test/misc/Makefile @@ -30,6 +30,7 @@ ifdef QUIET .SILENT: NULLOUT = >$(NULLDEV) NULLERR = 2>$(NULLDEV) + CATERR = 2> $(WORKDIR)/$$@.errlog || (cat $(WORKDIR)/$$@.errlog && false) endif SIM65FLAGS = -x 200000000 @@ -68,7 +69,7 @@ define PRG_template $(WORKDIR)/bug1209-ind-goto-rev.$1.$2.prg: bug1209-ind-goto-rev.c | $(WORKDIR) @echo "FIXME: " $$@ "currently does not compile." $(if $(QUIET),echo misc/bug1209-ind-goto-rev.$1.$2.prg) - $(CC65) -t sim$2 -$1 -o $$(@:.prg=.s) $$< $(NULLERR) + $(CC65) -t sim$2 -$1 -o $$(@:.prg=.s) $$< $(NULLOUT) $(CATERR) $(CA65) -t sim$2 -o $$(@:.prg=.o) $$(@:.prg=.s) $(NULLERR) $(NOT) $(LD65) -t sim$2 -o $$@ $$(@:.prg=.o) sim$2.lib $(NULLERR) @@ -76,7 +77,7 @@ $(WORKDIR)/bug1209-ind-goto-rev.$1.$2.prg: bug1209-ind-goto-rev.c | $(WORKDIR) $(WORKDIR)/bug1209-ind-goto-rev-2.$1.$2.prg: bug1209-ind-goto-rev-2.c | $(WORKDIR) @echo "FIXME: " $$@ "currently does not compile." $(if $(QUIET),echo misc/bug1209-ind-goto-rev-2.$1.$2.prg) - $(CC65) -t sim$2 -$1 -o $$(@:.prg=.s) $$< $(NULLERR) + $(CC65) -t sim$2 -$1 -o $$(@:.prg=.s) $$< $(NULLOUT) $(CATERR) $(CA65) -t sim$2 -o $$(@:.prg=.o) $$(@:.prg=.s) $(NULLERR) $(NOT) $(LD65) -t sim$2 -o $$@ $$(@:.prg=.o) sim$2.lib $(NULLERR) @@ -84,7 +85,7 @@ $(WORKDIR)/bug1209-ind-goto-rev-2.$1.$2.prg: bug1209-ind-goto-rev-2.c | $(WORKDI $(WORKDIR)/bug1209-ind-goto-rev-3.$1.$2.prg: bug1209-ind-goto-rev-3.c | $(WORKDIR) @echo "FIXME: " $$@ "currently does not compile." $(if $(QUIET),echo misc/bug1209-ind-goto-rev-3.$1.$2.prg) - $(CC65) -t sim$2 -$1 -o $$(@:.prg=.s) $$< $(NULLERR) + $(CC65) -t sim$2 -$1 -o $$(@:.prg=.s) $$< $(NULLOUT) $(CATERR) $(CA65) -t sim$2 -o $$(@:.prg=.o) $$(@:.prg=.s) $(NULLERR) $(NOT) $(LD65) -t sim$2 -o $$@ $$(@:.prg=.o) sim$2.lib $(NULLERR) @@ -92,40 +93,40 @@ $(WORKDIR)/bug1209-ind-goto-rev-3.$1.$2.prg: bug1209-ind-goto-rev-3.c | $(WORKDI $(WORKDIR)/pptest2.$1.$2.prg: pptest2.c | $(WORKDIR) @echo "FIXME: " $$@ "currently does not compile." $(if $(QUIET),echo misc/pptest2.$1.$2.prg) - $(NOT) $(CC65) -t sim$2 -$1 -o $$@ $$< $(NULLERR) + $(NOT) $(CC65) -t sim$2 -$1 -o $$@ $$< $(NULLOUT) $(CATERR) # should compile, but compiler exits with internal error $(WORKDIR)/bug1211-ice-move-refs-2.$1.$2.prg: bug1211-ice-move-refs-2.c | $(WORKDIR) @echo "FIXME: " $$@ "currently does not compile." $(if $(QUIET),echo misc/bug1211-ice-move-refs-2.$1.$2.prg) - $(NOT) $(CC65) -t sim$2 -$1 -o $$@ $$< $(NULLERR) + $(NOT) $(CC65) -t sim$2 -$1 -o $$@ $$< $(NULLOUT) $(CATERR) # this one requires --std=c89, it fails with --std=c99 $(WORKDIR)/bug1265.$1.$2.prg: bug1265.c | $(WORKDIR) $(if $(QUIET),echo misc/bug1265.$1.$2.prg) - $(CC65) --standard c89 -t sim$2 -$1 -o $$(@:.prg=.s) $$< $(NULLERR) + $(CC65) --standard c89 -t sim$2 -$1 -o $$(@:.prg=.s) $$< $(NULLOUT) $(CATERR) $(CA65) -t sim$2 -o $$(@:.prg=.o) $$(@:.prg=.s) $(NULLERR) $(LD65) -t sim$2 -o $$@ $$(@:.prg=.o) sim$2.lib $(NULLERR) $(SIM65) $(SIM65FLAGS) $$@ $(NULLOUT) $(NULLERR) # should not compile, but gives different diagnostics in C99 mode than in others -$(WORKDIR)/bug2515.$1.$2.prg: bug2515.c | $(WORKDIR) +$(WORKDIR)/bug2515.$1.$2.prg: bug2515.c $(ISEQUAL) | $(WORKDIR) $(if $(QUIET),echo misc/bug2515.$1.$2.prg) - $(NOT) $(CC65) --standard c99 -t sim$2 -$1 -o $$(@:.prg=.s) $$< 2>$(WORKDIR)/bug2515.$1.$2.out + $(NOT) $(CC65) --standard c99 -t sim$2 -$1 -o $$(@:.prg=.s) $$< $(NULLOUT) 2>$(WORKDIR)/bug2515.$1.$2.out $(ISEQUAL) $(WORKDIR)/bug2515.$1.$2.out bug2515.c99.ref - $(NOT) $(CC65) -t sim$2 -$1 -o $$(@:.prg=.s) $$< 2>$(WORKDIR)/bug2515.$1.$2.out + $(NOT) $(CC65) -t sim$2 -$1 -o $$(@:.prg=.s) $$< $(NULLOUT) 2>$(WORKDIR)/bug2515.$1.$2.out $(ISEQUAL) $(WORKDIR)/bug2515.$1.$2.out bug2515.ref # should not issue any warnings in C99 mode -$(WORKDIR)/bug2637.$1.$2.prg: bug2637.c | $(WORKDIR) +$(WORKDIR)/bug2637.$1.$2.prg: bug2637.c $(ISEQUAL) | $(WORKDIR) $(if $(QUIET),echo misc/bug2637.$1.$2.prg) - $(CC65) --standard c99 -t sim$2 -$1 -o $$(@:.prg=.s) $$< 2>$(WORKDIR)/bug2637.$1.$2.out + $(CC65) --standard c99 -t sim$2 -$1 -o $$(@:.prg=.s) $$< $(NULLOUT) 2>$(WORKDIR)/bug2637.$1.$2.out $(ISEQUAL) $(WORKDIR)/bug2637.$1.$2.out bug2637.ref # this one requires -Werror $(WORKDIR)/bug1768.$1.$2.prg: bug1768.c | $(WORKDIR) $(if $(QUIET),echo misc/bug1768.$1.$2.prg) - $(CC65) -Werror -t sim$2 -$1 -o $$(@:.prg=.s) $$< $(NULLERR) + $(CC65) -Werror -t sim$2 -$1 -o $$(@:.prg=.s) $$< $(NULLOUT) $(CATERR) $(CA65) -t sim$2 -o $$(@:.prg=.o) $$(@:.prg=.s) $(NULLERR) $(LD65) -t sim$2 -o $$@ $$(@:.prg=.o) sim$2.lib $(NULLERR) $(SIM65) $(SIM65FLAGS) $$@ $(NULLOUT) $(NULLERR) @@ -133,7 +134,7 @@ $(WORKDIR)/bug1768.$1.$2.prg: bug1768.c | $(WORKDIR) # should compile, but then hangs in an endless loop $(WORKDIR)/endless.$1.$2.prg: endless.c | $(WORKDIR) $(if $(QUIET),echo misc/endless.$1.$2.prg) - $(CC65) -t sim$2 -$1 -o $$(@:.prg=.s) $$< $(NULLERR) + $(CC65) -t sim$2 -$1 -o $$(@:.prg=.s) $$< $(NULLOUT) $(CATERR) $(CA65) -t sim$2 -o $$(@:.prg=.o) $$(@:.prg=.s) $(NULLERR) $(LD65) -t sim$2 -o $$@ $$(@:.prg=.o) sim$2.lib $(NULLERR) $(NOT) $(SIM65) $(SIM65FLAGS) $$@ $(NULLOUT) $(NULLERR) @@ -142,12 +143,12 @@ $(WORKDIR)/endless.$1.$2.prg: endless.c | $(WORKDIR) # in a useful way $(WORKDIR)/bug2655.$1.$2.prg: bug2655.c $(ISEQUAL) | $(WORKDIR) $(if $(QUIET),echo misc/bug2655.$1.$2.prg) - $(CC65) -t sim$2 -$1 -o $$@ $$< 2>$(WORKDIR)/bug2655.$1.$2.out + $(CC65) -t sim$2 -$1 -o $$@ $$< $(NULLOUT) 2>$(WORKDIR)/bug2655.$1.$2.out $(ISEQUAL) $(WORKDIR)/bug2655.$1.$2.out bug2655.ref $(WORKDIR)/limits.$1.$2.prg: limits.c $(ISEQUAL) | $(WORKDIR) $(if $(QUIET),echo misc/limits.$1.$2.prg) - $(CC65) -t sim$2 -$1 -o $$(@:.prg=.s) $$< $(NULLERR) + $(CC65) -t sim$2 -$1 -o $$(@:.prg=.s) $$< $(NULLOUT) $(CATERR) $(CA65) -t sim$2 -o $$(@:.prg=.o) $$(@:.prg=.s) $(NULLERR) $(LD65) -t sim$2 -o $$@ $$(@:.prg=.o) sim$2.lib $(NULLERR) $(SIM65) $(SIM65FLAGS) $$@ > $(WORKDIR)/limits.$1.$2.out @@ -155,24 +156,24 @@ $(WORKDIR)/limits.$1.$2.prg: limits.c $(ISEQUAL) | $(WORKDIR) $(WORKDIR)/goto.$1.$2.prg: goto.c $(ISEQUAL) | $(WORKDIR) $(if $(QUIET),echo misc/goto.$1.$2.prg) - $(CC65) -t sim$2 -$1 -o $$@ $$< 2>$(WORKDIR)/goto.$1.$2.out + $(CC65) -t sim$2 -$1 -o $$@ $$< $(NULLOUT) 2>$(WORKDIR)/goto.$1.$2.out $(ISEQUAL) $(WORKDIR)/goto.$1.$2.out goto.ref # this one requires failure with --std=c89, it fails with --std=cc65 due to # stricter checks $(WORKDIR)/bug2304-implicit-func.$1.$2.prg: bug2304-implicit-func.c | $(WORKDIR) $(if $(QUIET),echo misc/bug2304-implicit-func.$1.$2.prg) - $(NOT) $(CC65) --standard c89 -t sim$2 -$1 -o $$@ $$< $(NULLERR) + $(NOT) $(CC65) --standard c89 -t sim$2 -$1 -o $$@ $$< $(NULLOUT) $(CATERR) # should not compile until 3-byte struct by value tests are re-enabled $(WORKDIR)/struct-by-value.$1.$2.prg: struct-by-value.c | $(WORKDIR) $(if $(QUIET),echo misc/struct-by-value.$1.$2.prg) - $(NOT) $(CC65) -t sim$2 -$1 -o $$@ $$< $(NULLERR) + $(NOT) $(CC65) -t sim$2 -$1 -o $$@ $$< $(NULLOUT) $(CATERR) # the rest are tests that fail currently for one reason or another $(WORKDIR)/sitest.$1.$2.prg: sitest.c | $(WORKDIR) @echo "FIXME: " $$@ "currently does not compile." - $(NOT) $(CC65) -t sim$2 -$1 -o $$@ $$< $(NULLERR) + $(NOT) $(CC65) -t sim$2 -$1 -o $$@ $$< $(NULLOUT) $(CATERR) # $(SIM65) $(SIM65FLAGS) $$@ $(NULLOUT) endef # PRG_template diff --git a/test/ref/Makefile b/test/ref/Makefile index 2dadf5bcc..4ac8f02a4 100644 --- a/test/ref/Makefile +++ b/test/ref/Makefile @@ -29,7 +29,9 @@ endif ifdef QUIET .SILENT: + NULLOUT = >$(NULLDEV) NULLERR = 2>$(NULLDEV) + CATERR = 2> $(WORKDIR)/$$@.errlog || (cat $(WORKDIR)/$$@.errlog && false) endif SIM65FLAGS = -x 200000000 diff --git a/test/standard/Makefile b/test/standard/Makefile index e359fa975..c58fdc070 100644 --- a/test/standard/Makefile +++ b/test/standard/Makefile @@ -26,6 +26,7 @@ ifdef QUIET .SILENT: NULLOUT = >$(NULLDEV) NULLERR = 2>$(NULLDEV) + CATERR = 2> $(WORKDIR)/$$@.errlog || (cat $(WORKDIR)/$$@.errlog && false) endif SIM65FLAGS = -x 4000000000 -c diff --git a/test/standard_err/Makefile b/test/standard_err/Makefile index f554d33eb..53d4efafd 100644 --- a/test/standard_err/Makefile +++ b/test/standard_err/Makefile @@ -26,9 +26,12 @@ endif ifdef QUIET .SILENT: + NULLOUT = >$(NULLDEV) NULLERR = 2>$(NULLDEV) + CATERR = 2> $(WORKDIR)/$$@.errlog || (cat $(WORKDIR)/$$@.errlog && false) endif + CC65 := $(if $(wildcard ../../bin/cc65*),..$S..$Sbin$Scc65,cc65) WORKDIR = ../../testwrk/standard_err @@ -49,7 +52,7 @@ define PRG_template $(WORKDIR)/%.$1.$2.prg: %.c | $(WORKDIR) $(if $(QUIET),echo standard_err/$$*.$1.$2.prg) - $(NOT) $(CC65) -t sim$2 $$(CC65FLAGS) -Osir --add-source --standard $1 -o $$(@:.prg=.s) $$< $(NULLERR) + $(NOT) $(CC65) -t sim$2 $$(CC65FLAGS) -Osir --add-source --standard $1 -o $$(@:.prg=.s) $$< $(NULLOUT) $(CATERR) endef # PRG_template diff --git a/test/todo/Makefile b/test/todo/Makefile index ec14cf8d4..338ffb978 100644 --- a/test/todo/Makefile +++ b/test/todo/Makefile @@ -28,8 +28,10 @@ ifdef QUIET .SILENT: NULLOUT = >$(NULLDEV) NULLERR = 2>$(NULLDEV) + CATERR = 2> $(WORKDIR)/$$@.errlog || (cat $(WORKDIR)/$$@.errlog && false) endif + SIM65FLAGS = -x 200000000 CC65 := $(if $(wildcard ../../bin/cc65*),..$S..$Sbin$Scc65,cc65) diff --git a/test/val/Makefile b/test/val/Makefile index 68882971d..58c08d4f8 100644 --- a/test/val/Makefile +++ b/test/val/Makefile @@ -28,6 +28,7 @@ ifdef QUIET .SILENT: NULLOUT = >$(NULLDEV) NULLERR = 2>$(NULLDEV) + CATERR = 2> $(WORKDIR)/$$@.errlog || (cat $(WORKDIR)/$$@.errlog && false) endif SIM65FLAGS = -x 4000000000 -c @@ -56,10 +57,10 @@ define PRG_template $(WORKDIR)/%.$1.$2.prg: %.c | $(WORKDIR) $(if $(QUIET),echo val/$$*.$1.$2.prg) - $(CC65) -t sim$2 $$(CC65FLAGS) --add-source -$1 -o $$(@:.prg=.s) $$< $(NULLERR) - $(CA65) -t sim$2 -o $$(@:.prg=.o) $$(@:.prg=.s) $(NULLERR) - $(LD65) -t sim$2 -o $$@ $$(@:.prg=.o) sim$2.lib $(NULLERR) - $(SIM65) $(SIM65FLAGS) $$@ > $(WORKDIR)/$$@.out $(CATRES) + $(CC65) -t sim$2 $$(CC65FLAGS) --add-source -$1 -o $$(@:.prg=.s) $$< $(NULLOUT) $(CATERR) + $(CA65) -t sim$2 -o $$(@:.prg=.o) $$(@:.prg=.s) $(NULLOUT) $(CATERR) + $(LD65) -t sim$2 -o $$@ $$(@:.prg=.o) sim$2.lib $(NULLOUT) $(CATERR) + $(SIM65) $(SIM65FLAGS) $$@ > $(WORKDIR)/$$@.out 2> $(WORKDIR)/$$@.out $(CATRES) endef # PRG_template From afe395e9705e06f9fe6f56abeed9f9f3a4d021f3 Mon Sep 17 00:00:00 2001 From: mrdudz Date: Thu, 26 Jun 2025 20:15:28 +0200 Subject: [PATCH 05/16] fix -s vs QUIET in testtarget --- targettest/Makefile | 16 ++++++++++++++-- targettest/accelerator/Makefile | 16 ++++++++++++++++ targettest/atari/Makefile | 17 +++++++++++++++++ targettest/cbm/Makefile | 11 +++++++++++ targettest/gamate/Makefile | 11 +++++++++++ targettest/pce/Makefile | 11 +++++++++++ 6 files changed, 80 insertions(+), 2 deletions(-) diff --git a/targettest/Makefile b/targettest/Makefile index 56b5df446..edddca0f2 100644 --- a/targettest/Makefile +++ b/targettest/Makefile @@ -47,6 +47,16 @@ else LD := $(if $(wildcard ../bin/ld65*),../bin/ld65,ld65) endif +ifeq ($(SILENT),s) + QUIET = 1 +endif + +ifdef QUIET + .SILENT: + PQ = "QUIET=1" + PD = --no-print-directory +endif + ifneq ($(filter disk testcode.%,$(MAKECMDGOALS)),) ifdef CC65_HOME TARGET_PATH = $(CC65_HOME)/target @@ -120,10 +130,12 @@ DISK_atarixl = testcode.atr %: %.s .c.o: + $(if $(QUIET),echo targettest/$*.c) $(CC) $(CFLAGS) -Ors --codesize 500 -T -g -t $(SYS) $< $(AS) $(<:.c=.s) .s.o: + $(if $(QUIET),echo targettest/$*.s) $(AS) $(ASFLAGS) -t $(SYS) $< .PRECIOUS: %.o @@ -721,7 +733,7 @@ endif define SUBDIR_recipe -@+$(MAKE) -C $(dir) --no-print-directory $@ +@+$(MAKE) -C $(dir) $(PD) $@ $(PQ) endef # SUBDIR_recipe @@ -783,7 +795,7 @@ define TARGET_recipe @echo making targettest for: $(T) @$(MAKE) -j2 SYS:=$(T) -@$(MAKE) --no-print-directory clean SYS:=$(T) +@$(MAKE) $(PD) clean SYS:=$(T) endef # TARGET_recipe diff --git a/targettest/accelerator/Makefile b/targettest/accelerator/Makefile index 6e710d010..0a6a9bb02 100644 --- a/targettest/accelerator/Makefile +++ b/targettest/accelerator/Makefile @@ -36,6 +36,14 @@ else LD := $(if $(wildcard ../../bin/ld65*),../../bin/ld65,ld65) endif +ifeq ($(SILENT),s) + QUIET = 1 +endif + +ifdef QUIET + .SILENT: +endif + EXELIST_c64 = \ c64-scpu-test.prg \ c64dtv-test.prg \ @@ -64,27 +72,35 @@ else endif c64-scpu-test.prg: c64-c128-scpu-test.c + $(if $(QUIET),echo $@) $(CL) -t c64 c64-c128-scpu-test.c -o c64-scpu-test.prg c128-scpu-test.prg: c64-c128-scpu-test.c + $(if $(QUIET),echo $@) $(CL) -t c128 c64-c128-scpu-test.c -o c128-scpu-test.prg c64dtv-test.prg: c64dtv-test.c + $(if $(QUIET),echo $@) $(CL) -t c64 c64dtv-test.c -o c64dtv-test.prg c64-test.prg: c64-c128-test.c + $(if $(QUIET),echo $@) $(CL) -t c64 c64-c128-test.c -o c64-test.prg c128-test.prg: c64-c128-test.c + $(if $(QUIET),echo $@) $(CL) -t c128 c64-c128-test.c -o c128-test.prg chameleon-test.prg: chameleon-test.c + $(if $(QUIET),echo $@) $(CL) -t c64 chameleon-test.c -o chameleon-test.prg c65-test.prg: c65-test.c + $(if $(QUIET),echo $@) $(CL) -t c64 c65-test.c -o c65-test.prg turbomaster-test.prg: turbomaster-test.c + $(if $(QUIET),echo $@) $(CL) -t c64 turbomaster-test.c -o turbomaster-test.prg clean: diff --git a/targettest/atari/Makefile b/targettest/atari/Makefile index 0e376e9bc..ef8d1883c 100644 --- a/targettest/atari/Makefile +++ b/targettest/atari/Makefile @@ -37,6 +37,14 @@ else LD := $(if $(wildcard ../../bin/ld65*),../../bin/ld65,ld65) endif +ifeq ($(SILENT),s) + QUIET = 1 +endif + +ifdef QUIET + .SILENT: +endif + EXELIST_atari = \ charmapping.xex \ defdev.xex \ @@ -64,24 +72,33 @@ else endif charmapping.xex: charmapping.c + $(if $(QUIET),echo $@) $(CL) -t atari -o charmapping.xex charmapping.c defdev.xex: defdev.c + $(if $(QUIET),echo $@) $(CL) -t atari -o defdev.xex defdev.c displaylist.xex: displaylist.c + $(if $(QUIET),echo $@) $(CL) -t atari -o displaylist.xex displaylist.c mem.xex: mem.c ../getsp.s + $(if $(QUIET),echo $@) $(CL) -t atari -o mem.xex mem.c ../getsp.s multi.xex: multi-xex.s multi-xex.cfg + $(if $(QUIET),echo $@) $(CL) -t atari -C multi-xex.cfg multi-xex.s -o multi.xex ostype.xex: ostype.c + $(if $(QUIET),echo $@) $(CL) -t atari -o ostype.xex ostype.c scrcode.com: scrcode.s + $(if $(QUIET),echo $@) # ca65 -t atari -o scrcode.o scrcode.s # ld65 -C atari-asm.cfg -o scrcode.com scrcode.o $(CL) -t atari -C atari-asm.cfg -o scrcode.com scrcode.s sys.xex: sys.c + $(if $(QUIET),echo $@) $(CL) -t atari -o sys.xex sys.c sound.xex: sound.c + $(if $(QUIET),echo $@) $(CL) -t atari -o sound.xex sound.c clean: @$(DEL) charmapping.xex 2>$(NULLDEV) diff --git a/targettest/cbm/Makefile b/targettest/cbm/Makefile index ebe00198f..96acf49a0 100644 --- a/targettest/cbm/Makefile +++ b/targettest/cbm/Makefile @@ -40,6 +40,14 @@ else LD := $(if $(wildcard ../../bin/ld65*),../../bin/ld65,ld65) endif +ifeq ($(SILENT),s) + QUIET = 1 +endif + +ifdef QUIET + .SILENT: +endif + EXELIST_c64 = \ petscii.prg \ cbmdir-test.prg \ @@ -73,12 +81,14 @@ endif ifeq ($(SYS),c64) petscii.prg: petscii.c + $(if $(QUIET),echo $@) $(CL) -t $(SYS) -O -o petscii.prg petscii.c else petscii.prg: endif cbmdir-test.prg: cbmdir-test.c + $(if $(QUIET),echo $@) ifeq ($(SYS),vic20) $(CL) -t $(SYS) -C vic20-32k.cfg -Oris -o $@ $< else @@ -86,6 +96,7 @@ else endif cbmread.prg: cbmread.c + $(if $(QUIET),echo $@) ifeq ($(SYS),vic20) $(CL) -t $(SYS) -C vic20-32k.cfg -Oris -o $@ $< else diff --git a/targettest/gamate/Makefile b/targettest/gamate/Makefile index f03c2b064..3e3d1f9d8 100644 --- a/targettest/gamate/Makefile +++ b/targettest/gamate/Makefile @@ -37,6 +37,14 @@ else LD := $(if $(wildcard ../../bin/ld65*),../../bin/ld65,ld65) endif +ifeq ($(SILENT),s) + QUIET = 1 +endif + +ifdef QUIET + .SILENT: +endif + EXELIST_gamate = \ audiotest.bin lcdtest.bin ctest.bin @@ -56,10 +64,13 @@ else endif audiotest.bin: audiotest.s + $(if $(QUIET),echo $@) $(CL) -l audiotest.lst -t gamate -o audiotest.bin audiotest.s lcdtest.bin: lcdtest.s + $(if $(QUIET),echo $@) $(CL) -l lcdtest.lst -t gamate -o lcdtest.bin lcdtest.s ctest.bin: ctest.c + $(if $(QUIET),echo $@) $(CL) -l ctest.lst -t gamate -o ctest.bin ctest.c clean: diff --git a/targettest/pce/Makefile b/targettest/pce/Makefile index 549720a40..2a0be84d5 100644 --- a/targettest/pce/Makefile +++ b/targettest/pce/Makefile @@ -37,6 +37,14 @@ else LD := $(if $(wildcard ../../bin/ld65*),../../bin/ld65,ld65) endif +ifeq ($(SILENT),s) + QUIET = 1 +endif + +ifdef QUIET + .SILENT: +endif + .PHONY: all clean test # Size of cartridge to generate. @@ -71,8 +79,11 @@ else endif %.bin: %.c + $(if $(QUIET),echo $@) $(CL) -t pce $< -Wl -D__CARTSIZE__=${CARTSIZE} -m $*.map -o $@ +ifndef QUIET @echo "use 'make conio.pce' to produce a .pce file using dd" +endif %.pce: %.bin dd if=$< bs=8K skip=${COUNT} > $@ From 70f9723a893a1b51c66ac427c225c97ea0bd5720 Mon Sep 17 00:00:00 2001 From: mrdudz Date: Thu, 26 Jun 2025 20:42:15 +0200 Subject: [PATCH 06/16] dumb down for cmd.exe --- test/asm/cpudetect/Makefile | 2 ++ test/asm/err/Makefile | 2 ++ test/asm/listing/Makefile | 2 ++ test/asm/misc/Makefile | 2 ++ test/asm/opcodes/Makefile | 2 ++ test/dasm/Makefile | 2 ++ test/err/Makefile | 2 ++ test/misc/Makefile | 2 ++ test/ref/Makefile | 2 ++ test/standard/Makefile | 2 ++ test/standard_err/Makefile | 2 ++ test/todo/Makefile | 2 ++ test/val/Makefile | 2 ++ 13 files changed, 26 insertions(+) diff --git a/test/asm/cpudetect/Makefile b/test/asm/cpudetect/Makefile index a77e5b576..d0077bfd9 100644 --- a/test/asm/cpudetect/Makefile +++ b/test/asm/cpudetect/Makefile @@ -25,8 +25,10 @@ ifdef QUIET .SILENT: NULLOUT = >$(NULLDEV) NULLERR = 2>$(NULLDEV) +ifndef CMD_EXE CATERR = 2> $(WORKDIR)/$$@.errlog || (cat $(WORKDIR)/$$@.errlog && false) endif +endif CA65 := $(if $(wildcard ../../../bin/ca65*),../../../bin/ca65,ca65) LD65 := $(if $(wildcard ../../../bin/ld65*),../../../bin/ld65,ld65) diff --git a/test/asm/err/Makefile b/test/asm/err/Makefile index 5c329138b..8b93cd80d 100644 --- a/test/asm/err/Makefile +++ b/test/asm/err/Makefile @@ -28,8 +28,10 @@ ifdef QUIET .SILENT: NULLOUT = >$(NULLDEV) NULLERR = 2>$(NULLDEV) +ifndef CMD_EXE CATERR = 2> $(WORKDIR)/$$@.errlog || (cat $(WORKDIR)/$$@.errlog && false) endif +endif CA65 := $(if $(wildcard ../../../bin/ca65*),..$S..$S..$Sbin$Sca65,ca65) diff --git a/test/asm/listing/Makefile b/test/asm/listing/Makefile index 9d815985d..dc2c43d73 100644 --- a/test/asm/listing/Makefile +++ b/test/asm/listing/Makefile @@ -32,8 +32,10 @@ ifdef QUIET .SILENT: NULLOUT = >$(NULLDEV) NULLERR = 2>$(NULLDEV) +ifndef CMD_EXE CATERR = 2> $(WORKDIR)/$$@.errlog || (cat $(WORKDIR)/$$@.errlog && false) endif +endif CA65 := $(if $(wildcard ../../../bin/ca65*),..$S..$S..$Sbin$Sca65,ca65) LD65 := $(if $(wildcard ../../../bin/ld65*),..$S..$S..$Sbin$Sld65,ld65) diff --git a/test/asm/misc/Makefile b/test/asm/misc/Makefile index 4f24aa041..3072fa24e 100644 --- a/test/asm/misc/Makefile +++ b/test/asm/misc/Makefile @@ -30,8 +30,10 @@ ifdef QUIET .SILENT: NULLOUT = >$(NULLDEV) NULLERR = 2>$(NULLDEV) +ifndef CMD_EXE CATERR = 2> $(WORKDIR)/$$@.errlog || (cat $(WORKDIR)/$$@.errlog && false) endif +endif SIM65FLAGS = -x 200000000 diff --git a/test/asm/opcodes/Makefile b/test/asm/opcodes/Makefile index c0918499c..2fe046bd9 100644 --- a/test/asm/opcodes/Makefile +++ b/test/asm/opcodes/Makefile @@ -24,8 +24,10 @@ ifdef QUIET .SILENT: NULLOUT = >$(NULLDEV) NULLERR = 2>$(NULLDEV) +ifndef CMD_EXE CATERR = 2> $(WORKDIR)/$$@.errlog || (cat $(WORKDIR)/$$@.errlog && false) endif +endif CA65 := $(if $(wildcard ../../../bin/ca65*),../../../bin/ca65,ca65) LD65 := $(if $(wildcard ../../../bin/ld65*),../../../bin/ld65,ld65) diff --git a/test/dasm/Makefile b/test/dasm/Makefile index 9c19f575c..196975857 100644 --- a/test/dasm/Makefile +++ b/test/dasm/Makefile @@ -26,8 +26,10 @@ ifdef QUIET .SILENT: NULLOUT = >$(NULLDEV) NULLERR = 2>$(NULLDEV) +ifndef CMD_EXE CATERR = 2> $(WORKDIR)/$$@.errlog || (cat $(WORKDIR)/$$@.errlog && false) endif +endif CL65 := $(if $(wildcard ../../bin/cl65*),../../bin/cl65,cl65) CA65 := $(if $(wildcard ../../bin/ca65*),../../bin/ca65,ca65) diff --git a/test/err/Makefile b/test/err/Makefile index 72b11cd1f..5bd198477 100644 --- a/test/err/Makefile +++ b/test/err/Makefile @@ -28,8 +28,10 @@ ifdef QUIET .SILENT: NULLOUT = >$(NULLDEV) NULLERR = 2>$(NULLDEV) +ifndef CMD_EXE CATERR = 2> $(WORKDIR)/$$@.errlog || (cat $(WORKDIR)/$$@.errlog && false) endif +endif CC65 := $(if $(wildcard ../../bin/cc65*),..$S..$Sbin$Scc65,cc65) diff --git a/test/misc/Makefile b/test/misc/Makefile index fb3730f5c..8eb360e52 100644 --- a/test/misc/Makefile +++ b/test/misc/Makefile @@ -30,8 +30,10 @@ ifdef QUIET .SILENT: NULLOUT = >$(NULLDEV) NULLERR = 2>$(NULLDEV) +ifndef CMD_EXE CATERR = 2> $(WORKDIR)/$$@.errlog || (cat $(WORKDIR)/$$@.errlog && false) endif +endif SIM65FLAGS = -x 200000000 diff --git a/test/ref/Makefile b/test/ref/Makefile index 4ac8f02a4..1a5611083 100644 --- a/test/ref/Makefile +++ b/test/ref/Makefile @@ -31,8 +31,10 @@ ifdef QUIET .SILENT: NULLOUT = >$(NULLDEV) NULLERR = 2>$(NULLDEV) +ifndef CMD_EXE CATERR = 2> $(WORKDIR)/$$@.errlog || (cat $(WORKDIR)/$$@.errlog && false) endif +endif SIM65FLAGS = -x 200000000 diff --git a/test/standard/Makefile b/test/standard/Makefile index c58fdc070..f09024b58 100644 --- a/test/standard/Makefile +++ b/test/standard/Makefile @@ -26,8 +26,10 @@ ifdef QUIET .SILENT: NULLOUT = >$(NULLDEV) NULLERR = 2>$(NULLDEV) +ifndef CMD_EXE CATERR = 2> $(WORKDIR)/$$@.errlog || (cat $(WORKDIR)/$$@.errlog && false) endif +endif SIM65FLAGS = -x 4000000000 -c diff --git a/test/standard_err/Makefile b/test/standard_err/Makefile index 53d4efafd..702ad3f95 100644 --- a/test/standard_err/Makefile +++ b/test/standard_err/Makefile @@ -28,8 +28,10 @@ ifdef QUIET .SILENT: NULLOUT = >$(NULLDEV) NULLERR = 2>$(NULLDEV) +ifndef CMD_EXE CATERR = 2> $(WORKDIR)/$$@.errlog || (cat $(WORKDIR)/$$@.errlog && false) endif +endif CC65 := $(if $(wildcard ../../bin/cc65*),..$S..$Sbin$Scc65,cc65) diff --git a/test/todo/Makefile b/test/todo/Makefile index 338ffb978..7a0cbfa54 100644 --- a/test/todo/Makefile +++ b/test/todo/Makefile @@ -28,8 +28,10 @@ ifdef QUIET .SILENT: NULLOUT = >$(NULLDEV) NULLERR = 2>$(NULLDEV) +ifndef CMD_EXE CATERR = 2> $(WORKDIR)/$$@.errlog || (cat $(WORKDIR)/$$@.errlog && false) endif +endif SIM65FLAGS = -x 200000000 diff --git a/test/val/Makefile b/test/val/Makefile index 58c08d4f8..fe895e217 100644 --- a/test/val/Makefile +++ b/test/val/Makefile @@ -28,8 +28,10 @@ ifdef QUIET .SILENT: NULLOUT = >$(NULLDEV) NULLERR = 2>$(NULLDEV) +ifndef CMD_EXE CATERR = 2> $(WORKDIR)/$$@.errlog || (cat $(WORKDIR)/$$@.errlog && false) endif +endif SIM65FLAGS = -x 4000000000 -c From 46770bbb63511a3fad82ab8cd398a56d4d8756c0 Mon Sep 17 00:00:00 2001 From: mrdudz Date: Thu, 26 Jun 2025 20:53:10 +0200 Subject: [PATCH 07/16] another for cmd.exe --- test/val/Makefile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/test/val/Makefile b/test/val/Makefile index fe895e217..34ddff067 100644 --- a/test/val/Makefile +++ b/test/val/Makefile @@ -21,7 +21,7 @@ else NULLDEV = /dev/null MKDIR = mkdir -p $1 RMDIR = $(RM) -r $1 - CATRES = || (cat $(WORKDIR)/$$@.out && false) + CATRES = $$@ > $(WORKDIR)/$$@.out 2> $(WORKDIR)/$$@.out || (cat $(WORKDIR)/$$@.out && false) endif ifdef QUIET @@ -62,7 +62,7 @@ $(WORKDIR)/%.$1.$2.prg: %.c | $(WORKDIR) $(CC65) -t sim$2 $$(CC65FLAGS) --add-source -$1 -o $$(@:.prg=.s) $$< $(NULLOUT) $(CATERR) $(CA65) -t sim$2 -o $$(@:.prg=.o) $$(@:.prg=.s) $(NULLOUT) $(CATERR) $(LD65) -t sim$2 -o $$@ $$(@:.prg=.o) sim$2.lib $(NULLOUT) $(CATERR) - $(SIM65) $(SIM65FLAGS) $$@ > $(WORKDIR)/$$@.out 2> $(WORKDIR)/$$@.out $(CATRES) + $(SIM65) $(SIM65FLAGS) $(CATRES) endef # PRG_template From cc6813428c83418f293a48f5a962aacf250ce844 Mon Sep 17 00:00:00 2001 From: mrdudz Date: Thu, 26 Jun 2025 21:00:20 +0200 Subject: [PATCH 08/16] fix the fix --- test/val/Makefile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/test/val/Makefile b/test/val/Makefile index 34ddff067..1f6f0ba4c 100644 --- a/test/val/Makefile +++ b/test/val/Makefile @@ -21,7 +21,7 @@ else NULLDEV = /dev/null MKDIR = mkdir -p $1 RMDIR = $(RM) -r $1 - CATRES = $$@ > $(WORKDIR)/$$@.out 2> $(WORKDIR)/$$@.out || (cat $(WORKDIR)/$$@.out && false) + CATRES = > $(WORKDIR)/$$@.out 2> $(WORKDIR)/$$@.out || (cat $(WORKDIR)/$$@.out && false) endif ifdef QUIET @@ -62,7 +62,7 @@ $(WORKDIR)/%.$1.$2.prg: %.c | $(WORKDIR) $(CC65) -t sim$2 $$(CC65FLAGS) --add-source -$1 -o $$(@:.prg=.s) $$< $(NULLOUT) $(CATERR) $(CA65) -t sim$2 -o $$(@:.prg=.o) $$(@:.prg=.s) $(NULLOUT) $(CATERR) $(LD65) -t sim$2 -o $$@ $$(@:.prg=.o) sim$2.lib $(NULLOUT) $(CATERR) - $(SIM65) $(SIM65FLAGS) $(CATRES) + $(SIM65) $(SIM65FLAGS) $$@ $(CATRES) endef # PRG_template From fed7276a631e20a39e44f031ebed12663e9b8f81 Mon Sep 17 00:00:00 2001 From: mrdudz Date: Thu, 26 Jun 2025 22:16:08 +0200 Subject: [PATCH 09/16] make makefiles in samples behave the same as the others --- samples/Makefile | 27 +++++++++++++++++++++++---- samples/apple2/Makefile | 13 +++++++++++++ samples/atari2600/Makefile | 9 +++++++++ samples/atari5200/Makefile | 9 +++++++++ samples/cbm/Makefile | 13 +++++++++++++ samples/disasm/Makefile | 9 +++++++++ samples/gamate/Makefile | 9 +++++++++ samples/geos/Makefile | 27 +++++++++++++++++++++++++-- samples/geos/grc/Makefile | 10 ++++++++++ samples/kim1/Makefile | 19 +++++++++++++++++++ samples/lynx/Makefile | 9 +++++++++ samples/sim65/Makefile | 9 +++++++++ samples/supervision/Makefile | 9 +++++++++ samples/sym1/Makefile | 14 ++++++++++++++ samples/tutorial/Makefile | 11 +++++++++++ 15 files changed, 191 insertions(+), 6 deletions(-) diff --git a/samples/Makefile b/samples/Makefile index dc0ea8f9f..4bb954ba1 100644 --- a/samples/Makefile +++ b/samples/Makefile @@ -47,6 +47,16 @@ else LD := $(if $(wildcard ../bin/ld65*),../bin/ld65,ld65) endif +ifeq ($(SILENT),s) + QUIET = 1 +endif + +ifdef QUIET + .SILENT: + PQ = "QUIET=1" + PD = --no-print-directory +endif + ifneq ($(filter disk samples.%,$(MAKECMDGOALS)),) ifdef CC65_HOME TARGET_PATH = $(CC65_HOME)/target @@ -152,10 +162,13 @@ LDFLAGS_tgidemo_atarixl = --start-addr 0x4000 .o: ifeq ($(SYS),vic20) + $(if $(QUIET),echo $(SYS):$@) $(LD) $(LDFLAGS_$(@F)_$(SYS)) $(LDFLAGS) -o $@ -C vic20-32k.cfg -m $@.map $^ $(SYS).lib else ifeq ($(SYS),plus4) + $(if $(QUIET),echo $(SYS):$@) $(LD) $(LDFLAGS_$(@F)_$(SYS)) $(LDFLAGS) -o $@ -C plus4-hires.cfg -m $@.map $^ $(SYS).lib else + $(if $(QUIET),echo $(SYS):$@) $(LD) $(LDFLAGS_$(@F)_$(SYS)) $(LDFLAGS) -o $@ -t $(SYS) -m $@.map $^ $(SYS).lib endif @@ -387,7 +400,7 @@ endif define SUBDIR_recipe -@+$(MAKE) -C $(dir) --no-print-directory $@ +@+$(MAKE) -C $(dir) $(PD) $@ $(PQ) endef # SUBDIR_recipe @@ -450,17 +463,23 @@ TARGETS := \ # -------------------------------------------------------------------------- # Rule to make the binaries for every platform +define TARGETDIR_recipe + +@+$(MAKE) -C $(dir) $(PD) $(PQ) + +endef # TARGETDIR_recipe + define TARGET_recipe @echo making samples for: $(T) -@$(MAKE) --no-print-directory clean SYS:=$(T) -@$(MAKE) -j2 SYS:=$(T) -@$(MAKE) --no-print-directory clean SYS:=$(T) +@$(MAKE) -j2 SYS:=$(T) $(PQ) +@$(MAKE) $(PD) clean SYS:=$(T) $(PQ) endef # TARGET_recipe platforms: $(foreach T,$(TARGETS),$(TARGET_recipe)) + $(foreach dir,$(DIRLIST),$(TARGETDIR_recipe)) # -------------------------------------------------------------------------- # Overlay rules. Overlays need special ld65 configuration files. Also, the diff --git a/samples/apple2/Makefile b/samples/apple2/Makefile index d9fa40f66..1f39296de 100644 --- a/samples/apple2/Makefile +++ b/samples/apple2/Makefile @@ -40,6 +40,14 @@ else LD := $(if $(wildcard ../../bin/ld65*),../../bin/ld65,ld65) endif +ifeq ($(SILENT),s) + QUIET = 1 +endif + +ifdef QUIET + .SILENT: +endif + EXELIST_apple2 = \ hgrshow \ hgrtest \ @@ -63,6 +71,7 @@ endif disk: hgr.dsk dhgr.dsk hgr.dsk: hgrshow hgrtest + $(if $(QUIET),echo $(SYS):$@) cp prodos.dsk $@ java -jar $(AC) -as $@ hgrshow $( endef # D64_WRITE_SEQ_recipe samples.d64: samples + $(if $(QUIET),echo $(SYS):$@) @$(C1541) -format "samples,00" d64 $@ >$(NULLDEV) $(foreach file,$(EXELIST_$(SYS)),$(D64_WRITE_PRG_recipe)) # $(foreach file,$(OVERLAYLIST),$(D64_WRITE_PRG_recipe)) diff --git a/samples/disasm/Makefile b/samples/disasm/Makefile index 6599915f6..df883fa7c 100644 --- a/samples/disasm/Makefile +++ b/samples/disasm/Makefile @@ -37,6 +37,14 @@ else DA := $(if $(wildcard ../../bin/da65*),../../bin/da65,da65) endif +ifeq ($(SILENT),s) + QUIET = 1 +endif + +ifdef QUIET + .SILENT: +endif + CPP = cpp #CPPFLAGS = -DTEST_ERROR @@ -56,6 +64,7 @@ $(DAIS): fixed.da $(DA) --sync-lines -o $@ -i $< image.bin image.bin: image.s image.cfg + $(if $(QUIET),echo $(SYS):$@) $(CL) -t none -C image.cfg -o image.bin image.s clean: diff --git a/samples/gamate/Makefile b/samples/gamate/Makefile index 35aef293d..4f20f047a 100644 --- a/samples/gamate/Makefile +++ b/samples/gamate/Makefile @@ -37,6 +37,14 @@ else LD := $(if $(wildcard ../../bin/ld65*),../../bin/ld65,ld65) endif +ifeq ($(SILENT),s) + QUIET = 1 +endif + +ifdef QUIET + .SILENT: +endif + EXELIST_gamate = \ nachtm.bin @@ -56,6 +64,7 @@ else endif nachtm.bin: nachtm.c + $(if $(QUIET),echo $(SYS):$@) $(CL) -Os -l nachtm.lst -t gamate -o nachtm.bin nachtm.c ../../util/gamate/gamate-fixcart nachtm.bin diff --git a/samples/geos/Makefile b/samples/geos/Makefile index ad4033f80..0ede7e78c 100644 --- a/samples/geos/Makefile +++ b/samples/geos/Makefile @@ -17,11 +17,15 @@ C1541 ?= c1541 ifeq ($(origin SYS),command line) ifeq ($(SYS),c64) override SYS = geos-cbm - $(info GEOS: c64 -> geos-cbm) + ifneq ($(SILENT),s) + $(info GEOS: c64 -> geos-cbm) + endif endif ifeq ($(SYS),apple2enh) override SYS = geos-apple - $(info GEOS: apple2enh -> geos-apple) + ifneq ($(SILENT),s) + $(info GEOS: apple2enh -> geos-apple) + endif endif endif @@ -55,6 +59,14 @@ else SP := $(if $(wildcard ../../bin/sp65*),../../bin/sp65,sp65) endif +ifeq ($(SILENT),s) + QUIET = 1 +endif + +ifdef QUIET + .SILENT: +endif + DIRLIST = grc define SUBDIR_recipe @@ -111,36 +123,47 @@ bitmap.c: logo.pcx $(SP) -r logo.pcx -c geos-bitmap -w bitmap.c,ident=bitmap bitmap-demo.cvt: bitmap.c bitmap-demores.grc bitmap-demo.c + $(if $(QUIET),echo $(SYS):$@) $(CL) -t $(SYS) -O -o $@ -m bitmap-demo.map bitmap-demores.grc bitmap-demo.c filesel.cvt: fileselres.grc filesel.c + $(if $(QUIET),echo $(SYS):$@) $(CL) -t $(SYS) -O -o $@ -m filesel.map fileselres.grc filesel.c geosconio.cvt: geosconiores.grc geosconio.c + $(if $(QUIET),echo $(SYS):$@) $(CL) -t $(SYS) -O -o $@ -m geosconio.map geosconiores.grc geosconio.c geosver.cvt: geosverres.grc geosver.c + $(if $(QUIET),echo $(SYS):$@) $(CL) -t $(SYS) -O -o $@ -m geosver.map geosverres.grc geosver.c getid.cvt: getidres.grc getid.c + $(if $(QUIET),echo $(SYS):$@) $(CL) -t $(SYS) -O -o $@ -m getid.map getidres.grc getid.c hello1.cvt: hello1res.grc hello1.c + $(if $(QUIET),echo $(SYS):$@) $(CL) -t $(SYS) -O -o $@ -m hello1.map hello1res.grc hello1.c hello2.cvt: hello2res.grc hello2.c + $(if $(QUIET),echo $(SYS):$@) $(CL) -t $(SYS) -O -o $@ -m hello2.map hello2res.grc hello2.c overlay-demo.cvt: overlay-demores.grc overlay-demo.c + $(if $(QUIET),echo $(SYS):$@) $(CL) -t $(SYS) -O -o $@ -m overlay-demo.map overlay-demores.grc overlay-demo.c rmvprot.cvt: rmvprotres.grc rmvprot.c + $(if $(QUIET),echo $(SYS):$@) $(CL) -t $(SYS) -O -o $@ -m rmvprot.map rmvprotres.grc rmvprot.c vector-demo.cvt: vector-demores.grc vector-demo.c + $(if $(QUIET),echo $(SYS):$@) $(CL) -t $(SYS) -O -o $@ -m vector-demo.map vector-demores.grc vector-demo.c yesno.cvt: yesnores.grc yesno.c + $(if $(QUIET),echo $(SYS):$@) $(CL) -t $(SYS) -O -o $@ -m yesno.map yesnores.grc yesno.c diff --git a/samples/geos/grc/Makefile b/samples/geos/grc/Makefile index 360c7bc7d..101d501e8 100644 --- a/samples/geos/grc/Makefile +++ b/samples/geos/grc/Makefile @@ -39,6 +39,14 @@ else GRC := $(if $(wildcard ../../../bin/grc65*),../../../bin/grc65,grc65) endif +ifeq ($(SILENT),s) + QUIET = 1 +endif + +ifdef QUIET + .SILENT: +endif + EXELIST_geos-cbm = \ test.s \ vlir.cvt @@ -56,9 +64,11 @@ samples: endif test.s: test.grc + $(if $(QUIET),echo $(SYS):$@) $(GRC) -s test.s test.grc vlir.cvt: vlir.grc vlir0.s vlir1.s vlir2.s + $(if $(QUIET),echo $(SYS):$@) # using separate calls here for demonstration purposes: $(GRC) -t $(SYS) -s vlir.s vlir.grc $(AS) -t $(SYS) vlir.s diff --git a/samples/kim1/Makefile b/samples/kim1/Makefile index dbdbcec8d..eca7d6524 100644 --- a/samples/kim1/Makefile +++ b/samples/kim1/Makefile @@ -37,6 +37,14 @@ else LD := $(if $(wildcard ../../bin/ld65*),../../bin/ld65,ld65) endif +ifeq ($(SILENT),s) + QUIET = 1 +endif + +ifdef QUIET + .SILENT: +endif + EXELIST_kim1 = \ kimHello.bin \ kimSieve.bin \ @@ -66,40 +74,51 @@ ramfont.o: ramfont.asm $(AS) ramfont.asm -o ramfont.o kimLife.bin: kimLife.c + $(if $(QUIET),echo $(SYS):$@) $(CL) -t kim1 -C kim1-60k.cfg -Oi -o kimLife.bin kimLife.c kimTest.bin: kimTest.c + $(if $(QUIET),echo $(SYS):$@) $(CL) -t kim1 -C kim1-60k.cfg -Oi -o kimTest.bin kimTest.c kimGFX.bin: kimGFX.c subs.o ramfont.o + $(if $(QUIET),echo $(SYS):$@) $(CL) -t kim1 --listing kimGFX.lst -C kim1-mtuE000.cfg -o kimGFX.bin kimGFX.c subs.o ramfont.o -Ln kimgfx.lbl kimSieve.bin: kimSieve.c + $(if $(QUIET),echo $(SYS):$@) $(CL) -t kim1 -C kim1-60k.cfg -O -o kimSieve.bin kimSieve.c kimHello.bin: kimHello.c + $(if $(QUIET),echo $(SYS):$@) $(CL) -t kim1 -O -o kimHello.bin kimHello.c # To build an intel-format file for the CORSHAM SD card reader kimLife.hex: kimLife.bin + $(if $(QUIET),echo $(SYS):$@) srec_cat kimLife.bin -binary -offset 0x2000 -o kimLife.hex -Intel -address-length=2 kimTest.hex: kimTest.bin + $(if $(QUIET),echo $(SYS):$@) srec_cat kimTest.bin -binary -offset 0x2000 -o kimTest.hex -Intel -address-length=2 kimGFX.hex: kimGFX.bin ramfont.o + $(if $(QUIET),echo $(SYS):$@) srec_cat kimGFX.bin -binary -offset 0x2000 -o kimGFX.hex -Intel -address-length=2 # To build a paper tape file for uploading to the KIM-1 via terminal kimLife.ptp: kimLife.bin + $(if $(QUIET),echo $(SYS):$@) srec_cat kimLife.bin -binary -offset 0x2000 -o kimLife.ptp -MOS_Technologies kimGFX.ptp: kimGFX.bin + $(if $(QUIET),echo $(SYS):$@) srec_cat kimGFX.bin -binary -offset 0x2000 -o kimGFX.ptp -MOS_Technologies kimTest.ptp: kimTest.bin + $(if $(QUIET),echo $(SYS):$@) srec_cat kimTest.bin -binary -offset 0x2000 -o kimTest.ptp -MOS_Technologies clean: diff --git a/samples/lynx/Makefile b/samples/lynx/Makefile index 078ea129a..e27d5801a 100644 --- a/samples/lynx/Makefile +++ b/samples/lynx/Makefile @@ -35,6 +35,14 @@ else LD := $(if $(wildcard ../../bin/ld65*),../../bin/ld65,ld65) endif +ifeq ($(SILENT),s) + QUIET = 1 +endif + +ifdef QUIET + .SILENT: +endif + EXELIST_lynx = \ hello.lnx \ mandelbrot.lnx \ @@ -59,6 +67,7 @@ endif .SUFFIXES: .c .lnx %.lnx : %.c + $(if $(QUIET),echo $(SYS):$@) $(CL) -t $(SYS) -Oris -m $*.map -o $@ $< clean: diff --git a/samples/sim65/Makefile b/samples/sim65/Makefile index 3a06321ee..43783afca 100644 --- a/samples/sim65/Makefile +++ b/samples/sim65/Makefile @@ -37,6 +37,14 @@ else LD := $(if $(wildcard ../../bin/ld65*),../../bin/ld65,ld65) endif +ifeq ($(SILENT),s) + QUIET = 1 +endif + +ifdef QUIET + .SILENT: +endif + EXELIST_sim6502 = \ cpumode_example.bin \ timer_example.bin \ @@ -61,6 +69,7 @@ endif .SUFFIXES: .c .bin %.bin : %.c + $(if $(QUIET),echo $(SYS):$@) $(CL) -t $(SYS) -Oris -m $*.map -o $@ $< clean: diff --git a/samples/supervision/Makefile b/samples/supervision/Makefile index 9396be63d..cae5885ff 100644 --- a/samples/supervision/Makefile +++ b/samples/supervision/Makefile @@ -39,6 +39,14 @@ else SP := $(if $(wildcard ../../bin/sp65*),../../bin/sp65,sp65) endif +ifeq ($(SILENT),s) + QUIET = 1 +endif + +ifdef QUIET + .SILENT: +endif + EXELIST_supervision = \ hello @@ -58,6 +66,7 @@ else endif hello: hello.c + $(if $(QUIET),echo $(SYS):$@) $(CL) -t $(SYS) -O -o hello -m hello.map hello.c clean: diff --git a/samples/sym1/Makefile b/samples/sym1/Makefile index 8abcfb5aa..a5b2e35b5 100644 --- a/samples/sym1/Makefile +++ b/samples/sym1/Makefile @@ -37,6 +37,14 @@ else LD := $(if $(wildcard ../../bin/ld65*),../../bin/ld65,ld65) endif +ifeq ($(SILENT),s) + QUIET = 1 +endif + +ifdef QUIET + .SILENT: +endif + EXELIST_sym1 = \ symHello.bin symTiny.bin symDisplay.bin symIO.bin symNotepad.bin symExtendedMemory.bin @@ -56,21 +64,27 @@ else endif symHello.bin: symHello.c + $(if $(QUIET),echo $(SYS):$@) $(CL) -t sym1 -O -o symHello.bin symHello.c symTiny.bin: symTiny.c + $(if $(QUIET),echo $(SYS):$@) $(CL) -t sym1 -O -o symTiny.bin symTiny.c symDisplay.bin: symDisplay.c + $(if $(QUIET),echo $(SYS):$@) $(CL) -t sym1 -O -o symDisplay.bin symDisplay.c symIO.bin: symIO.c + $(if $(QUIET),echo $(SYS):$@) $(CL) -t sym1 -C sym1-32k.cfg -O -o symIO.bin symIO.c symNotepad.bin: symNotepad.c + $(if $(QUIET),echo $(SYS):$@) $(CL) -t sym1 -C sym1-32k.cfg -O -o symNotepad.bin symNotepad.c symExtendedMemory.bin: symExtendedMemory.c + $(if $(QUIET),echo $(SYS):$@) $(CL) -t sym1 -C sym1-32k.cfg -O -o symExtendedMemory.bin symExtendedMemory.c diff --git a/samples/tutorial/Makefile b/samples/tutorial/Makefile index 685c8dd69..3c3d1edb9 100644 --- a/samples/tutorial/Makefile +++ b/samples/tutorial/Makefile @@ -37,6 +37,14 @@ else LD := $(if $(wildcard ../../bin/ld65*),../../bin/ld65,ld65) endif +ifeq ($(SILENT),s) + QUIET = 1 +endif + +ifdef QUIET + .SILENT: +endif + EXELIST_atari2600 = \ notavailable @@ -86,9 +94,12 @@ ifndef EXELIST_$(SYS) EXELIST_$(SYS) := ${patsubst %.c,%,$(wildcard *.c)} endif +all: samples + samples: $(EXELIST_$(SYS)) hello: hello.c text.s + $(if $(QUIET),echo $(SYS):$@) $(CL) -t $(SYS) -o hello hello.c text.s # empty target used to skip systems that will not work with any program in this dir From 000789de9564190527cf9fe864f56de253d0e3f1 Mon Sep 17 00:00:00 2001 From: mrdudz Date: Thu, 26 Jun 2025 22:36:12 +0200 Subject: [PATCH 10/16] adjust makefiles in util to common behaviour --- util/Makefile | 21 +++++++++++++++------ util/atari/Makefile | 8 ++++++++ util/gamate/Makefile | 8 ++++++++ util/zlib/Makefile | 8 ++++++++ 4 files changed, 39 insertions(+), 6 deletions(-) diff --git a/util/Makefile b/util/Makefile index 337320d36..96d2ec629 100644 --- a/util/Makefile +++ b/util/Makefile @@ -4,6 +4,15 @@ ifneq ($(SILENT),s) $(info Using Makefile: $(realpath $(firstword $(MAKEFILE_LIST))) $(MAKECMDGOALS)) endif +ifeq ($(SILENT),s) + QUIET = 1 +endif + +ifdef QUIET + .SILENT: + PQ = "QUIET=1" + PD = --no-print-directory +endif .PHONY: atari gamate zlib @@ -12,16 +21,16 @@ util: atari gamate zlib all: util atari: - @$(MAKE) -C atari --no-print-directory $@ + @$(MAKE) -C atari $(PD) $(PQ) gamate: - @$(MAKE) -C gamate --no-print-directory $@ + @$(MAKE) -C gamate $(PD) $(PQ) zlib: - @$(MAKE) -C zlib --no-print-directory $@ + @$(MAKE) -C zlib $(PD) $(PQ) mostlyclean clean: - @$(MAKE) -C atari --no-print-directory $@ - @$(MAKE) -C gamate --no-print-directory $@ - @$(MAKE) -C zlib --no-print-directory $@ + @$(MAKE) -C atari $(PD) $@ $(PQ) + @$(MAKE) -C gamate $(PD) $@ $(PQ) + @$(MAKE) -C zlib $(PD) $@ $(PQ) install zip: diff --git a/util/atari/Makefile b/util/atari/Makefile index aa3163ec4..74b7ee78a 100644 --- a/util/atari/Makefile +++ b/util/atari/Makefile @@ -4,6 +4,13 @@ ifneq ($(SILENT),s) $(info Using Makefile: $(realpath $(firstword $(MAKEFILE_LIST))) $(MAKECMDGOALS)) endif +ifeq ($(SILENT),s) + QUIET = 1 +endif + +ifdef QUIET + .SILENT: +endif CC = $(CROSS_COMPILE)gcc @@ -28,6 +35,7 @@ CFLAGS += -O3 -Wall -Wextra -Wno-char-subscripts $(USER_CFLAGS) atari: ataricvt ataricvt: ataricvt.c + $(if $(QUIET),echo HOST:$@) $(CC) $(CFLAGS) -o ataricvt ataricvt.c mostlyclean clean: diff --git a/util/gamate/Makefile b/util/gamate/Makefile index d9b4bbd42..7d1681c37 100644 --- a/util/gamate/Makefile +++ b/util/gamate/Makefile @@ -4,6 +4,13 @@ ifneq ($(SILENT),s) $(info Using Makefile: $(realpath $(firstword $(MAKEFILE_LIST))) $(MAKECMDGOALS)) endif +ifeq ($(SILENT),s) + QUIET = 1 +endif + +ifdef QUIET + .SILENT: +endif CC = $(CROSS_COMPILE)gcc @@ -28,6 +35,7 @@ CFLAGS += -O3 -Wall -Wextra -Wno-char-subscripts $(USER_CFLAGS) gamate: gamate-fixcart gamate-fixcart: gamate-fixcart.c + $(if $(QUIET),echo HOST:$@) $(CC) $(CFLAGS) -o gamate-fixcart gamate-fixcart.c mostlyclean clean: diff --git a/util/zlib/Makefile b/util/zlib/Makefile index 8068ea120..5778ae821 100644 --- a/util/zlib/Makefile +++ b/util/zlib/Makefile @@ -4,6 +4,13 @@ ifneq ($(SILENT),s) $(info Using Makefile: $(realpath $(firstword $(MAKEFILE_LIST))) $(MAKECMDGOALS)) endif +ifeq ($(SILENT),s) + QUIET = 1 +endif + +ifdef QUIET + .SILENT: +endif CC = $(CROSS_COMPILE)gcc @@ -35,6 +42,7 @@ warning: @echo "note that you need zlib installed first" deflater: deflater.c + $(if $(QUIET),echo HOST:$@) $(CC) $(CFLAGS) -o deflater deflater.c -lz mostlyclean clean: From 261180577ccaf668b73b22bee2d840fa241c59a4 Mon Sep 17 00:00:00 2001 From: mrdudz Date: Thu, 26 Jun 2025 22:44:26 +0200 Subject: [PATCH 11/16] add subdirs to "platforms" --- targettest/Makefile | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/targettest/Makefile b/targettest/Makefile index edddca0f2..329992d18 100644 --- a/targettest/Makefile +++ b/targettest/Makefile @@ -791,6 +791,12 @@ TARGETS := \ # -------------------------------------------------------------------------- # Rule to make the binaries for every platform +define TARGETDIR_recipe + +@+$(MAKE) -C $(dir) $(PD) $(PQ) + +endef # TARGETDIR_recipe + define TARGET_recipe @echo making targettest for: $(T) @@ -801,6 +807,7 @@ endef # TARGET_recipe platforms: $(foreach T,$(TARGETS),$(TARGET_recipe)) + $(foreach dir,$(DIRLIST),$(TARGETDIR_recipe)) # -------------------------------------------------------------------------- # some programs link against getsp.o From 703b166b295c6f09fe61b7fd97a69b255815a5ac Mon Sep 17 00:00:00 2001 From: mrdudz Date: Thu, 26 Jun 2025 23:18:35 +0200 Subject: [PATCH 12/16] handle -s and QUIET accordingly in libsrc too. those who never used make -s before might start doing it now :) --- libsrc/Makefile | 33 ++++++++++++++++++++++----------- 1 file changed, 22 insertions(+), 11 deletions(-) diff --git a/libsrc/Makefile b/libsrc/Makefile index 9bbb0aadb..586ce3c03 100644 --- a/libsrc/Makefile +++ b/libsrc/Makefile @@ -8,6 +8,16 @@ ifneq ($(shell echo),) CMD_EXE = 1 endif +ifeq ($(SILENT),s) + QUIET = 1 +endif + +ifdef QUIET + .SILENT: + PQ = "QUIET=1" + PD = --no-print-directory +endif + CBMS = c128 \ c16 \ c64 \ @@ -134,7 +144,7 @@ zip: $(foreach dir,$(OUTPUTDIRS),$(ZIP_recipe)) $(TARGETS): | ../lib - @$(MAKE) --no-print-directory $@ + @$(MAKE) $(PD) $@ $(PQ) # ../lib must be created globally before doing lib targets in parallel ../lib: @@ -259,8 +269,8 @@ $1_DYNS = $$(patsubst $$($1_SRCPAT),$$($1_DYNPAT),$$($1_SRCS)) $1_DRVS = $$(patsubst $$($1_DYNPAT),$$($1_DRVPAT),$$($1_DYNS)) $$($1_STCPAT): $$($1_SRCPAT) - @echo $$(TARGET) - $$< - static - @$$(CA65) -t $$(TARGET) -D DYN_DRV=0 $$(CA65FLAGS) --create-dep $$(@:.o=.d) -o $$@ $$< + $$(if $$(QUIET),@echo $$(TARGET) - $$< - static) + $$(CA65) -t $$(TARGET) -D DYN_DRV=0 $$(CA65FLAGS) --create-dep $$(@:.o=.d) -o $$@ $$< OBJS += $$($1_STCS) DEPS += $$($1_STCS:.o=.d) @@ -268,8 +278,8 @@ DEPS += $$($1_STCS:.o=.d) $$($1_DYNS): | $$($1_DYNDIR) $$($1_DRVPAT): $$($1_DYNPAT) $$(ZPOBJ) | $$($1_DRVDIR) - @echo $$(TARGET) - $$( Date: Thu, 26 Jun 2025 23:44:56 +0200 Subject: [PATCH 13/16] ...and patch the Makefile in src the same way --- src/Makefile | 34 ++++++++++++++++++++++++---------- 1 file changed, 24 insertions(+), 10 deletions(-) diff --git a/src/Makefile b/src/Makefile index 085a50f9d..bdeaf4bc9 100644 --- a/src/Makefile +++ b/src/Makefile @@ -8,12 +8,6 @@ ifneq ($(shell echo),) CMD_EXE = 1 endif -ifneq ($(V),1) - Q=@ -else - Q= -endif - PROGS = ar65 \ ca65 \ cc65 \ @@ -52,6 +46,21 @@ else RMDIR = $(RM) -r $1 endif +ifeq ($(SILENT),s) + QUIET = 1 + NULLOUT = >$(NULLDEV) + NULLERR = 2>$(NULLDEV) +endif + +ifdef QUIET + .SILENT: + PQ = "QUIET=1" + PD = --no-print-directory +ifndef CMD_EXE + CATERR = 2> ../wrk/common/$$@.errlog || (cat ../wrk/common/$$@.errlog && false) +endif +endif + CC = $(CROSS_COMPILE)gcc AR = $(CROSS_COMPILE)ar @@ -70,7 +79,10 @@ ifndef BUILD_ID BUILD_ID := N/A endif endif -$(info BUILD_ID: $(BUILD_ID)) + +ifneq ($(SILENT),s) + $(info BUILD_ID: $(BUILD_ID)) +endif CFLAGS += -MMD -MP -O3 -I common \ -Wall -Wextra -Wno-char-subscripts $(USER_CFLAGS) \ @@ -161,8 +173,8 @@ $1: ../bin/$1$(EXE_SUFFIX) endef # PROG_template ../wrk/%.o: %.c - @echo $< - $(Q)$(CC) -c $(CFLAGS) -o $@ $< + $(if $(QUIET),echo CC:$@) + $(CC) -c $(CFLAGS) -o $@ $< ../bin: @$(call MKDIR,$@) @@ -170,7 +182,8 @@ endef # PROG_template $(eval $(call OBJS_template,common)) ../wrk/common/common.a: $(common_OBJS) - $(AR) r $@ $? + $(if $(QUIET),echo AR:$@) + $(AR) r $@ $? $(CATERR) $(foreach prog,$(PROGS),$(eval $(call PROG_template,$(prog)))) @@ -184,6 +197,7 @@ $(eval $(call OBJS_template,dbginfo)) dbginfo: $(dbginfo_OBJS) ../wrk/dbgsh$(EXE_SUFFIX): $(dbginfo_OBJS) ../wrk/common/common.a + $(if $(QUIET),echo LINK:$@) $(CC) $(LDFLAGS) -o $@ $^ $(LDLIBS) dbgsh: ../wrk/dbgsh$(EXE_SUFFIX) From 1f1e1f1490c167e02c53e79e35d060608386fd50 Mon Sep 17 00:00:00 2001 From: mrdudz Date: Thu, 26 Jun 2025 23:53:36 +0200 Subject: [PATCH 14/16] output target before name(s) --- targettest/Makefile | 7 +++++-- targettest/accelerator/Makefile | 16 ++++++++-------- targettest/atari/Makefile | 18 +++++++++--------- targettest/cbm/Makefile | 6 +++--- targettest/gamate/Makefile | 6 +++--- targettest/pce/Makefile | 2 +- 6 files changed, 29 insertions(+), 26 deletions(-) diff --git a/targettest/Makefile b/targettest/Makefile index 329992d18..ebdecfba6 100644 --- a/targettest/Makefile +++ b/targettest/Makefile @@ -130,12 +130,12 @@ DISK_atarixl = testcode.atr %: %.s .c.o: - $(if $(QUIET),echo targettest/$*.c) + $(if $(QUIET),echo $(SYS):$*.c) $(CC) $(CFLAGS) -Ors --codesize 500 -T -g -t $(SYS) $< $(AS) $(<:.c=.s) .s.o: - $(if $(QUIET),echo targettest/$*.s) + $(if $(QUIET),echo $(SYS):$*.s) $(AS) $(ASFLAGS) -t $(SYS) $< .PRECIOUS: %.o @@ -813,10 +813,12 @@ platforms: # some programs link against getsp.o mouse-test: mouse-test.o getsp.o + $(if $(QUIET),echo $(SYS):$@) $(LD) $(LDFLAGS) -t $(SYS) -o $@ $^ $(SYS).lib ifneq ($(SYS),vic20) ft: ft.o getsp.o + $(if $(QUIET),echo $(SYS):$@) $(LD) $(LDFLAGS) -t $(SYS) -o $@ $^ $(SYS).lib endif @@ -824,6 +826,7 @@ endif ifeq ($(SYS),vic20) ft: ft.o getsp.o + $(if $(QUIET),echo $(SYS):$@) $(LD) $(LDFLAGS) -o $@ -C vic20-32k.cfg -m $@.map $^ $(SYS).lib endif diff --git a/targettest/accelerator/Makefile b/targettest/accelerator/Makefile index 0a6a9bb02..a8d26e368 100644 --- a/targettest/accelerator/Makefile +++ b/targettest/accelerator/Makefile @@ -72,35 +72,35 @@ else endif c64-scpu-test.prg: c64-c128-scpu-test.c - $(if $(QUIET),echo $@) + $(if $(QUIET),echo $(SYS):$@) $(CL) -t c64 c64-c128-scpu-test.c -o c64-scpu-test.prg c128-scpu-test.prg: c64-c128-scpu-test.c - $(if $(QUIET),echo $@) + $(if $(QUIET),echo $(SYS):$@) $(CL) -t c128 c64-c128-scpu-test.c -o c128-scpu-test.prg c64dtv-test.prg: c64dtv-test.c - $(if $(QUIET),echo $@) + $(if $(QUIET),echo $(SYS):$@) $(CL) -t c64 c64dtv-test.c -o c64dtv-test.prg c64-test.prg: c64-c128-test.c - $(if $(QUIET),echo $@) + $(if $(QUIET),echo $(SYS):$@) $(CL) -t c64 c64-c128-test.c -o c64-test.prg c128-test.prg: c64-c128-test.c - $(if $(QUIET),echo $@) + $(if $(QUIET),echo $(SYS):$@) $(CL) -t c128 c64-c128-test.c -o c128-test.prg chameleon-test.prg: chameleon-test.c - $(if $(QUIET),echo $@) + $(if $(QUIET),echo $(SYS):$@) $(CL) -t c64 chameleon-test.c -o chameleon-test.prg c65-test.prg: c65-test.c - $(if $(QUIET),echo $@) + $(if $(QUIET),echo $(SYS):$@) $(CL) -t c64 c65-test.c -o c65-test.prg turbomaster-test.prg: turbomaster-test.c - $(if $(QUIET),echo $@) + $(if $(QUIET),echo $(SYS):$@) $(CL) -t c64 turbomaster-test.c -o turbomaster-test.prg clean: diff --git a/targettest/atari/Makefile b/targettest/atari/Makefile index ef8d1883c..099dd291c 100644 --- a/targettest/atari/Makefile +++ b/targettest/atari/Makefile @@ -72,33 +72,33 @@ else endif charmapping.xex: charmapping.c - $(if $(QUIET),echo $@) + $(if $(QUIET),echo $(SYS):$@) $(CL) -t atari -o charmapping.xex charmapping.c defdev.xex: defdev.c - $(if $(QUIET),echo $@) + $(if $(QUIET),echo $(SYS):$@) $(CL) -t atari -o defdev.xex defdev.c displaylist.xex: displaylist.c - $(if $(QUIET),echo $@) + $(if $(QUIET),echo $(SYS):$@) $(CL) -t atari -o displaylist.xex displaylist.c mem.xex: mem.c ../getsp.s - $(if $(QUIET),echo $@) + $(if $(QUIET),echo $(SYS):$@) $(CL) -t atari -o mem.xex mem.c ../getsp.s multi.xex: multi-xex.s multi-xex.cfg - $(if $(QUIET),echo $@) + $(if $(QUIET),echo $(SYS):$@) $(CL) -t atari -C multi-xex.cfg multi-xex.s -o multi.xex ostype.xex: ostype.c - $(if $(QUIET),echo $@) + $(if $(QUIET),echo $(SYS):$@) $(CL) -t atari -o ostype.xex ostype.c scrcode.com: scrcode.s - $(if $(QUIET),echo $@) + $(if $(QUIET),echo $(SYS):$@) # ca65 -t atari -o scrcode.o scrcode.s # ld65 -C atari-asm.cfg -o scrcode.com scrcode.o $(CL) -t atari -C atari-asm.cfg -o scrcode.com scrcode.s sys.xex: sys.c - $(if $(QUIET),echo $@) + $(if $(QUIET),echo $(SYS):$@) $(CL) -t atari -o sys.xex sys.c sound.xex: sound.c - $(if $(QUIET),echo $@) + $(if $(QUIET),echo $(SYS):$@) $(CL) -t atari -o sound.xex sound.c clean: @$(DEL) charmapping.xex 2>$(NULLDEV) diff --git a/targettest/cbm/Makefile b/targettest/cbm/Makefile index 96acf49a0..6359a154a 100644 --- a/targettest/cbm/Makefile +++ b/targettest/cbm/Makefile @@ -81,14 +81,14 @@ endif ifeq ($(SYS),c64) petscii.prg: petscii.c - $(if $(QUIET),echo $@) + $(if $(QUIET),echo $(SYS):$@) $(CL) -t $(SYS) -O -o petscii.prg petscii.c else petscii.prg: endif cbmdir-test.prg: cbmdir-test.c - $(if $(QUIET),echo $@) + $(if $(QUIET),echo $(SYS):$@) ifeq ($(SYS),vic20) $(CL) -t $(SYS) -C vic20-32k.cfg -Oris -o $@ $< else @@ -96,7 +96,7 @@ else endif cbmread.prg: cbmread.c - $(if $(QUIET),echo $@) + $(if $(QUIET),echo $(SYS):$@) ifeq ($(SYS),vic20) $(CL) -t $(SYS) -C vic20-32k.cfg -Oris -o $@ $< else diff --git a/targettest/gamate/Makefile b/targettest/gamate/Makefile index 3e3d1f9d8..21fd039ec 100644 --- a/targettest/gamate/Makefile +++ b/targettest/gamate/Makefile @@ -64,13 +64,13 @@ else endif audiotest.bin: audiotest.s - $(if $(QUIET),echo $@) + $(if $(QUIET),echo $(SYS):$@) $(CL) -l audiotest.lst -t gamate -o audiotest.bin audiotest.s lcdtest.bin: lcdtest.s - $(if $(QUIET),echo $@) + $(if $(QUIET),echo $(SYS):$@) $(CL) -l lcdtest.lst -t gamate -o lcdtest.bin lcdtest.s ctest.bin: ctest.c - $(if $(QUIET),echo $@) + $(if $(QUIET),echo $(SYS):$@) $(CL) -l ctest.lst -t gamate -o ctest.bin ctest.c clean: diff --git a/targettest/pce/Makefile b/targettest/pce/Makefile index 2a0be84d5..53516d55d 100644 --- a/targettest/pce/Makefile +++ b/targettest/pce/Makefile @@ -79,7 +79,7 @@ else endif %.bin: %.c - $(if $(QUIET),echo $@) + $(if $(QUIET),echo $(SYS):$@) $(CL) -t pce $< -Wl -D__CARTSIZE__=${CARTSIZE} -m $*.map -o $@ ifndef QUIET @echo "use 'make conio.pce' to produce a .pce file using dd" From 0d98ab42f03de4e8d5693892dd7737e3ddc49441 Mon Sep 17 00:00:00 2001 From: mrdudz Date: Fri, 27 Jun 2025 00:00:48 +0200 Subject: [PATCH 15/16] pass QUIET in the workflows --- .github/workflows/build-on-pull-request.yml | 16 ++++++++-------- .github/workflows/snapshot-on-push-master.yml | 18 +++++++++--------- .github/workflows/windows-test-scheduled.yml | 8 ++++---- 3 files changed, 21 insertions(+), 21 deletions(-) diff --git a/.github/workflows/build-on-pull-request.yml b/.github/workflows/build-on-pull-request.yml index b577e4b03..7f80663f2 100644 --- a/.github/workflows/build-on-pull-request.yml +++ b/.github/workflows/build-on-pull-request.yml @@ -29,29 +29,29 @@ jobs: run: make -j2 sorted - name: Build the tools. shell: bash - run: make -j2 bin USER_CFLAGS=-Werror + run: make -j2 bin USER_CFLAGS=-Werror QUIET=1 - name: Build the dbginfo example shell: bash - run: make -j2 -C src test + run: make -j2 -C src test QUIET=1 - name: Build the utilities. shell: bash - run: make -j2 util + run: make -j2 util QUIET=1 - name: Build the platform libraries. shell: bash run: make -j2 lib QUIET=1 - name: check test that no modules use sp shell: bash - run: make -j2 checksp QUIET=1 + run: make -j2 checksp QUIET=1 - name: Run the regression tests. shell: bash run: make -j2 test QUIET=1 - name: Test that the samples can be built. - run: make -C samples platforms + run: make -C samples platforms QUIET=1 - name: Test that the targettest programs can be built. - run: make -C targettest platforms + run: make -C targettest platforms QUIET=1 - name: Build the document files. shell: bash - run: make -j2 doc + run: make -j2 doc QUIET=1 - name: Upload a documents snapshot. uses: actions/upload-artifact@v4 with: @@ -90,7 +90,7 @@ jobs: - name: Build utils (MinGW) shell: cmd - run: make -j2 util SHELL=cmd + run: make -j2 util QUIET=1 SHELL=cmd - name: Build the platform libraries (make lib) shell: cmd diff --git a/.github/workflows/snapshot-on-push-master.yml b/.github/workflows/snapshot-on-push-master.yml index 557ba24af..c9c8a0c47 100644 --- a/.github/workflows/snapshot-on-push-master.yml +++ b/.github/workflows/snapshot-on-push-master.yml @@ -55,8 +55,8 @@ jobs: - name: Build the tools. shell: bash run: | - make -j2 bin USER_CFLAGS=-Werror - make -j2 util + make -j2 bin USER_CFLAGS=-Werror QUIET=1 + make -j2 util QUIET=1 - name: Build the platform libraries. shell: bash run: make -j2 lib QUIET=1 @@ -65,26 +65,26 @@ jobs: run: make -j2 test QUIET=1 - name: Test that the samples can be built. shell: bash - run: make -j2 samples + run: make -j2 samples QUIET=1 - name: Remove the output from the samples tests. shell: bash - run: make -C samples clean + run: make -C samples clean QUIET=1 - name: Remove programs in util directory shell: bash - run: make -C util clean + run: make -C util clean QUIET=1 - name: Build the document files. shell: bash - run: make -j2 doc + run: make -j2 doc QUIET=1 - name: Build and package 64-bit Windows versions of the tools. run: | - make -C src clean + make -C src clean QUIET=1 make -j2 bin USER_CFLAGS=-Werror CROSS_COMPILE=x86_64-w64-mingw32- make zip mv cc65.zip cc65-snapshot-win64.zip - name: Build and package 32-bit Windows versions of the tools. run: | - make -C src clean - make -j2 bin USER_CFLAGS=-Werror CROSS_COMPILE=i686-w64-mingw32- + make -C src clean QUIET=1 + make -j2 bin USER_CFLAGS=-Werror QUIET=1 CROSS_COMPILE=i686-w64-mingw32- make zip mv cc65.zip cc65-snapshot-win32.zip diff --git a/.github/workflows/windows-test-scheduled.yml b/.github/workflows/windows-test-scheduled.yml index fa22473f4..2e24e1d01 100644 --- a/.github/workflows/windows-test-scheduled.yml +++ b/.github/workflows/windows-test-scheduled.yml @@ -60,19 +60,19 @@ jobs: - name: Build utils (MinGW) if: steps.check-sha.outputs.cache-hit != 'true' shell: cmd - run: make -j2 util SHELL=cmd + run: make -j2 util SHELL=cmd QUIET=1 - name: Build the platform libraries (make lib) if: steps.check-sha.outputs.cache-hit != 'true' shell: cmd - run: make -j2 lib QUIET=1 SHELL=cmd + run: make -j2 lib QUIET=1 SHELL=cmd QUIET=1 - name: Run the regression tests (make test) if: steps.check-sha.outputs.cache-hit != 'true' shell: cmd - run: make -j2 test QUIET=1 SHELL=cmd + run: make -j2 test QUIET=1 SHELL=cmd QUIET=1 - name: Test that the samples can be built (make samples) if: steps.check-sha.outputs.cache-hit != 'true' shell: cmd - run: make -j2 samples SHELL=cmd + run: make -j2 samples SHELL=cmd QUIET=1 From ecdc59de474f654ef92c51adc598034d086ce815 Mon Sep 17 00:00:00 2001 From: mrdudz Date: Fri, 27 Jun 2025 00:10:07 +0200 Subject: [PATCH 16/16] more QUIET=1 --- .github/workflows/build-on-pull-request.yml | 4 ++-- .github/workflows/snapshot-on-push-master.yml | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/build-on-pull-request.yml b/.github/workflows/build-on-pull-request.yml index 7f80663f2..f5aacca31 100644 --- a/.github/workflows/build-on-pull-request.yml +++ b/.github/workflows/build-on-pull-request.yml @@ -59,8 +59,8 @@ jobs: path: ./html - name: Build 64-bit Windows versions of the tools. run: | - make -C src clean - make -j2 bin USER_CFLAGS=-Werror CROSS_COMPILE=x86_64-w64-mingw32- + make -C src clean QUIET=1 + make -j2 bin QUIET=1 USER_CFLAGS=-Werror CROSS_COMPILE=x86_64-w64-mingw32- build_windows: name: Build and Test (Windows) diff --git a/.github/workflows/snapshot-on-push-master.yml b/.github/workflows/snapshot-on-push-master.yml index c9c8a0c47..591b221be 100644 --- a/.github/workflows/snapshot-on-push-master.yml +++ b/.github/workflows/snapshot-on-push-master.yml @@ -78,7 +78,7 @@ jobs: - name: Build and package 64-bit Windows versions of the tools. run: | make -C src clean QUIET=1 - make -j2 bin USER_CFLAGS=-Werror CROSS_COMPILE=x86_64-w64-mingw32- + make -j2 bin QUIET=1 USER_CFLAGS=-Werror CROSS_COMPILE=x86_64-w64-mingw32- make zip mv cc65.zip cc65-snapshot-win64.zip - name: Build and package 32-bit Windows versions of the tools.