updates.
[silc.git] / Makefile.am.pre
1 #
2 #  Makefile.am
3 #
4 #  Author: Pekka Riikonen <priikone@poseidon.pspt.fi>
5 #
6 #  Copyright (C) 2000 - 2001 Pekka Riikonen
7 #
8 #  This program is free software; you can redistribute it and/or modify
9 #  it under the terms of the GNU General Public License as published by
10 #  the Free Software Foundation; either version 2 of the License, or
11 #  (at your option) any later version.
12 #
13 #  This program is distributed in the hope that it will be useful,
14 #  but WITHOUT ANY WARRANTY; without even the implied warranty of
15 #  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
16 #  GNU General Public License for more details.
17 #
18
19 AUTOMAKE_OPTIONS = 1.0 no-dependencies foreign
20
21 SUBDIRS = lib irssi silc silcd doc includes
22 DIST_SUBDIRS = SILC_DISTRIBUTION_SUBDIRS
23
24 include $(top_srcdir)/Makefile.defines
25
26 dist-bzip: distdir
27         -chmod -R a+r $(distdir)
28         -$(TAR) chof $(distdir).tar $(distdir)
29         -bzip2 $(distdir).tar
30         -rm -rf $(distdir)
31
32 EXTRA_DIST = CHANGES CREDITS
33
34 #
35 # Installing of SILC into the system
36 #
37
38 etcdir = $(silc_etcdir)
39 modulesdir = $(silc_modulesdir)
40 helpdir = $(silc_helpdir)
41 docdir = $(silc_docdir)
42 logsdir = $(silc_logsdir)
43
44 install-dirs:
45         -mkdir -p $(etcdir)
46         -mkdir -p $(modulesdir)
47         -mkdir -p $(helpdir)
48         -mkdir -p $(docdir)
49         -mkdir -p $(logsdir)
50
51 generate-server-key:
52         -$(sbindir)/silcd -C $(etcdir)
53
54 sim-install:
55         -cp -fR $(srcdir)/lib/silcsim/modules/*.so $(modulesdir)/
56
57 doc-install:
58         $(INSTALL_DATA) $(srcdir)/doc/CodingStyle $(docdir)/
59         $(INSTALL_DATA) $(srcdir)/doc/FAQ $(docdir)/
60         $(INSTALL_DATA) $(srcdir)/doc/example* $(docdir)/
61         $(INSTALL_DATA) $(srcdir)/doc/*.txt $(docdir)/
62         $(INSTALL_DATA) $(srcdir)/COPYING $(docdir)/
63         $(INSTALL_DATA) $(srcdir)/CHANGES $(docdir)/
64         $(INSTALL_DATA) $(srcdir)/CREDITS $(docdir)/
65         $(INSTALL_DATA) $(srcdir)/README $(docdir)/
66         $(INSTALL_DATA) $(srcdir)/INSTALL $(docdir)/
67         $(INSTALL_DATA) $(srcdir)/TODO $(docdir)/
68
69 etc-install:
70         -@if test '!' -f $(etcdir)/silcd.conf ; then \
71           $(INSTALL_DATA) $(srcdir)/doc/example_silcd.conf \
72           $(etcdir)/silcd.conf; \
73           chmod go= $(etcdir)/silcd.conf; \
74         fi
75         -@if test '!' -f $(etcdir)/silc.conf ; then \
76           $(INSTALL_DATA) $(srcdir)/doc/example_silc.conf \
77           $(etcdir)/silc.conf; \
78         fi
79
80 install-data-hook: install-dirs generate-server-key sim-install doc-install etc-install