[svn-upgrade] Integrating new upstream version, iodine (0.4.1)
[debian/iodine.git] / Makefile
1 prefix=/usr/local
2 sbindir=$(prefix)/sbin
3 datadir=$(prefix)/share
4 mandir=$(datadir)/man
5
6 DESTDIR=
7
8 INSTALL=install
9 INSTALL_FLAGS=
10
11 MKDIR=mkdir
12 MKDIR_FLAGS=-p
13
14 RM=rm
15 RM_FLAGS=-f
16
17 all: 
18         @(cd src; $(MAKE) all)
19
20 install: all
21         $(MKDIR) $(MKDIR_FLAGS) $(DESTDIR)$(sbindir)
22         $(INSTALL) $(INSTALL_FLAGS) bin/iodine $(DESTDIR)$(sbindir)/iodine
23         chmod 755 $(DESTDIR)$(sbindir)/iodine
24         $(INSTALL) $(INSTALL_FLAGS) bin/iodined $(DESTDIR)$(sbindir)/iodined
25         chmod 755 $(DESTDIR)$(sbindir)/iodined
26         $(MKDIR) $(MKDIR_FLAGS) $(DESTDIR)$(mandir)/man8
27         $(INSTALL) $(INSTALL_FLAGS) man/iodine.8 $(DESTDIR)$(mandir)/man8/iodine.8
28         chmod 644 $(DESTDIR)$(mandir)/man8/iodine.8
29
30 uninstall:
31         $(RM) $(RM_FLAGS) $(DESTDIR)$(sbindir)/iodine
32         $(RM) $(RM_FLAGS) $(DESTDIR)$(sbindir)/iodined
33         $(RM) $(RM_FLAGS) $(DESTDIR)$(mandir)/man8/iodine.8
34         
35 test: all
36         @echo "!! The check library is required for compiling and running the tests"
37         @echo "!! Get it at http://check.sf.net"
38         @(cd tests; make all)
39
40 clean:
41         @echo "Cleaning..."
42         @(cd src; $(MAKE) clean)
43         @(cd tests; $(MAKE) clean)
44         @rm -rf bin
45