build: adding rules ex1/ex2 to the Makefile
This commit is contained in:
parent
9d46cee039
commit
c960cd6f32
1 changed files with 26 additions and 1 deletions
27
C/Makefile
27
C/Makefile
|
|
@ -91,6 +91,31 @@ $(OBJDIRNAME)/%.o: %.c
|
|||
@printf '$(GREY) Compiling $(END)$(GREEN)$<$(END)\n'
|
||||
@$(CC) $(CFLAGS) -c -o $@ $<
|
||||
|
||||
test: test_colleen test_grace test_sully
|
||||
|
||||
test_colleen: $(COLLEEN)
|
||||
@clear
|
||||
@rm -rf /tmp/test_colleen.c
|
||||
@$(COLLEEN) > /tmp/test_colleen.c
|
||||
@printf '$(GREY)Output of the $(GOLD)Colleen$(RESET)\n'
|
||||
@bat -plc /tmp/test_colleen.c
|
||||
@printf '\n$(GREY)Here's the diff between $(GOLD)$(SRC_COLLEEN) $(GREY)and $(GOLD)/tmp/test_colleen.c$(RESET)\n'
|
||||
@diff $(SRC_COLLEEN) /tmp/test_colleen.c | bat -ldiff
|
||||
|
||||
test_grace: $(GRACE)
|
||||
@$(GRACE) > /tmp/test_grace.c
|
||||
@printf '\n\n\n$(GREY)Output of the $(GOLD)Grace$(RESET)\n'
|
||||
@bat -plc /tmp/test_grace.c
|
||||
@printf '\n$(GREY)Here's the diff between $(GOLD)$(SRC_GRACE) $(GREY)and $(GOLD)/tmp/test_grace.c$(RESET)\n'
|
||||
@diff $(SRC_GRACE) /tmp/test_grace | bat -ldiff
|
||||
|
||||
test_sully: $(SULLY)
|
||||
@$(SULLY) > /tmp/test_sully.c
|
||||
@printf '$(GREY)Output of the $(GOLD)Sully$(RESET)\n'
|
||||
@bat -plc /tmp/test_sully.c
|
||||
@printf '\n$(GREY)Here's the diff between $(GOLD)$(SRC_SULLY) $(GREY)and $(GOLD)/tmp/test_sully.c$(RESET)\n'
|
||||
@diff $(SRC_SULLY) /tmp/test_sully | bat -ldiff
|
||||
|
||||
# Header
|
||||
header:
|
||||
@printf '\n\n'
|
||||
|
|
@ -104,7 +129,7 @@ header:
|
|||
@printf '$(GOLD) ****** ******* ****** $(END)\n'
|
||||
@printf '$(GOLD) ****** $(END)\n'
|
||||
@printf '$(GOLD) ****** $(END)\n'
|
||||
@printf '$(GREY) Made by glaruell & rparodi$(END)\n\n'
|
||||
@printf '$(GREY) Made by rparodi$(END)\n\n'
|
||||
|
||||
# Footer
|
||||
footer:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue