make diff ok

This commit is contained in:
asus
2024-01-26 13:10:50 +01:00
parent 318cff516b
commit bbe97e90c6

View File

@@ -105,13 +105,15 @@ $(NAME): $(OBJS)
leaks: $(NAME)
valgrind --leak-check=full --show-leak-kinds=all $(CREATE_CLONE)
run:
run: $(NAME)
$(CREATE_CLONE)
diff: $(NAME)
diff: $(CLONES)
@echo $(CYAN)"compare source with output :"$(RESET)
- diff --color $(CLONE) $(SRCS); \
if [ $$? -eq 0 ]; then echo $(GREEN)"Files $(SRCS) and $(CLONES) are identical"$(RESET); else echo $(RED)":Files $(SRCS) and $(CLONES) differ"$(RESET); fi
@for clone in $^; do \
diff --color $$clone $(SRCS); \
if [ $$? -eq 0 ]; then echo $(GREEN)"Files $(SRCS) and $$clone are identical"$(RESET); else echo $(RED)":Files $(SRCS) and $$clone differ"$(RESET); fi \
done
clean:
$(RM_OBJS)