~ubuntu-branches/ubuntu/trusty/libtasn1-3/trusty

« back to all changes in this revision

Viewing changes to doc/Makefile.am

  • Committer: Bazaar Package Importer
  • Author(s): Andreas Metzler
  • Date: 2006-06-07 20:14:52 UTC
  • Revision ID: james.westby@ubuntu.com-20060607201452-7a9dojyu7i2kfbyp
Tags: upstream-0.3.4
ImportĀ upstreamĀ versionĀ 0.3.4

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
## Process this file with automake to produce Makefile.in
 
2
# Copyright (C) 2002, 2003, 2004, 2005, 2006 Free Software Foundation
 
3
#
 
4
# This file is part of LIBTASN1.
 
5
#
 
6
# This file is free software; you can redistribute it and/or modify it
 
7
# under the terms of the GNU General Public License as published by
 
8
# the Free Software Foundation; either version 2 of the License, or
 
9
# (at your option) any later version.
 
10
#
 
11
# This file is distributed in the hope that it will be useful, but
 
12
# WITHOUT ANY WARRANTY; without even the implied warranty of
 
13
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
 
14
# General Public License for more details.
 
15
#
 
16
# You should have received a copy of the GNU General Public License
 
17
# along with this file; if not, write to the Free Software Foundation,
 
18
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
 
19
 
 
20
if ENABLE_GTK_DOC
 
21
SUBDIRS = reference
 
22
endif
 
23
 
 
24
EXTRA_DIST = gdoc TODO libtasn1.html libtasn1.ps libtasn1.pdf
 
25
 
 
26
info_TEXINFOS = libtasn1.texi
 
27
libtasn1_TEXINFOS = fdl.texi $(gdoc_TEXINFOS)
 
28
 
 
29
AM_MAKEINFOFLAGS = -I $(top_builddir)/doc
 
30
AM_MAKEINFOHTMLFLAGS = --no-split
 
31
 
 
32
dist_man_MANS = $(gdoc_MANS) asn1Parser.1 asn1Coding.1 asn1Decoding.1
 
33
 
 
34
HELP2MAN_OPTS = --info-page libtasn1
 
35
 
 
36
asn1Parser.1: $(top_srcdir)/src/asn1Parser.c $(top_srcdir)/configure.in
 
37
        $(HELP2MAN) $(HELP2MAN_OPTS) \
 
38
                --name="ASN.1 syntax tree generator for libtasn1" \
 
39
                --output=$@ $(top_builddir)/src/asn1Parser$(EXEEXT)
 
40
 
 
41
asn1Coding.1: $(top_srcdir)/src/asn1Coding.c $(top_srcdir)/configure.in
 
42
        $(HELP2MAN) $(HELP2MAN_OPTS) \
 
43
                --name="ASN.1 DER encoder" \
 
44
                --output=$@ $(top_builddir)/src/asn1Coding$(EXEEXT)
 
45
 
 
46
asn1Decoding.1: $(top_srcdir)/src/asn1Decoding.c $(top_srcdir)/configure.in
 
47
        $(HELP2MAN) $(HELP2MAN_OPTS) \
 
48
                --name="ASN.1 DER decoder" \
 
49
                --output=$@ $(top_builddir)/src/asn1Decoding$(EXEEXT)
 
50
 
 
51
gdoc_MANS = man/asn1_get_length_der.3 man/asn1_get_tag_der.3 man/asn1_get_octet_der.3 man/asn1_get_bit_der.3 man/asn1_der_decoding.3 man/asn1_der_decoding_element.3 man/asn1_der_decoding_startEnd.3 man/asn1_expand_any_defined_by.3 man/asn1_expand_octet_string.3 man/libtasn1_perror.3 man/libtasn1_strerror.3 man/asn1_find_node.3 man/asn1_check_version.3 man/asn1_length_der.3 man/asn1_octet_der.3 man/asn1_bit_der.3 man/asn1_der_coding.3 man/asn1_write_value.3 man/asn1_read_value.3 man/asn1_read_tag.3 man/asn1_array2tree.3 man/asn1_delete_structure.3 man/asn1_delete_element.3 man/asn1_create_element.3 man/asn1_print_structure.3 man/asn1_number_of_elements.3 man/asn1_find_structure_from_oid.3 man/asn1_copy_node.3 man/asn1_parser2tree.3 man/asn1_parser2array.3
 
52
gdoc_TEXINFOS = texi/decoding.c.texi texi/errors.c.texi texi/parser_aux.c.texi texi/coding.c.texi texi/element.c.texi texi/gstr.c.texi texi/structure.c.texi texi/ASN1.c.texi texi/asn1_get_length_der.texi texi/asn1_get_tag_der.texi texi/asn1_get_octet_der.texi texi/asn1_get_bit_der.texi texi/asn1_der_decoding.texi texi/asn1_der_decoding_element.texi texi/asn1_der_decoding_startEnd.texi texi/asn1_expand_any_defined_by.texi texi/asn1_expand_octet_string.texi texi/libtasn1_perror.texi texi/libtasn1_strerror.texi texi/asn1_find_node.texi texi/asn1_check_version.texi texi/asn1_length_der.texi texi/asn1_octet_der.texi texi/asn1_bit_der.texi texi/asn1_der_coding.texi texi/asn1_write_value.texi texi/asn1_read_value.texi texi/asn1_read_tag.texi texi/asn1_array2tree.texi texi/asn1_delete_structure.texi texi/asn1_delete_element.texi texi/asn1_create_element.texi texi/asn1_print_structure.texi texi/asn1_number_of_elements.texi texi/asn1_find_structure_from_oid.texi texi/asn1_copy_node.texi texi/asn1_parser2tree.texi texi/asn1_parser2array.texi
 
53
 
 
54
$(gdoc_MANS) $(gdoc_TEXINFOS):
 
55
        make update-makefile
 
56
        make Makefile
 
57
        make doit
 
58
 
 
59
GDOC_SRC = $(top_srcdir)/lib/decoding.c $(top_srcdir)/lib/errors.c      \
 
60
        $(top_srcdir)/lib/parser_aux.c $(top_srcdir)/lib/coding.c       \
 
61
        $(top_srcdir)/lib/element.c $(top_srcdir)/lib/gstr.c            \
 
62
        $(top_srcdir)/lib/structure.c $(top_builddir)/lib/ASN1.c
 
63
 
 
64
update-makefile:
 
65
        @MANS=""; \
 
66
        TEXINFOS=""; \
 
67
        for i in $(GDOC_SRC); do \
 
68
                BASE=`basename $$i`; \
 
69
                TEXINFOS="$$TEXINFOS texi/$$BASE.texi"; \
 
70
        done; \
 
71
        FUNCS=`$(srcdir)/gdoc -listfunc $(GDOC_SRC)`; \
 
72
        for i in $$FUNCS; do \
 
73
                MANS="$$MANS man/$$i.3"; \
 
74
                TEXINFOS="$$TEXINFOS texi/$$i.texi"; \
 
75
        done; \
 
76
        perl -pi -e "s,^gdoc_MANS =.*,gdoc_MANS =$$MANS,;" \
 
77
                -e "s,^gdoc_TEXINFOS =.*,gdoc_TEXINFOS =$$TEXINFOS,;" \
 
78
                Makefile.am
 
79
 
 
80
doit:
 
81
        $(mkdir_p) man texi; \
 
82
        for i in `$(srcdir)/gdoc -listfunc $(GDOC_SRC)`; do \
 
83
                echo -n "Creating documentation for $$i... " && \
 
84
                $(srcdir)/gdoc -man \
 
85
                        -module $(PACKAGE) -sourceversion $(VERSION) \
 
86
                        -include libtasn1.h \
 
87
                        -seeinfo $(PACKAGE) -verbatimcopying \
 
88
                        -copyright "2001, 2002, 2003 Fabio Fiorina" \
 
89
                        -function $$i \
 
90
                        $(GDOC_SRC) > man/$$i.3 && \
 
91
                $(srcdir)/gdoc -texinfo -function $$i \
 
92
                        $(GDOC_SRC) > texi/$$i.texi && \
 
93
                echo "ok"; \
 
94
        done; \
 
95
        for i in $(GDOC_SRC); do \
 
96
                BASE=`basename $$i`; \
 
97
                echo -n "Creating documentation for $$i... " && \
 
98
                $(srcdir)/gdoc -texinfo $$i > texi/$$BASE.texi && \
 
99
                echo "ok"; \
 
100
        done
 
101
 
 
102
.PHONY: update-makefile doit