aboutsummaryrefslogtreecommitdiffstats
path: root/Makefile
diff options
context:
space:
mode:
authorMattias Andrée <maandree@kth.se>2021-09-16 16:13:12 +0200
committerMattias Andrée <maandree@kth.se>2021-09-16 16:13:12 +0200
commite9f603063cdd2d3c7c7f0801078e22158e6bad1d (patch)
treef718093534c648d37e30a1220313deb2ca45291b /Makefile
parentFix a buf and a portability issue found by Jonathan Frech (diff)
downloadasroot-e9f603063cdd2d3c7c7f0801078e22158e6bad1d.tar.gz
asroot-e9f603063cdd2d3c7c7f0801078e22158e6bad1d.tar.bz2
asroot-e9f603063cdd2d3c7c7f0801078e22158e6bad1d.tar.xz
Improve makefile1.1.5
Signed-off-by: Mattias Andrée <maandree@kth.se>
Diffstat (limited to '')
-rw-r--r--Makefile9
1 files changed, 8 insertions, 1 deletions
diff --git a/Makefile b/Makefile
index ae36177..10de910 100644
--- a/Makefile
+++ b/Makefile
@@ -3,9 +3,13 @@
CONFIGFILE = config.mk
include $(CONFIGFILE)
+
all: asroot
asroot.o: asroot.c arg.h
+.c.o:
+ $(CC) -c -o $@ $< $(CFLAGS) $(CPPFLAGS)
+
asroot: asroot.o
$(CC) -o $@ asroot.o $(LDFLAGS)
@@ -24,6 +28,9 @@ uninstall:
-rm -f -- "$(DESTDIR)$(MANPREFIX)/man8/asroot.8"
clean:
- -rm -f -- asroot.o asroot
+ -rm -f -- asroot *.o *.su
+
+.SUFFIXES:
+.SUFFIXES: .o .c
.PHONY: all install post-install uninstall clean