aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTom Ryder <tom@sanctum.geek.nz>2016-03-05 18:16:01 +1300
committerTom Ryder <tom@sanctum.geek.nz>2016-03-05 18:16:01 +1300
commite2db53dc1d402b320a13050173ace2b2c281546e (patch)
treed0e0aaabfcb6c11130775e727d713dee79692972
parentMore precise definition for ctags (diff)
downloadspsh-e2db53dc1d402b320a13050173ace2b2c281546e.tar.gz
spsh-e2db53dc1d402b320a13050173ace2b2c281546e.zip
Specify phony Make targets, reorder
-rw-r--r--Makefile9
1 files changed, 7 insertions, 2 deletions
diff --git a/Makefile b/Makefile
index 49ca5dd..3ef5c6e 100644
--- a/Makefile
+++ b/Makefile
@@ -1,16 +1,21 @@
+.PHONY: all clean install
+
CC = gcc
LDFLAGS = -lreadline
CFLAGS = -Wall -Wpedantic -ansi -pedantic-errors
PREFIX := /usr/local
+all : spsh
+
spsh : main.o banner.o cmd.o loop.o
$(CC) $(CFLAGS) main.o banner.o cmd.o loop.o $(LDFLAGS) -o spsh
tags :
ctags -- *.c *.h
+clean :
+ rm -f -- *.o spsh tags
+
install : spsh
install -m 0755 spsh "$(PREFIX)"/bin
-clean :
- rm -f -- *.o spsh tags