gmyth-upnp/aminclude.am
author morphbr
Fri Mar 30 23:07:54 2007 +0100 (2007-03-30)
branchtrunk
changeset 471 2eef40885322
permissions -rw-r--r--
[svn r476] * GMyth-Stream:
- Bug fixes
- Improved error handling
- Created Mencoder plugin
melunko@249
     1
# Copyright (C) 2004 Oren Ben-Kiki
melunko@249
     2
# This file is distributed under the same terms as the Automake macro files.
melunko@249
     3
melunko@249
     4
# Generate automatic documentation using Doxygen. Goals and variables values
melunko@249
     5
# are controlled by the various DX_COND_??? conditionals set by autoconf.
melunko@249
     6
#
melunko@249
     7
# The provided goals are:
melunko@249
     8
# doxygen-doc: Generate all doxygen documentation.
melunko@249
     9
# doxygen-run: Run doxygen, which will generate some of the documentation
melunko@249
    10
#              (HTML, CHM, CHI, MAN, RTF, XML) but will not do the post
melunko@249
    11
#              processing required for the rest of it (PS, PDF, and some MAN).
melunko@249
    12
# doxygen-man: Rename some doxygen generated man pages.
melunko@249
    13
# doxygen-ps: Generate doxygen PostScript documentation.
melunko@249
    14
# doxygen-pdf: Generate doxygen PDF documentation.
melunko@249
    15
#
melunko@249
    16
# Note that by default these are not integrated into the automake goals. If
melunko@249
    17
# doxygen is used to generate man pages, you can achieve this integration by
melunko@249
    18
# setting man3_MANS to the list of man pages generated and then adding the
melunko@249
    19
# dependency:
melunko@249
    20
#
melunko@249
    21
#   $(man3_MANS): doxygen-doc
melunko@249
    22
#
melunko@249
    23
# This will cause make to run doxygen and generate all the documentation.
melunko@249
    24
#
melunko@249
    25
# The following variable is intended for use in Makefile.am:
melunko@249
    26
#
melunko@249
    27
# DX_CLEANFILES = everything to clean.
melunko@249
    28
#
melunko@249
    29
# This is usually added to MOSTLYCLEANFILES.
melunko@249
    30
melunko@249
    31
## --------------------------------- ##
melunko@249
    32
## Format-independent Doxygen rules. ##
melunko@249
    33
## --------------------------------- ##
melunko@249
    34
melunko@249
    35
if DX_COND_doc
melunko@249
    36
melunko@249
    37
## ------------------------------- ##
melunko@249
    38
## Rules specific for HTML output. ##
melunko@249
    39
## ------------------------------- ##
melunko@249
    40
melunko@249
    41
if DX_COND_html
melunko@249
    42
melunko@249
    43
DX_CLEAN_HTML = @DX_DOCDIR@/html
melunko@249
    44
melunko@249
    45
endif DX_COND_html
melunko@249
    46
melunko@249
    47
## ------------------------------ ##
melunko@249
    48
## Rules specific for CHM output. ##
melunko@249
    49
## ------------------------------ ##
melunko@249
    50
melunko@249
    51
if DX_COND_chm
melunko@249
    52
melunko@249
    53
DX_CLEAN_CHM = @DX_DOCDIR@/chm
melunko@249
    54
melunko@249
    55
if DX_COND_chi
melunko@249
    56
melunko@249
    57
DX_CLEAN_CHI = @DX_DOCDIR@/@PACKAGE@.chi
melunko@249
    58
melunko@249
    59
endif DX_COND_chi
melunko@249
    60
melunko@249
    61
endif DX_COND_chm
melunko@249
    62
melunko@249
    63
## ------------------------------ ##
melunko@249
    64
## Rules specific for MAN output. ##
melunko@249
    65
## ------------------------------ ##
melunko@249
    66
melunko@249
    67
if DX_COND_man
melunko@249
    68
melunko@249
    69
DX_CLEAN_MAN = @DX_DOCDIR@/man
melunko@249
    70
melunko@249
    71
endif DX_COND_man
melunko@249
    72
melunko@249
    73
## ------------------------------ ##
melunko@249
    74
## Rules specific for RTF output. ##
melunko@249
    75
## ------------------------------ ##
melunko@249
    76
melunko@249
    77
if DX_COND_rtf
melunko@249
    78
melunko@249
    79
DX_CLEAN_RTF = @DX_DOCDIR@/rtf
melunko@249
    80
melunko@249
    81
endif DX_COND_rtf
melunko@249
    82
melunko@249
    83
## ------------------------------ ##
melunko@249
    84
## Rules specific for XML output. ##
melunko@249
    85
## ------------------------------ ##
melunko@249
    86
melunko@249
    87
if DX_COND_xml
melunko@249
    88
melunko@249
    89
DX_CLEAN_XML = @DX_DOCDIR@/xml
melunko@249
    90
melunko@249
    91
endif DX_COND_xml
melunko@249
    92
melunko@249
    93
## ----------------------------- ##
melunko@249
    94
## Rules specific for PS output. ##
melunko@249
    95
## ----------------------------- ##
melunko@249
    96
melunko@249
    97
if DX_COND_ps
melunko@249
    98
melunko@249
    99
DX_CLEAN_PS = @DX_DOCDIR@/@PACKAGE@.ps
melunko@249
   100
melunko@249
   101
DX_PS_GOAL = doxygen-ps
melunko@249
   102
melunko@249
   103
doxygen-ps: @DX_DOCDIR@/@PACKAGE@.ps
melunko@249
   104
melunko@249
   105
@DX_DOCDIR@/@PACKAGE@.ps: @DX_DOCDIR@/@PACKAGE@.tag
melunko@249
   106
	cd @DX_DOCDIR@/latex; \
melunko@249
   107
	rm -f *.aux *.toc *.idx *.ind *.ilg *.log *.out; \
melunko@249
   108
	$(DX_LATEX) refman.tex; \
melunko@249
   109
	$(MAKEINDEX_PATH) refman.idx; \
melunko@249
   110
	$(DX_LATEX) refman.tex; \
melunko@249
   111
	countdown=5; \
melunko@249
   112
	while $(DX_EGREP) 'Rerun (LaTeX|to get cross-references right)' \
melunko@249
   113
	                  refman.log > /dev/null 2>&1 \
melunko@249
   114
	   && test $$countdown -gt 0; do \
melunko@249
   115
	    $(DX_LATEX) refman.tex; \
melunko@249
   116
	    countdown=`expr $$countdown - 1`; \
melunko@249
   117
	done; \
melunko@249
   118
	$(DX_DVIPS) -o ../@PACKAGE@.ps refman.dvi
melunko@249
   119
melunko@249
   120
endif DX_COND_ps
melunko@249
   121
melunko@249
   122
## ------------------------------ ##
melunko@249
   123
## Rules specific for PDF output. ##
melunko@249
   124
## ------------------------------ ##
melunko@249
   125
melunko@249
   126
if DX_COND_pdf
melunko@249
   127
melunko@249
   128
DX_CLEAN_PDF = @DX_DOCDIR@/@PACKAGE@.pdf
melunko@249
   129
melunko@249
   130
DX_PDF_GOAL = doxygen-pdf
melunko@249
   131
melunko@249
   132
doxygen-pdf: @DX_DOCDIR@/@PACKAGE@.pdf
melunko@249
   133
melunko@249
   134
@DX_DOCDIR@/@PACKAGE@.pdf: @DX_DOCDIR@/@PACKAGE@.tag
melunko@249
   135
	cd @DX_DOCDIR@/latex; \
melunko@249
   136
	rm -f *.aux *.toc *.idx *.ind *.ilg *.log *.out; \
melunko@249
   137
	$(DX_PDFLATEX) refman.tex; \
melunko@249
   138
	$(DX_MAKEINDEX) refman.idx; \
melunko@249
   139
	$(DX_PDFLATEX) refman.tex; \
melunko@249
   140
	countdown=5; \
melunko@249
   141
	while $(DX_EGREP) 'Rerun (LaTeX|to get cross-references right)' \
melunko@249
   142
	                  refman.log > /dev/null 2>&1 \
melunko@249
   143
	   && test $$countdown -gt 0; do \
melunko@249
   144
	    $(DX_PDFLATEX) refman.tex; \
melunko@249
   145
	    countdown=`expr $$countdown - 1`; \
melunko@249
   146
	done; \
melunko@249
   147
	mv refman.pdf ../@PACKAGE@.pdf
melunko@249
   148
melunko@249
   149
endif DX_COND_pdf
melunko@249
   150
melunko@249
   151
## ------------------------------------------------- ##
melunko@249
   152
## Rules specific for LaTeX (shared for PS and PDF). ##
melunko@249
   153
## ------------------------------------------------- ##
melunko@249
   154
melunko@249
   155
if DX_COND_latex
melunko@249
   156
melunko@249
   157
DX_CLEAN_LATEX = @DX_DOCDIR@/latex
melunko@249
   158
melunko@249
   159
endif DX_COND_latex
melunko@249
   160
melunko@249
   161
.PHONY: doxygen-run doxygen-doc $(DX_PS_GOAL) $(DX_PDF_GOAL)
melunko@249
   162
melunko@249
   163
.INTERMEDIATE: doxygen-run $(DX_PS_GOAL) $(DX_PDF_GOAL)
melunko@249
   164
melunko@249
   165
doxygen-run: @DX_DOCDIR@/@PACKAGE@.tag
melunko@249
   166
melunko@249
   167
doxygen-doc: doxygen-run $(DX_PS_GOAL) $(DX_PDF_GOAL)
melunko@249
   168
melunko@249
   169
@DX_DOCDIR@/@PACKAGE@.tag: $(DX_CONFIG) $(pkginclude_HEADERS)
melunko@249
   170
	rm -rf @DX_DOCDIR@
melunko@249
   171
	$(DX_ENV) $(DX_DOXYGEN) $(srcdir)/$(DX_CONFIG)
melunko@249
   172
melunko@249
   173
DX_CLEANFILES = \
melunko@249
   174
    @DX_DOCDIR@/@PACKAGE@.tag \
melunko@249
   175
    -r \
melunko@249
   176
    $(DX_CLEAN_HTML) \
melunko@249
   177
    $(DX_CLEAN_CHM) \
melunko@249
   178
    $(DX_CLEAN_CHI) \
melunko@249
   179
    $(DX_CLEAN_MAN) \
melunko@249
   180
    $(DX_CLEAN_RTF) \
melunko@249
   181
    $(DX_CLEAN_XML) \
melunko@249
   182
    $(DX_CLEAN_PS) \
melunko@249
   183
    $(DX_CLEAN_PDF) \
melunko@249
   184
    $(DX_CLEAN_LATEX)
melunko@249
   185
melunko@249
   186
endif DX_COND_doc