From 04d16b3740d962ecfe0f1c9cc83e3b702835fa58 Mon Sep 17 00:00:00 2001 From: Jesse Rosenstock Date: Tue, 28 Jul 2020 13:38:49 +0200 Subject: [PATCH] Make $WORKDIR for tests/err Without this, if there is a test that can compile, it will still fail because the WORKDIR does not exist: ``` pass.c(1): Fatal: Cannot open output file '../../testwrk/err/pass.s': No such file or directory ``` --- test/err/Makefile | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/test/err/Makefile b/test/err/Makefile index 4b05ca5db..1273bbb2c 100644 --- a/test/err/Makefile +++ b/test/err/Makefile @@ -34,7 +34,10 @@ TESTS = $(patsubst %.c,$(WORKDIR)/%.s,$(SOURCES)) all: $(TESTS) -$(WORKDIR)/%.s: %.c +$(WORKDIR): + $(call MKDIR,$(WORKDIR)) + +$(WORKDIR)/%.s: %.c | $(WORKDIR) $(if $(QUIET),echo err/$*.s) $(NOT) $(CC65) -o $@ $< $(NULLERR)