1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299
|
# Copyright (C) 1999, 2000, 2001, 2002 Lorenzo Bettini <bettini@gnu.org>
#
# This file is free software; as a special exception the author gives
# unlimited permission to copy and/or distribute it, with or without
# modifications, as long as this notice is preserved.
#
# This program is distributed in the hope that it will be useful, but
# WITHOUT ANY WARRANTY, to the extent permitted by law; without even the
# implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
TAGS_J2H_OPTION = -f html --tags-file $(top_srcdir)/src/tags.j2h
# we disable the generation of the version of source-highlight
# so that the version does not interfere with the diffing
PROGNAME = $(top_builddir)/src/$(PACKAGE)$(EXEEXT) --gen-version
JAVA2HTML = $(PROGNAME) -s java $(TAGS_J2H_OPTION)
JS2HTML = $(PROGNAME) -s javascript $(TAGS_J2H_OPTION)
JAVA2XHTML = $(PROGNAME) -s java -f xhtml --tags-file $(top_srcdir)/src/tags.j2h --doc
JAVA2ESC = $(PROGNAME) -s java -f esc --tags-file=$(srcdir)/tags.esc --doc
# this refers to an "absolute" path (../doc/) without using the automake
# variables. However this way the generated files will always be the
# same so tests won't fail. You may have some problems if you want to
# view the generated file, test_css.html, and you are building in a
# different directory. However this is not the spirit of the test :-)
# the important thing is that the generated file is always the same.
JAVA2HTMLCSS = $(PROGNAME) -s java -f html --css ../doc/mono.css
JAVA2HTMLCSSNODOC = $(PROGNAME) -s java -f html --css ../doc/mono.css --no-doc
CPP2HTML = $(PROGNAME) -s cpp $(TAGS_J2H_OPTION)
PROLOG2HTML = $(PROGNAME) -s prolog $(TAGS_J2H_OPTION)
PERL2HTML = $(PROGNAME) -s perl $(TAGS_J2H_OPTION)
PHP32HTML = $(PROGNAME) -s php3 $(TAGS_J2H_OPTION)
PYTHON2HTML = $(PROGNAME) -s python $(TAGS_J2H_OPTION)
FLEX2HTML = $(PROGNAME) -s flex $(TAGS_J2H_OPTION)
CHANGELOG2HTML = $(PROGNAME) -s changelog $(TAGS_J2H_OPTION)
CHANGELOG2HTMLCSS = $(PROGNAME) -s changelog -f html --css ./changelog.css --title="ChangeLog with css"
RUBY2HTML = $(PROGNAME) -s ruby $(TAGS_J2H_OPTION)
LUA2HTML = $(PROGNAME) -s lua $(TAGS_J2H_OPTION)
CAML2HTML = $(PROGNAME) -s caml $(TAGS_J2H_OPTION)
SML2HTML = $(PROGNAME) -s sml $(TAGS_J2H_OPTION)
LOG2HTML = $(PROGNAME) -s log -f html --tags-file=$(srcdir)/tags.syslog
EXTRA_DIST = test.java test.java.html test.js test.js.html test.h test.h.html \
test_comments.cc test_comments.cc.html test_comments.java \
test_comments.java.html test_template.cc test_template.cc.html \
test.pl test.pl.html header.html footer.html test_header.html \
test_java_lines.html test_cpp_lines.html test_pl_lines.html \
test.pm test_comments.pm test.pm.html test_comments.pm.html \
test_perl_lines.html \
test.php3 test.php3.html test_php3_lines.html \
test.py test.py.html test_python_lines.html \
test_comments.py test_comments.py.html test_py_comments_lines.html \
test_xhtml.html test_css.html test_css_nodoc.html \
test.chlog test.chlog.html test.chlog_css.html \
test.l test.l.html \
test.rb test_comments.rb test.rb.html test_comments.rb.html \
test.java.txt \
test.lua test.lua.html \
test.ml test.ml.html \
test.sml test.sml.html \
test.log test.log.html \
access.log access.log.html \
auth.log auth.log.html \
error.log error.log.html \
syslog.log syslog.log.html \
tags.syslog tags.esc \
changelog.css
%.cc.html: %.cc
$(CPP2HTML) $<
%.h.html: %.h
$(CPP2HTML) $<
%.java.html: %.java
$(JAVA2HTML) $<
%.js.html: %.js
$(JS2HTML) $<
%.java.txt: %.java
$(JAVA2ESC) --line-number $<
%.pl.html: %.pl
$(PROLOG2HTML) $<
%.pm.html: %.pm
$(PERL2HTML) $<
%.php3.html: %.php3
$(PHP32HTML) $<
%.py.html: %.py
$(PYTHON2HTML) $<
%.chlog.html: %.chlog
$(CHANGELOG2HTML) $<
%.chlog_css.html: %.chlog
$(CHANGELOG2HTMLCSS) -i $< > $@
%.l.html: %.l
$(FLEX2HTML) $<
%.rb.html: %.rb
$(RUBY2HTML) $<
%.lua.html: %.lua
$(LUA2HTML) $<
%.ml.html: %.ml
$(CAML2HTML) $<
%.sml.html: %.sml
$(SML2HTML) $<
%.log.html: %.log
$(LOG2HTML) $<
CPP2HTML_WHEADERS = $(CPP2HTML) --header=$(srcdir)/header.html --footer=$(srcdir)/footer.html --title="Header and footer test"
test_header.html: test.h
$(CPP2HTML_WHEADERS) -i test.h -o $@
test_java_lines.html: test.java
$(JAVA2HTML) --line-number-ref -i test.java -o $@
test_xhtml.html: test.java
$(JAVA2XHTML) < test.java > $@
test_css.html: test.java
$(JAVA2HTMLCSS) < test.java > $@
test_css_nodoc.html: test.java
$(JAVA2HTMLCSSNODOC) < test.java > $@
test_cpp_lines.html: test.h
$(CPP2HTML) --line-number -i test.h -o $@
test_pl_lines.html: test.pl
$(PROLOG2HTML) --line-number -i test.pl -o $@
test_perl_lines.html: test.pm
$(PERL2HTML) --line-number -i test.pm -o $@
test_php3_lines.html: test.php3
$(PHP32HTML) --line-number -i test.php3 -o $@
test_python_lines.html: test.py
$(PYTHON2HTML) --line-number -i test.py -o $@
test_py_comments_lines.html: test_comments.py
$(PYTHON2HTML) --line-number -i test_comments.py -o $@
check: check_java2html check_cpp2html check_prolog2html check_perl2html \
check_php32html check_python2html check_changelog check_flex \
check_ruby check_lua check_ml check_sml check_log
check_java2html: test.java.html test.js.html test.java.txt test_xhtml.html test_css.html test_css_nodoc.html test_comments.java.html test_java_lines.html
$(JAVA2HTML) < $(srcdir)/test.java > test.java.out.html
$(JS2HTML) < $(srcdir)/test.js > test.js.out.html
$(JAVA2XHTML) < $(srcdir)/test.java > test_xhtml.out.html
$(JAVA2HTMLCSS) < $(srcdir)/test.java > test_css.out.html
$(JAVA2HTMLCSSNODOC) < $(srcdir)/test.java > test_css_nodoc.out.html
$(JAVA2HTML) < $(srcdir)/test_comments.java > test_comments.java.out.html
$(JAVA2HTML) -n --line-number-ref -i $(srcdir)/test.java -o test_java_lines.out.html
$(JAVA2ESC) -n -i $(srcdir)/test.java -o test.java.out.txt
@echo expect no output from diff
diff $(srcdir)/test.java.html test.java.out.html
diff $(srcdir)/test.js.html test.js.out.html
diff $(srcdir)/test_xhtml.html test_xhtml.out.html
diff $(srcdir)/test_css.html test_css.out.html
diff $(srcdir)/test_css_nodoc.html test_css_nodoc.out.html
diff $(srcdir)/test_comments.java.html test_comments.java.out.html
diff $(srcdir)/test_java_lines.html test_java_lines.out.html
diff $(srcdir)/test.java.txt test.java.out.txt
check_cpp2html: test.h.html test_comments.cc.html test_template.cc.html test_header.html test_cpp_lines.html
$(CPP2HTML) < $(srcdir)/test.h > test.h.out.html
$(CPP2HTML) < $(srcdir)/test_comments.cc > test_comments.cc.out.html
$(CPP2HTML) < $(srcdir)/test_template.cc > test_template.cc.out.html
$(CPP2HTML_WHEADERS) -i $(srcdir)/test.h -o test_header.out.html
$(CPP2HTML) -n -i $(srcdir)/test.h -o test_cpp_lines.out.html
@echo expect no output from diff
diff $(srcdir)/test.h.html test.h.out.html
diff $(srcdir)/test_comments.cc.html test_comments.cc.out.html
diff $(srcdir)/test_template.cc.html test_template.cc.out.html
diff $(srcdir)/test_header.html test_header.out.html
diff $(srcdir)/test_cpp_lines.html test_cpp_lines.out.html
check_prolog2html: test.pl.html test_pl_lines.html
$(PROLOG2HTML) < $(srcdir)/test.pl > test.pl.out.html
$(PROLOG2HTML) -n -i $(srcdir)/test.pl -o test_pl_lines.out.html
@echo expect no output from diff
diff $(srcdir)/test.pl.html test.pl.out.html
diff $(srcdir)/test_pl_lines.html test_pl_lines.out.html
check_perl2html: test.pm.html test_comments.pm.html test_perl_lines.html
$(PERL2HTML) < $(srcdir)/test.pm > test.pm.out.html
$(PERL2HTML) < $(srcdir)/test_comments.pm > test_comments.pm.out.html
$(PERL2HTML) -n -i $(srcdir)/test.pm -o test_perl_lines.out.html
@echo expect no output from diff
diff $(srcdir)/test.pm.html test.pm.out.html
diff $(srcdir)/test_comments.pm.html test_comments.pm.out.html
diff $(srcdir)/test_perl_lines.html test_perl_lines.out.html
check_php32html: test.php3.html test_php3_lines.html
$(PHP32HTML) < $(srcdir)/test.php3 > test.php3.out.html
$(PHP32HTML) -n -i $(srcdir)/test.php3 -o test_php3_lines.out.html
@echo expect no output from diff
diff $(srcdir)/test.php3.html test.php3.out.html
diff $(srcdir)/test_php3_lines.html test_php3_lines.out.html
check_python2html: test.py.html test_python_lines.html test_comments.py.html test_py_comments_lines.html
$(PYTHON2HTML) < $(srcdir)/test.py > test.py.out.html
$(PYTHON2HTML) < $(srcdir)/test_comments.py > test_comments.py.out.html
$(PYTHON2HTML) -n -i $(srcdir)/test.py -o test_python_lines.out.html
$(PYTHON2HTML) -n -i $(srcdir)/test_comments.py -o test_py_comments_lines.out.html
@echo expect no output from diff
diff $(srcdir)/test.py.html test.py.out.html
diff $(srcdir)/test_comments.py.html test_comments.py.out.html
diff $(srcdir)/test_python_lines.html test_python_lines.out.html
diff $(srcdir)/test_py_comments_lines.html test_py_comments_lines.out.html
check_changelog: test.chlog.html test.chlog_css.html
$(CHANGELOG2HTML) < $(srcdir)/test.chlog > test.chlog.out.html
$(CHANGELOG2HTMLCSS) -i $(srcdir)/test.chlog > test.chlog_css.out.html
@echo expect no output from diff
diff $(srcdir)/test.chlog.html test.chlog.out.html
diff $(srcdir)/test.chlog_css.html test.chlog_css.out.html
check_flex: test.l.html
$(FLEX2HTML) < $(srcdir)/test.l > test.l.out.html
@echo expect no output from diff
diff $(srcdir)/test.l.html test.l.out.html
check_ruby: test.rb.html test_comments.rb.html
$(RUBY2HTML) < $(srcdir)/test.rb > test.rb.out.html
$(RUBY2HTML) < $(srcdir)/test_comments.rb > test_comments.rb.out.html
@echo expect no output from diff
diff $(srcdir)/test.rb.html test.rb.out.html
diff $(srcdir)/test_comments.rb.html test_comments.rb.out.html
check_lua: test.lua.html
$(LUA2HTML) < $(srcdir)/test.lua > test.lua.out.html
@echo expect no output from diff
diff $(srcdir)/test.lua.html test.lua.out.html
check_ml: test.ml.html
$(CAML2HTML) < $(srcdir)/test.ml > test.ml.out.html
@echo expect no output from diff
diff $(srcdir)/test.ml.html test.ml.out.html
check_sml: test.sml.html
$(SML2HTML) < $(srcdir)/test.sml > test.sml.out.html
@echo expect no output from diff
diff $(srcdir)/test.sml.html test.sml.out.html
check_log: test.log.html
$(LOG2HTML) < $(srcdir)/test.log > test.log.out.html
$(LOG2HTML) < $(srcdir)/access.log > access.log.out.html
$(LOG2HTML) < $(srcdir)/auth.log > auth.log.out.html
$(LOG2HTML) < $(srcdir)/error.log > error.log.out.html
$(LOG2HTML) < $(srcdir)/syslog.log > syslog.log.out.html
@echo expect no output from diff
diff $(srcdir)/test.log.html test.log.out.html
diff $(srcdir)/access.log.html access.log.out.html
diff $(srcdir)/auth.log.html auth.log.out.html
diff $(srcdir)/error.log.html error.log.out.html
diff $(srcdir)/syslog.log.html syslog.log.out.html
source_highlightdoc_DATA = test.php3.html test.pl.html test.pm.html \
test.py.html test.rb.html test.js.html test.lua.html test.ml.html \
test.sml.html test.log.html access.log.html auth.log.html error.log.html syslog.log.html \
tags.syslog tags.esc
CLEANFILES = *.out.html *.out.txt
clean_html:
rm -f *.h.html *.java.html *.cc.html *.pl.html *.pm.html *.php3.html *.py.html *.chlog.html *.l.html test_xhtml.html test_css.html test_css_nodoc.html test_header.html *.rb.html *.js.html *.java.txt *.lua.html *.ml.html *.sml.html test_*_lines.html *.log.html
|