From 51d751b69879ee80e4e6185df21b1eb11f1db844 Mon Sep 17 00:00:00 2001 From: Ulysse Cura Date: Fri, 17 Jul 2026 17:57:34 +0200 Subject: [PATCH] Fixing some Makefile problems. --- GCC_Project/Makefile | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/GCC_Project/Makefile b/GCC_Project/Makefile index 208deca..551e41a 100644 --- a/GCC_Project/Makefile +++ b/GCC_Project/Makefile @@ -30,9 +30,9 @@ Q := @ endif # Colors -GREEN := \033[0;32m -YELLOW := \033[1;33m -RESET := \033[0m +GREEN := \033[32m +YELLOW := \033[33m +RESET := \033[m # Current file nb to process CURRENT_FILE := 0 @@ -46,14 +46,14 @@ build_dir: # Link target $(OUTPUT): $(OBJECTS) - @echo "[100%] $(YELLOW)Linking $(OUTPUT)$(RESET)" + @echo -e "[100%] $(YELLOW)Linking $(OUTPUT)$(RESET)" $(Q)$(CC) $(LDFLAGS) -o $@ $(OBJECTS) # Build .o files from .c $(BUILD_DIR)/%.o: %.c $(eval CURRENT_FILE := $(shell echo $$(($(CURRENT_FILE)+1)))) $(eval PERCENTAGE := $(shell echo $$(($(CURRENT_FILE)*100/$(TOTAL_FILES))))) - @echo "[$(PERCENTAGE)%] $(GREEN)Building C object $@$(RESET)" + @echo -e "[$(PERCENTAGE)%] $(GREEN)Building C object $@$(RESET)" $(Q)$(CC) $(CCFLAGS) $(INCLUDE_DIRS:%=-I%) -MMD -MP -c $< -o $@ # Source files dependencies @@ -73,5 +73,5 @@ clean: # Run executable .PHONY: run -run: +run: all $(Q)./$(OUTPUT)