aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Makefile11
1 files changed, 8 insertions, 3 deletions
diff --git a/Makefile b/Makefile
index 1bd8fb8..3d1e305 100644
--- a/Makefile
+++ b/Makefile
@@ -1,6 +1,11 @@
-fref: fref.lex
- lex fref.lex
- cc -std=c89 -O2 -o fref lex.yy.c -lfl
+CFLAGS += -std=c89
+LDFLAGS += -lfl
+
+fref: lex.yy.c
+ $(CC) $(CFLAGS) -o fref lex.yy.c $(LDFLAGS)
+
+lex.yy.c: fref.lex
+ flex fref.lex
install:
install fref /usr/local/bin