aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Makefile13
1 files changed, 12 insertions, 1 deletions
diff --git a/Makefile b/Makefile
index 3f212bf..db8718c 100644
--- a/Makefile
+++ b/Makefile
@@ -1,7 +1,14 @@
-TARGETS = pingu mtu
+TARGETS = mtu
CFLAGS ?= -g
+prefix = /usr
+BINDIR = $(prefix)/bin
+DESTDIR ?=
+
+INSTALL = install
+INSTALLDIR = $(INSTALL) -d
+
pingu_OBJS = \
log.o \
pingu.o \
@@ -20,5 +27,9 @@ pingu: $(pingu_OBJS)
mtu: $(mtu_OBJS)
+install: $(TARGETS)
+ $(INSTALLDIR) $(DESTDIR)/$(BINDIR)
+ $(INSTALL) $(TARGETS) $(DESTDIR)/$(BINDIR)
+
clean:
rm -f $(TARGETS) $(ALL_OBJS)