From 846734e894b3b48ae46886ebecdde1636de8abc6 Mon Sep 17 00:00:00 2001 From: hedara90 <90hedara@gmail.com> Date: Sat, 11 Jan 2025 21:53:15 +0100 Subject: [PATCH] Ported Makefile fix from upcoming (#6007) Co-authored-by: Hedara --- Makefile | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/Makefile b/Makefile index 0d2ef1d240..5f806e45ec 100644 --- a/Makefile +++ b/Makefile @@ -29,9 +29,6 @@ endif ifeq (debug,$(MAKECMDGOALS)) DEBUG := 1 endif -ifeq ($(TESTELF),$(MAKECMDGOALS)) - TEST := 1 -endif # Default make rule all: rom @@ -75,6 +72,9 @@ HEADLESSELF = $(ROM_NAME:.gba=-test-headless.elf) # Pick our active variables ROM := $(ROM_NAME) +ifeq ($(TESTELF),$(MAKECMDGOALS)) + TEST := 1 +endif ifeq ($(TEST), 0) OBJ_DIR := $(OBJ_DIR_NAME) else @@ -83,9 +83,6 @@ endif ifeq ($(DEBUG),1) OBJ_DIR := $(OBJ_DIR_NAME_DEBUG) endif -ifeq ($(TESTELF),$(MAKECMDGOALS)) - TEST := 1 -endif ELF := $(ROM:.gba=.elf) MAP := $(ROM:.gba=.map) SYM := $(ROM:.gba=.sym) @@ -180,7 +177,7 @@ MAKEFLAGS += --no-print-directory # Delete files that weren't built properly .DELETE_ON_ERROR: -RULES_NO_SCAN += libagbsyscall clean clean-assets tidy tidymodern tidycheck generated clean-generated $(TESTELF) +RULES_NO_SCAN += libagbsyscall clean clean-assets tidy tidymodern tidycheck generated clean-generated .PHONY: all rom agbcc modern compare check debug .PHONY: $(RULES_NO_SCAN)