From 70697e7afc06b191f911b31d3f58088174e3e290 Mon Sep 17 00:00:00 2001 From: Titouan Rigoudy Date: Wed, 26 Nov 2014 19:00:55 -0500 Subject: [PATCH] Better makefile, use %.o rule --- arithmetic_progressions/Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arithmetic_progressions/Makefile b/arithmetic_progressions/Makefile index 461b0f8..47ae4b8 100644 --- a/arithmetic_progressions/Makefile +++ b/arithmetic_progressions/Makefile @@ -4,7 +4,7 @@ CFLAGS= -ggdb --std=c11 all: ap -segtree.o: segtree.c +%.o: %.c $(CC) -o $@ -c $^ $(CFLAGS) ap: arithmetic_progressions.c segtree.o