CHECK_PYTHON_CODE = $(top_srcdir)/autotools/check-python-code
CHECK_HEADER = $(top_srcdir)/autotools/check-header
CHECK_MAN_DASHES = $(top_srcdir)/autotools/check-man-dashes
+CHECK_MAN_REFERENCES = $(top_srcdir)/autotools/check-man-references
CHECK_MAN_WARNINGS = $(top_srcdir)/autotools/check-man-warnings
CHECK_VERSION = $(top_srcdir)/autotools/check-version
CHECK_NEWS = $(top_srcdir)/autotools/check-news
daemons \
devel \
doc \
+ doc/css \
doc/examples \
doc/examples/gnt-debug \
doc/examples/hooks \
APIDOC_HS_DIR = $(APIDOC_DIR)/hs
MAINTAINERCLEANFILES = \
- $(docpng) \
$(maninput) \
doc/install-quick.rst \
doc/news.rst \
lib/utils/wrapper.py \
lib/utils/x509.py
-docrst = \
+docinput = \
+ doc/conf.py \
+ doc/css/style.css \
doc/admin.rst \
doc/cluster-merge.rst \
doc/design-2.0.rst \
# has to exist in order for the sphinx module to be loaded
# successfully, but we certainly don't want the docs to be rebuilt if
# it changes
-doc/html/index.html: $(docrst) $(docpng) doc/conf.py configure.ac \
+doc/html/index.html: $(docinput) doc/conf.py configure.ac \
$(RUN_IN_TEMPDIR) lib/build/sphinx_ext.py \
lib/build/shell_example_lexer.py lib/opcodes.py lib/ht.py \
+ doc/css/style.css \
| $(BUILT_PYTHON_SOURCES)
@test -n "$(SPHINX)" || \
{ echo 'sphinx-build' not found during configure; exit 1; }
-d . \
-D version="$(VERSION_MAJOR).$(VERSION_MINOR)" \
-D release="$(PACKAGE_VERSION)" \
- $(abs_top_srcdir)/doc $(CURDIR)/doc/html
+ -D graphviz_dot="$(DOT)" \
+ $(abs_top_builddir)/doc $(CURDIR)/doc/html
rm -f doc/html/.buildinfo doc/html/objects.inv
touch $@
cat $<; \
} > $@
-docdot = \
- doc/arch-2.0.dot \
- doc/design-2.1-lock-acquire.dot \
- doc/design-2.1-lock-release.dot
-
-docpng = $(patsubst %.dot,%.png,$(docdot))
-
# Things to build but not to install (add it to EXTRA_DIST if it should be
# distributed)
noinst_DATA = \
autotools/check-header \
autotools/check-imports \
autotools/check-man-dashes \
+ autotools/check-man-references \
autotools/check-man-warnings \
autotools/check-news \
autotools/check-python-code \
daemons/ganeti-cleaner.in \
$(pkglib_python_scripts) \
devel/upload \
+ devel/webserver \
tools/kvm-ifup.in \
tools/vcluster-setup.in \
- $(docdot) \
- $(docpng) \
- $(docrst) \
- doc/conf.py \
+ $(docinput) \
doc/html \
$(BUILT_EXAMPLES:%=%.in) \
doc/examples/ganeti.default \
maninput = \
$(patsubst %.1,%.1.in,$(patsubst %.7,%.7.in,$(patsubst %.8,%.8.in,$(man_MANS)))) \
$(patsubst %.html,%.html.in,$(manhtml)) \
- man/footer.man man/footer.html $(mangen)
+ $(mangen)
TEST_FILES = \
test/data/htools/clean-nonzero-score.data \
test/data/bdev-drbd-net-ip6.txt \
test/data/cert1.pem \
test/data/cert2.pem \
+ test/data/instance-minor-pairing.txt \
test/data/ip-addr-show-dummy0.txt \
test/data/ip-addr-show-lo-ipv4.txt \
test/data/ip-addr-show-lo-ipv6.txt \
test/py/ganeti.utils.io_unittest-runasroot.py \
test/py/ganeti.utils.io_unittest.py \
test/py/ganeti.utils.log_unittest.py \
+ test/py/ganeti.utils.lvm_unittest.py \
test/py/ganeti.utils.mlock_unittest.py \
test/py/ganeti.utils.nodesetup_unittest.py \
test/py/ganeti.utils.process_unittest.py \
test/hs/offline-test.sh \
test/hs/cli-tests-defs.sh \
$(all_python_code) \
- $(HS_LIBTEST_SRCS) $(HS_PROG_SRCS)
+ $(HS_LIBTEST_SRCS) $(HS_PROG_SRCS) \
+ $(docinput)
check_python_code = \
$(BUILD_BASH_COMPLETION) \
PYTHONPATH=. $(RUN_IN_TEMPDIR) \
$(CURDIR)/$(BUILD_BASH_COMPLETION) $(BC_ARGS) > $@
-doc/%.png: doc/%.dot
- @test -n "$(DOT)" || { echo 'dot' not found during configure; exit 1; }
- $(DOT) -Tpng -o $@ $<
-
-man/footer.man: man/footer.rst
- @test -n "$(PANDOC)" || \
- { echo 'pandoc' not found during configure; exit 1; }
- $(PANDOC) -f rst -t man -o $@ $<
-
-man/footer.html: man/footer.rst
- @test -n "$(PANDOC)" || \
- { echo 'pandoc' not found during configure; exit 1; }
- $(PANDOC) -f rst -t html -o $@ $<
-
man/%.gen: man/%.rst lib/query.py lib/build/sphinx_ext.py \
lib/build/shell_example_lexer.py \
| $(RUN_IN_TEMPDIR) $(BUILT_PYTHON_SOURCES)
@echo "Checking $< for hardcoded paths..."
@if grep -nEf autotools/wrong-hardcoded-paths $<; then \
- echo "Man page $< has harcoded paths (see above)!" 1>&2 ; \
+ echo "Man page $< has hardcoded paths (see above)!" 1>&2 ; \
exit 1; \
fi
set -e ; \
trap 'echo auto-removing $@; rm $@' EXIT; \
PYTHONPATH=. $(RUN_IN_TEMPDIR) $(CURDIR)/$(DOCPP) < $< > $@ ;\
+ $(CHECK_MAN_REFERENCES) $@; \
trap - EXIT
-man/%.7.in man/%.8.in man/%.1.in: man/%.gen man/footer.man
+man/%.7.in man/%.8.in man/%.1.in: man/%.gen man/footer.rst
@test -n "$(PANDOC)" || \
{ echo 'pandoc' not found during configure; exit 1; }
set -o pipefail ; \
trap 'echo auto-removing $@; rm $@' EXIT; \
- $(PANDOC) -s -f rst -t man -A man/footer.man $< | \
+ $(PANDOC) -s -f rst -t man $< man/footer.rst | \
sed -e 's/\\@/@/g' > $@; \
if test -n "$(MAN_HAS_WARNINGS)"; then $(CHECK_MAN_WARNINGS) $@; fi; \
$(CHECK_MAN_DASHES) $@; \
trap - EXIT
-
-man/%.html.in: man/%.gen man/footer.html
+man/%.html.in: man/%.gen man/footer.rst
@test -n "$(PANDOC)" || \
{ echo 'pandoc' not found during configure; exit 1; }
set -o pipefail ; \
- $(PANDOC) -s -f rst -t html -A man/footer.html $< | \
+ $(PANDOC) --toc -s -f rst -t html $< man/footer.rst | \
sed -e 's/\\@/@/g' > $@
man/%: man/%.in $(REPLACE_VARS_SED)
exit 1; \
fi
+# target to rebuild all man pages (both groff and html output)
+.PHONY: man
+man: $(man_MANS) $(manhtml)
+
# Target that builds all binaries (including those that are not
# rebuilt except when running the tests)
.PHONY: really-all