The Autodist environment added.
[silc.git] / doc / Makefile.ad
similarity index 80%
rename from doc/Makefile.am.pre
rename to doc/Makefile.ad
index b63eb061adbbaec0ba913df5f558edc8a0264124..834caf10fa1a9ce4c9d328522401a925c9903554 100644 (file)
@@ -1,14 +1,13 @@
 #
-#  Makefile.am
+#  Makefile.ad
 #
-#  Author: Pekka Riikonen <priikone@poseidon.pspt.fi>
+#  Author: Pekka Riikonen <priikone@silcnet.org>
 #
-#  Copyright (C) 2000 - 2001 Pekka Riikonen
+#  Copyright (C) 2000 - 2005 Pekka Riikonen
 #
 #  This program is free software; you can redistribute it and/or modify
 #  it under the terms of the GNU General Public License as published by
-#  the Free Software Foundation; either version 2 of the License, or
-#  (at your option) any later version.
+#  the Free Software Foundation; version 2 of the License.
 #
 #  This program is distributed in the hope that it will be useful,
 #  but WITHOUT ANY WARRANTY; without even the implied warranty of
 
 AUTOMAKE_OPTIONS = 1.0 no-dependencies foreign
 
-COMMONDIRS = .
-SUBDIRS = SILC_DISTRIBUTION_SUBDIRS
-DIST_SUBDIRS = SILC_DISTRIBUTION_SUBDIRS
-makerfc = ../scripts/makerfc
-
 all:
        touch draft-riikonen-silc-spec-08.txt
        touch draft-riikonen-silc-pp-09.txt
@@ -31,7 +25,9 @@ all:
        touch draft-riikonen-silc-flags-payloads-04.txt
        touch draft-riikonen-presence-attrs-03.txt
 
-if SILC_DIST_TOOLKIT
+#ifdef SILC_DIST_TOOLKIT
+makerfc = $(SILC_TOP_SRCDIR)/scripts/makerfc
+
 toolkit-ref-html:
        -@if test -f $(SILC_TOP_SRCDIR)/util/robodoc/Source/robodoc ; then \
          echo Generating Toolkit Reference Manual ; \
@@ -55,6 +51,7 @@ toolkit-ref-pdf:
         fi
 
 dist-hook:
+       rm -rf `find $(top_distdir)/doc -name CVS`
        $(SILC_TOP_SRCDIR)/scripts/manpages.pl
        touch draft-riikonen-silc-spec-08.txt
        touch draft-riikonen-silc-pp-09.txt
@@ -75,8 +72,9 @@ dist-hook:
        $(makerfc) draft-riikonen-presence-attrs-03.nroff \
                draft-riikonen-presence-attrs-03.txt
 
-else
+#else !SILC_DIST_TOOLKIT
 dist-hook:
+       rm -rf `find $(top_distdir)/doc -name CVS`
        $(SILC_TOP_SRCDIR)/scripts/manpages.pl
        rm draft-riikonen*.txt
        touch draft-riikonen-silc-spec-08.txt
@@ -85,21 +83,20 @@ dist-hook:
        touch draft-riikonen-silc-commands-06.txt
        touch draft-riikonen-silc-flags-payloads-04.txt
        touch draft-riikonen-presence-attrs-03.txt
-endif
-
-if SILC_DIST_TOOLKIT
-SILC_EXTRA_DIST = toolkit examples silc.1 silcd.8 silcd.conf.5
-else
-if SILC_DIST_SERVER
-SILC_EXTRA_DIST = examples silcd.8 silcd.conf.5
-else
-SILC_EXTRA_DIST = silc.1
-endif
-endif
+#endif SILC_DIST_TOOLKIT
 
-EXTRA_DIST = \
-       CodingStyle \
-       FAQ \
-       example_silcd.conf \
-       silcalgs.conf \
-       draft-riikonen*.txt $(SILC_EXTRA_DIST)
+EXTRA_DIST =                   \
+#ifdef SILC_DIST_CLIENT
+       silc.1                  \
+#endif SILC_DIST_CLIENT
+#ifdef SILC_DIST_SERVER
+       examples silcd.8 silcd.conf.5   \
+#endif SILC_DIST_SERVER
+#ifdef SILC_DIST_TOOLKIT
+       toolkit                 \
+#endif SILC_DIST_TOOLKIT
+       CodingStyle             \
+       FAQ                     \
+       example_silcd.conf      \
+       silcalgs.conf           \
+       draft-riikonen*.txt