2 # - Indent with tabs only.
3 # - Keep files sorted; one line per file.
4 # - Directories in lib/ must have their own *dir variable (see hypervisor).
5 # - All directories must be listed DIRS.
6 # - Use autogen.sh to generate Makefile.in and configure script.
8 # Automake doesn't export these variables before version 1.10.
9 abs_top_builddir = @abs_top_builddir@
10 abs_top_srcdir = @abs_top_srcdir@
12 # Helper values for calling builtin functions
14 space := $(empty) $(empty)
17 # Use bash in order to be able to use pipefail
20 ACLOCAL_AMFLAGS = -I autotools
21 BUILD_BASH_COMPLETION = $(top_srcdir)/autotools/build-bash-completion
22 RUN_IN_TEMPDIR = $(top_srcdir)/autotools/run-in-tempdir
23 CHECK_PYTHON_CODE = $(top_srcdir)/autotools/check-python-code
24 CHECK_HEADER = $(top_srcdir)/autotools/check-header
25 CHECK_MAN_DASHES = $(top_srcdir)/autotools/check-man-dashes
26 CHECK_MAN_REFERENCES = $(top_srcdir)/autotools/check-man-references
27 CHECK_MAN_WARNINGS = $(top_srcdir)/autotools/check-man-warnings
28 CHECK_VERSION = $(top_srcdir)/autotools/check-version
29 CHECK_NEWS = $(top_srcdir)/autotools/check-news
30 CHECK_IMPORTS = $(top_srcdir)/autotools/check-imports
31 DOCPP = $(top_srcdir)/autotools/docpp
32 REPLACE_VARS_SED = autotools/replace_vars.sed
33 CONVERT_CONSTANTS = $(top_srcdir)/autotools/convert-constants
34 BUILD_RPC = $(top_srcdir)/autotools/build-rpc
35 SHELL_ENV_INIT = autotools/shell-env-init
37 # Note: these are automake-specific variables, and must be named after
38 # the directory + 'dir' suffix
39 clientdir = $(pkgpythondir)/client
40 hypervisordir = $(pkgpythondir)/hypervisor
41 httpdir = $(pkgpythondir)/http
42 masterddir = $(pkgpythondir)/masterd
43 confddir = $(pkgpythondir)/confd
44 rapidir = $(pkgpythondir)/rapi
45 serverdir = $(pkgpythondir)/server
46 watcherdir = $(pkgpythondir)/watcher
47 impexpddir = $(pkgpythondir)/impexpd
48 utilsdir = $(pkgpythondir)/utils
49 toolsdir = $(pkglibdir)/tools
50 iallocatorsdir = $(pkglibdir)/iallocators
51 pytoolsdir = $(pkgpythondir)/tools
52 docdir = $(datadir)/doc/$(PACKAGE)
53 myexeclibdir = $(pkglibdir)
55 # Delete output file if an error occurred while building it
62 src/Ganeti/Block/Drbd \
65 src/Ganeti/DataCollectors \
67 src/Ganeti/HTools/Backend \
68 src/Ganeti/HTools/Program \
69 src/Ganeti/Hypervisor \
70 src/Ganeti/Hypervisor/Xen \
75 test/hs/Test/Ganeti/Block \
76 test/hs/Test/Ganeti/Block/Drbd \
77 test/hs/Test/Ganeti/Confd \
78 test/hs/Test/Ganeti/HTools \
79 test/hs/Test/Ganeti/HTools/Backend \
80 test/hs/Test/Ganeti/Hypervisor \
81 test/hs/Test/Ganeti/Hypervisor/Xen \
82 test/hs/Test/Ganeti/Query
92 doc/examples/gnt-debug \
95 test/data/htools/rapi \
116 test/data/ovfdata/other \
120 ALL_APIDOC_HS_DIRS = \
122 $(APIDOC_HS_DIR)/Ganeti \
123 $(APIDOC_HS_DIR)/Ganeti/Block \
124 $(APIDOC_HS_DIR)/Ganeti/Block/Drbd \
125 $(APIDOC_HS_DIR)/Ganeti/Confd \
126 $(APIDOC_HS_DIR)/Ganeti/Curl \
127 $(APIDOC_HS_DIR)/Ganeti/DataCollectors \
128 $(APIDOC_HS_DIR)/Ganeti/HTools \
129 $(APIDOC_HS_DIR)/Ganeti/HTools/Backend \
130 $(APIDOC_HS_DIR)/Ganeti/HTools/Program \
131 $(APIDOC_HS_DIR)/Ganeti/Hypervisor \
132 $(APIDOC_HS_DIR)/Ganeti/Hypervisor/Xen \
133 $(APIDOC_HS_DIR)/Ganeti/Query
135 BUILDTIME_DIR_AUTOCREATE = \
138 $(ALL_APIDOC_HS_DIRS) \
146 $(BUILDTIME_DIR_AUTOCREATE) \
152 ganeti-[0-9]*.[0-9]*.[0-9]* \
158 COVERAGE_DIR = doc/coverage
159 COVERAGE_PY_DIR = $(COVERAGE_DIR)/py
160 COVERAGE_HS_DIR = $(COVERAGE_DIR)/hs
162 APIDOC_PY_DIR = $(APIDOC_DIR)/py
163 APIDOC_HS_DIR = $(APIDOC_DIR)/hs
165 MAINTAINERCLEANFILES = \
167 doc/install-quick.rst \
172 maintainer-clean-local:
173 rm -rf $(BUILDTIME_DIRS)
176 $(addsuffix /*.py[co],$(DIRS)) \
177 $(addsuffix /*.hi,$(HS_DIRS)) \
178 $(addsuffix /*.o,$(HS_DIRS)) \
179 $(PYTHON_BOOTSTRAP) \
181 $(REPLACE_VARS_SED) \
183 daemons/daemon-util \
184 daemons/ganeti-cleaner \
186 doc/manpages-enabled.rst \
188 doc/examples/bash_completion \
189 doc/examples/bash_completion-debug \
190 lib/_generated_rpc.py \
194 tools/vcluster-setup \
197 $(nodist_pkgpython_PYTHON) \
198 $(HS_ALL_PROGS) $(HS_BUILT_SRCS) \
199 $(HS_BUILT_TEST_HELPERS) \
201 .hpc/*.mix src/*.tix test/hs/*.tix \
205 $(built_base_sources) \
206 $(BUILT_PYTHON_SOURCES) \
211 HS_GENERATED_FILES += $(HS_PROGS)
213 HS_GENERATED_FILES += src/hconfd src/ganeti-confd
217 built_base_sources = \
221 built_python_base_sources = \
225 BUILT_PYTHON_SOURCES = \
226 $(built_python_base_sources) \
227 lib/_generated_rpc.py
229 # Generating the RPC wrappers depends on many things, so make sure
230 # it's built at the end of the built sources
231 lib/_generated_rpc.py: | $(built_base_sources) $(built_python_base_sources)
233 # these are all built from the underlying %.in sources
235 doc/examples/ganeti-kvm-poweroff.initd \
236 doc/examples/ganeti.cron \
237 doc/examples/ganeti.initd \
238 doc/examples/ganeti-master-role.ocf \
239 doc/examples/ganeti-node-role.ocf \
240 doc/examples/gnt-config-backup \
241 doc/examples/hooks/ipsec
243 nodist_pkgpython_PYTHON = \
244 $(BUILT_PYTHON_SOURCES)
247 lib/build/__init__.py \
248 lib/build/shell_example_lexer.py \
249 lib/build/sphinx_ext.py
253 lib/asyncnotifier.py \
291 lib/client/__init__.py \
292 lib/client/gnt_backup.py \
293 lib/client/gnt_cluster.py \
294 lib/client/gnt_debug.py \
295 lib/client/gnt_group.py \
296 lib/client/gnt_instance.py \
297 lib/client/gnt_job.py \
298 lib/client/gnt_node.py \
299 lib/client/gnt_network.py \
300 lib/client/gnt_os.py \
301 lib/client/gnt_storage.py
303 hypervisor_PYTHON = \
304 lib/hypervisor/__init__.py \
305 lib/hypervisor/hv_base.py \
306 lib/hypervisor/hv_chroot.py \
307 lib/hypervisor/hv_fake.py \
308 lib/hypervisor/hv_kvm.py \
309 lib/hypervisor/hv_lxc.py \
310 lib/hypervisor/hv_xen.py
313 lib/rapi/__init__.py \
314 lib/rapi/baserlib.py \
316 lib/rapi/client_utils.py \
317 lib/rapi/connector.py \
319 lib/rapi/testutils.py
322 lib/http/__init__.py \
328 lib/confd/__init__.py \
332 lib/masterd/__init__.py \
333 lib/masterd/iallocator.py \
334 lib/masterd/instance.py
337 lib/impexpd/__init__.py
340 lib/watcher/__init__.py \
341 lib/watcher/nodemaint.py \
345 lib/server/__init__.py \
346 lib/server/masterd.py \
347 lib/server/noded.py \
351 lib/tools/__init__.py \
352 lib/tools/burnin.py \
353 lib/tools/ensure_dirs.py \
354 lib/tools/node_cleanup.py \
355 lib/tools/node_daemon_setup.py \
356 lib/tools/prepare_node_join.py
359 lib/utils/__init__.py \
361 lib/utils/filelock.py \
367 lib/utils/nodesetup.py \
368 lib/utils/process.py \
371 lib/utils/wrapper.py \
378 doc/cluster-merge.rst \
387 doc/design-autorepair.rst \
388 doc/design-bulk-create.rst \
389 doc/design-chained-jobs.rst \
390 doc/design-cpu-pinning.rst \
391 doc/design-draft.rst \
392 doc/design-htools-2.3.rst \
393 doc/design-http-server.rst \
394 doc/design-impexp2.rst \
395 doc/design-lu-generated-jobs.rst \
396 doc/design-linuxha.rst \
397 doc/design-multi-reloc.rst \
398 doc/design-network.rst \
399 doc/design-node-add.rst \
401 doc/design-ovf-support.rst \
402 doc/design-opportunistic-locking.rst \
403 doc/design-partitioned.rst \
404 doc/design-query-splitting.rst \
405 doc/design-query2.rst \
406 doc/design-resource-model.rst \
407 doc/design-restricted-commands.rst \
408 doc/design-shared-storage.rst \
409 doc/design-monitoring-agent.rst \
410 doc/design-virtual-clusters.rst \
411 doc/design-x509-ca.rst \
412 doc/design-hroller.rst \
413 doc/design-storagespace.rst \
419 doc/install-quick.rst \
422 doc/manpages-disabled.rst \
423 doc/move-instance.rst \
425 doc/ovfconverter.rst \
429 doc/virtual-cluster.rst \
432 # Generates file names such as "doc/man-gnt-instance.rst"
433 mandocrst = $(addprefix doc/man-,$(notdir $(manrst)))
435 # Haskell programs to be installed in $PREFIX/bin
436 HS_BIN_PROGS=src/htools
438 # Haskell programs to be installed in the MYEXECLIB dir
439 HS_MYEXECLIB_PROGS=src/mon-collector
441 # Haskell programs to compiled but not installed automatically
442 # Usually they have their own specific installation rules
447 # All Haskell non-test programs to be compiled but not automatically installed
448 HS_PROGS = $(HS_BIN_PROGS) $(HS_MYEXECLIB_PROGS)
450 HS_BIN_ROLES = harep hbal hscan hspace hinfo hcheck hroller
451 HS_HTOOLS_PROGS = $(HS_BIN_ROLES) hail
456 test/hs/hpc-mon-collector \
460 HS_PROG_SRCS = $(patsubst %,%.hs,$(HS_ALL_PROGS))
461 HS_BUILT_TEST_HELPERS = $(HS_BIN_ROLES:%=test/hs/%) test/hs/hail
464 -O -Wall -Werror -isrc \
465 -fwarn-monomorphism-restriction \
467 $(GHC_BYVERSION_FLAGS)
469 # extra flags that can be overriden on the command line (e.g. -Wwarn, etc.)
471 # internal extra flags (used for test/hs/htest mainly)
473 # exclude options for coverage reports
474 HPCEXCL = --exclude Main \
475 --exclude Ganeti.Constants \
476 --exclude Ganeti.HTools.QC \
477 --exclude Ganeti.THH \
478 --exclude Ganeti.Version \
479 --exclude Test.Ganeti.Attoparsec \
480 --exclude Test.Ganeti.TestCommon \
481 --exclude Test.Ganeti.TestHTools \
482 --exclude Test.Ganeti.TestHelper \
483 --exclude Test.Ganeti.TestImports \
484 $(patsubst src.%,--exclude Test.%,$(subst /,.,$(patsubst %.hs,%, $(HS_LIB_SRCS))))
487 src/Ganeti/Block/Drbd/Types.hs \
488 src/Ganeti/Block/Drbd/Parser.hs \
489 src/Ganeti/BasicTypes.hs \
490 src/Ganeti/Common.hs \
491 src/Ganeti/Compat.hs \
492 src/Ganeti/Confd/Client.hs \
493 src/Ganeti/Confd/Server.hs \
494 src/Ganeti/Confd/Types.hs \
495 src/Ganeti/Confd/Utils.hs \
496 src/Ganeti/Config.hs \
497 src/Ganeti/Curl/Multi.hs \
498 src/Ganeti/Daemon.hs \
499 src/Ganeti/DataCollectors/CLI.hs \
500 src/Ganeti/DataCollectors/Drbd.hs \
501 src/Ganeti/DataCollectors/Program.hs \
502 src/Ganeti/DataCollectors/Types.hs \
503 src/Ganeti/Errors.hs \
504 src/Ganeti/HTools/Backend/IAlloc.hs \
505 src/Ganeti/HTools/Backend/Luxi.hs \
506 src/Ganeti/HTools/Backend/Rapi.hs \
507 src/Ganeti/HTools/Backend/Simu.hs \
508 src/Ganeti/HTools/Backend/Text.hs \
509 src/Ganeti/HTools/CLI.hs \
510 src/Ganeti/HTools/Cluster.hs \
511 src/Ganeti/HTools/Container.hs \
512 src/Ganeti/HTools/ExtLoader.hs \
513 src/Ganeti/HTools/Graph.hs \
514 src/Ganeti/HTools/Group.hs \
515 src/Ganeti/HTools/Instance.hs \
516 src/Ganeti/HTools/Loader.hs \
517 src/Ganeti/HTools/Node.hs \
518 src/Ganeti/HTools/PeerMap.hs \
519 src/Ganeti/HTools/Program/Hail.hs \
520 src/Ganeti/HTools/Program/Harep.hs \
521 src/Ganeti/HTools/Program/Hbal.hs \
522 src/Ganeti/HTools/Program/Hcheck.hs \
523 src/Ganeti/HTools/Program/Hinfo.hs \
524 src/Ganeti/HTools/Program/Hscan.hs \
525 src/Ganeti/HTools/Program/Hspace.hs \
526 src/Ganeti/HTools/Program/Hroller.hs \
527 src/Ganeti/HTools/Program/Main.hs \
528 src/Ganeti/HTools/Types.hs \
529 src/Ganeti/Hypervisor/Xen/XmParser.hs \
530 src/Ganeti/Hypervisor/Xen/Types.hs \
532 src/Ganeti/JQueue.hs \
535 src/Ganeti/Logging.hs \
537 src/Ganeti/Network.hs \
538 src/Ganeti/Objects.hs \
539 src/Ganeti/OpCodes.hs \
540 src/Ganeti/OpParams.hs \
542 src/Ganeti/Query/Common.hs \
543 src/Ganeti/Query/Export.hs \
544 src/Ganeti/Query/Filter.hs \
545 src/Ganeti/Query/Group.hs \
546 src/Ganeti/Query/Job.hs \
547 src/Ganeti/Query/Language.hs \
548 src/Ganeti/Query/Network.hs \
549 src/Ganeti/Query/Node.hs \
550 src/Ganeti/Query/Query.hs \
551 src/Ganeti/Query/Server.hs \
552 src/Ganeti/Query/Types.hs \
554 src/Ganeti/Runtime.hs \
555 src/Ganeti/Ssconf.hs \
557 src/Ganeti/Types.hs \
561 test/hs/Test/Ganeti/Attoparsec.hs \
562 test/hs/Test/Ganeti/BasicTypes.hs \
563 test/hs/Test/Ganeti/Block/Drbd/Parser.hs \
564 test/hs/Test/Ganeti/Block/Drbd/Types.hs \
565 test/hs/Test/Ganeti/Common.hs \
566 test/hs/Test/Ganeti/Confd/Types.hs \
567 test/hs/Test/Ganeti/Confd/Utils.hs \
568 test/hs/Test/Ganeti/Daemon.hs \
569 test/hs/Test/Ganeti/Errors.hs \
570 test/hs/Test/Ganeti/HTools/Backend/Simu.hs \
571 test/hs/Test/Ganeti/HTools/Backend/Text.hs \
572 test/hs/Test/Ganeti/HTools/CLI.hs \
573 test/hs/Test/Ganeti/HTools/Cluster.hs \
574 test/hs/Test/Ganeti/HTools/Container.hs \
575 test/hs/Test/Ganeti/HTools/Graph.hs \
576 test/hs/Test/Ganeti/HTools/Instance.hs \
577 test/hs/Test/Ganeti/HTools/Loader.hs \
578 test/hs/Test/Ganeti/HTools/Node.hs \
579 test/hs/Test/Ganeti/HTools/PeerMap.hs \
580 test/hs/Test/Ganeti/HTools/Types.hs \
581 test/hs/Test/Ganeti/Hypervisor/Xen/XmParser.hs \
582 test/hs/Test/Ganeti/JSON.hs \
583 test/hs/Test/Ganeti/Jobs.hs \
584 test/hs/Test/Ganeti/JQueue.hs \
585 test/hs/Test/Ganeti/Luxi.hs \
586 test/hs/Test/Ganeti/Network.hs \
587 test/hs/Test/Ganeti/Objects.hs \
588 test/hs/Test/Ganeti/OpCodes.hs \
589 test/hs/Test/Ganeti/Query/Filter.hs \
590 test/hs/Test/Ganeti/Query/Language.hs \
591 test/hs/Test/Ganeti/Query/Network.hs \
592 test/hs/Test/Ganeti/Query/Query.hs \
593 test/hs/Test/Ganeti/Rpc.hs \
594 test/hs/Test/Ganeti/Runtime.hs \
595 test/hs/Test/Ganeti/Ssconf.hs \
596 test/hs/Test/Ganeti/THH.hs \
597 test/hs/Test/Ganeti/TestCommon.hs \
598 test/hs/Test/Ganeti/TestHTools.hs \
599 test/hs/Test/Ganeti/TestHelper.hs \
600 test/hs/Test/Ganeti/Types.hs \
601 test/hs/Test/Ganeti/Utils.hs
603 HS_LIBTEST_SRCS = $(HS_LIB_SRCS) $(HS_TEST_SRCS)
606 test/hs/Test/Ganeti/TestImports.hs \
607 src/Ganeti/Constants.hs \
608 src/Ganeti/Curl/Internal.hs \
609 src/Ganeti/Version.hs
611 $(patsubst %,%.in,$(filter-out src/Ganeti/Curl/Internal.hs,$(HS_BUILT_SRCS))) \
612 src/Ganeti/Curl/Internal.hsc
614 $(RUN_IN_TEMPDIR): | stamp-directories
616 doc/html/index.html: ENABLE_MANPAGES =
617 doc/man-html/index.html: ENABLE_MANPAGES = 1
618 doc/man-html/index.html: doc/manpages-enabled.rst $(mandocrst)
620 # Note: we use here an order-only prerequisite, as the contents of
621 # _autoconf.py are not actually influencing the html build output: it
622 # has to exist in order for the sphinx module to be loaded
623 # successfully, but we certainly don't want the docs to be rebuilt if
625 doc/html/index.html doc/man-html/index.html: $(docinput) doc/conf.py \
626 configure.ac $(RUN_IN_TEMPDIR) lib/build/sphinx_ext.py \
627 lib/build/shell_example_lexer.py lib/opcodes.py lib/ht.py \
628 doc/css/style.css lib/rapi/connector.py lib/rapi/rlib2.py \
629 | $(BUILT_PYTHON_SOURCES)
630 @test -n "$(SPHINX)" || \
631 { echo 'sphinx-build' not found during configure; exit 1; }
633 if test -n '$(ENABLE_MANPAGES)'; then \
634 echo 'Man pages in documentation were disabled at configure time' >&2; \
638 ## Sphinx provides little control over what content should be included. Some
639 ## mechanisms exist, but they all have drawbacks or actual issues. Since we
640 ## build two different versions of the documentation--once without man pages and
641 ## once, if enabled, with them--some control is necessary. xmpp-wrapper provides
642 ## us with this, but requires running in a temporary directory. It moves the
643 ## correct files into place depending on environment variables.
646 PYTHONPATH=. ENABLE_MANPAGES=$(ENABLE_MANPAGES) COPY_DOC=1 \
647 $(RUN_IN_TEMPDIR) autotools/sphinx-wrapper $(SPHINX) -q -W -b html \
649 -D version="$(VERSION_MAJOR).$(VERSION_MINOR)" \
650 -D release="$(PACKAGE_VERSION)" \
651 -D graphviz_dot="$(DOT)" \
652 -D enable_manpages="$(ENABLE_MANPAGES)" \
653 doc $(CURDIR)/$$dir && \
654 rm -f $$dir/.buildinfo $$dir/objects.inv
657 doc/html: doc/html/index.html
659 doc/man-html: doc/man-html/index.html
661 doc/install-quick.rst: INSTALL
663 doc/upgrade.rst: UPGRADE
665 doc/install-quick.rst doc/news.rst doc/upgrade.rst:
667 { echo '.. This file is automatically updated at build time from $<.'; \
668 echo '.. Do not edit.'; \
673 doc/manpages-enabled.rst: Makefile | $(built_base_sources)
674 { echo '.. This file is automatically generated, do not edit!'; \
679 echo '.. toctree::'; \
680 echo ' :maxdepth: 1'; \
682 for i in $(notdir $(mandocrst)); do \
684 done | LC_ALL=C sort; \
687 doc/man-%.rst: man/%.gen Makefile $(REPLACE_VARS_SED) | $(built_base_sources)
689 { echo '.. This file is automatically updated at build time from $<.'; \
690 echo '.. Do not edit.'; \
693 echo '=========================================='; \
694 tail -n +3 $< | sed -f $(REPLACE_VARS_SED); \
697 echo 'Man pages in documentation were disabled at configure time' >&2; \
701 # Things to build but not to install (add it to EXTRA_DIST if it should be
706 doc/examples/bash_completion \
707 doc/examples/bash_completion-debug \
711 noinst_DATA += doc/man-html
716 scripts/gnt-cluster \
719 scripts/gnt-instance \
721 scripts/gnt-network \
726 PYTHON_BOOTSTRAP_SBIN = \
727 daemons/ganeti-masterd \
728 daemons/ganeti-noded \
729 daemons/ganeti-rapi \
730 daemons/ganeti-watcher \
734 $(PYTHON_BOOTSTRAP_SBIN) \
738 tools/node-daemon-setup \
739 tools/prepare-node-join
760 bin_SCRIPTS += $(HS_BIN_PROGS)
762 @mkdir_p@ $(DESTDIR)$(iallocatorsdir)
763 # FIXME: this is a hardcoded logic, instead of auto-resolving
764 $(LN_S) -f ../../../bin/htools \
765 $(DESTDIR)$(iallocatorsdir)/hail
766 for role in $(HS_BIN_ROLES); do \
767 $(LN_S) -f htools $(DESTDIR)$(bindir)/$$role ; \
771 $(HS_ALL_PROGS): %: %.hs $(HS_LIBTEST_SRCS) $(HS_BUILT_SRCS) Makefile
772 @if [ "$(notdir $@)" = "test" ] && [ "$(HS_NODEV)" ]; then \
773 echo "Error: cannot run unittests without the development" \
774 " libraries (see devnotes.rst)" 1>&2; \
777 @rm -f $(notdir $@).tix
780 $(HS_PARALLEL3) $(HS_REGEX_PCRE) \
781 -osuf $(notdir $@).o -hisuf $(notdir $@).hi \
782 $(HEXTRA) $(HEXTRA_INT) $@
785 # for the test/hs/htest binary, we need to enable profiling/coverage
786 test/hs/htest: HEXTRA_INT=-fhpc -itest/hs
788 # we compile the hpc-htools binary with the program coverage
789 test/hs/hpc-htools: HEXTRA_INT=-fhpc
791 # we compile the hpc-mon-collector binary with the program coverage
792 test/hs/hpc-mon-collector: HEXTRA_INT=-fhpc
795 test/hs/offline-tests.sh: test/hs/hpc-htools test/hs/hpc-mon-collector
797 # rules for building profiling-enabled versions of the haskell
798 # programs: hs-prof does the full two-step build, whereas
799 # hs-prof-quick does only the final rebuild (hs-prof must have been
801 .PHONY: hs-prof hs-prof-quick
803 @if [ -z "$(TARGET)" ]; then \
804 echo "You need to define TARGET when running this rule" 1>&2; \
807 $(MAKE) $(AM_MAKEFLAGS) clean
808 $(MAKE) $(AM_MAKEFLAGS) $(TARGET) HEXTRA="-osuf o"
809 rm -f $(HS_ALL_PROGS)
810 $(MAKE) $(AM_MAKEFLAGS) hs-prof-quick
813 @if [ -z "$(TARGET)" ]; then \
814 echo "You need to define TARGET when running this rule" 1>&2; \
817 $(MAKE) $(AM_MAKEFLAGS) $(TARGET) HEXTRA="-osuf prof_o -prof -auto-all"
819 dist_sbin_SCRIPTS = \
820 tools/ganeti-listrunner
822 nodist_sbin_SCRIPTS = \
823 $(PYTHON_BOOTSTRAP_SBIN) \
824 daemons/ganeti-cleaner
827 src/ganeti-confd: src/hconfd
830 nodist_sbin_SCRIPTS += src/ganeti-confd
837 tools/cluster-merge \
841 tools/move-instance \
843 tools/sanitize-config
845 dist_tools_SCRIPTS = \
847 tools/kvm-console-wrapper \
848 tools/master-ip-setup \
849 tools/xen-console-wrapper
851 nodist_tools_python_scripts = \
854 nodist_tools_SCRIPTS = \
855 $(nodist_tools_python_scripts) \
858 pkglib_python_scripts = \
859 daemons/import-export \
860 tools/check-cert-expired
862 nodist_pkglib_python_scripts = \
865 tools/node-daemon-setup \
866 tools/prepare-node-join
868 myexeclib_SCRIPTS = \
869 daemons/daemon-util \
871 $(pkglib_python_scripts) \
872 $(HS_MYEXECLIB_PROGS)
874 nodist_myexeclib_SCRIPTS = \
875 $(nodist_pkglib_python_scripts)
882 autotools/build-bash-completion \
883 autotools/build-rpc \
884 autotools/check-header \
885 autotools/check-imports \
886 autotools/check-man-dashes \
887 autotools/check-man-references \
888 autotools/check-man-warnings \
889 autotools/check-news \
890 autotools/check-python-code \
891 autotools/check-tar \
892 autotools/check-version \
893 autotools/convert-constants \
895 autotools/gen-py-coverage \
896 autotools/sphinx-wrapper \
897 autotools/testrunner \
898 autotools/wrong-hardcoded-paths \
900 daemons/daemon-util.in \
901 daemons/ganeti-cleaner.in \
902 $(pkglib_python_scripts) \
906 tools/vcluster-setup.in \
909 $(BUILT_EXAMPLES:%=%.in) \
910 doc/examples/ganeti.default \
911 doc/examples/ganeti.default-debug \
912 doc/examples/hooks/ethers \
913 doc/examples/gnt-debug/README \
914 doc/examples/gnt-debug/delay0.json \
915 doc/examples/gnt-debug/delay50.json \
916 test/py/lockperf.py \
917 test/py/testutils.py \
926 $(HS_LIBTEST_SRCS) $(HS_BUILT_SRCS_IN) \
929 test/hs/cli-tests-defs.sh \
930 test/hs/offline-test.sh \
934 man/ganeti-cleaner.8 \
936 man/ganeti-listrunner.8 \
937 man/ganeti-masterd.8 \
939 man/ganeti-os-interface.7 \
940 man/ganeti-extstorage-interface.7 \
942 man/ganeti-watcher.8 \
964 # Remove extensions from all filenames in man_MANS
965 mannoext = $(patsubst %.1,%,$(patsubst %.7,%,$(patsubst %.8,%,$(man_MANS))))
967 manrst = $(patsubst %,%.rst,$(mannoext))
968 manhtml = $(patsubst %.rst,%.html,$(manrst))
969 mangen = $(patsubst %.rst,%.gen,$(manrst))
971 $(patsubst %.1,%.1.in,$(patsubst %.7,%.7.in,$(patsubst %.8,%.8.in,$(man_MANS)))) \
972 $(patsubst %.html,%.html.in,$(manhtml)) \
976 test/data/htools/clean-nonzero-score.data \
977 test/data/htools/common-suffix.data \
978 test/data/htools/empty-cluster.data \
979 test/data/htools/hail-alloc-drbd.json \
980 test/data/htools/hail-change-group.json \
981 test/data/htools/hail-invalid-reloc.json \
982 test/data/htools/hail-node-evac.json \
983 test/data/htools/hail-reloc-drbd.json \
984 test/data/htools/hbal-excl-tags.data \
985 test/data/htools/hbal-split-insts.data \
986 test/data/htools/invalid-node.data \
987 test/data/htools/missing-resources.data \
988 test/data/htools/n1-failure.data \
989 test/data/htools/rapi/groups.json \
990 test/data/htools/rapi/info.json \
991 test/data/htools/rapi/instances.json \
992 test/data/htools/rapi/nodes.json \
993 test/hs/shelltests/htools-balancing.test \
994 test/hs/shelltests/htools-basic.test \
995 test/hs/shelltests/htools-dynutil.test \
996 test/hs/shelltests/htools-excl.test \
997 test/hs/shelltests/htools-hail.test \
998 test/hs/shelltests/htools-hspace.test \
999 test/hs/shelltests/htools-invalid.test \
1000 test/hs/shelltests/htools-multi-group.test \
1001 test/hs/shelltests/htools-no-backend.test \
1002 test/hs/shelltests/htools-rapi.test \
1003 test/hs/shelltests/htools-single-group.test \
1004 test/hs/shelltests/htools-text-backend.test \
1005 test/hs/shelltests/htools-mon-collector.test \
1006 test/data/bdev-drbd-8.0.txt \
1007 test/data/bdev-drbd-8.3.txt \
1008 test/data/bdev-drbd-disk.txt \
1009 test/data/bdev-drbd-net-ip4.txt \
1010 test/data/bdev-drbd-net-ip6.txt \
1011 test/data/bdev-rbd/json_output_empty.txt \
1012 test/data/bdev-rbd/json_output_extra_matches.txt \
1013 test/data/bdev-rbd/json_output_no_matches.txt \
1014 test/data/bdev-rbd/json_output_ok.txt \
1015 test/data/bdev-rbd/plain_output_new_extra_matches.txt \
1016 test/data/bdev-rbd/plain_output_new_no_matches.txt \
1017 test/data/bdev-rbd/plain_output_new_ok.txt \
1018 test/data/bdev-rbd/plain_output_old_empty.txt \
1019 test/data/bdev-rbd/plain_output_old_extra_matches.txt \
1020 test/data/bdev-rbd/plain_output_old_no_matches.txt \
1021 test/data/bdev-rbd/plain_output_old_ok.txt \
1022 test/data/bdev-rbd/output_invalid.txt \
1023 test/data/cert1.pem \
1024 test/data/cert2.pem \
1025 test/data/instance-minor-pairing.txt \
1026 test/data/ip-addr-show-dummy0.txt \
1027 test/data/ip-addr-show-lo-ipv4.txt \
1028 test/data/ip-addr-show-lo-ipv6.txt \
1029 test/data/ip-addr-show-lo-oneline-ipv4.txt \
1030 test/data/ip-addr-show-lo-oneline-ipv6.txt \
1031 test/data/ip-addr-show-lo-oneline.txt \
1032 test/data/ip-addr-show-lo.txt \
1033 test/data/kvm_0.12.5_help.txt \
1034 test/data/kvm_0.15.90_help.txt \
1035 test/data/kvm_0.9.1_help.txt \
1036 test/data/kvm_0.9.1_help_boot_test.txt \
1037 test/data/kvm_1.0_help.txt \
1038 test/data/kvm_1.1.2_help.txt \
1039 test/data/ovfdata/compr_disk.vmdk.gz \
1040 test/data/ovfdata/config.ini \
1041 test/data/ovfdata/corrupted_resources.ovf \
1042 test/data/ovfdata/empty.ini \
1043 test/data/ovfdata/empty.ovf \
1044 test/data/ovfdata/ganeti.mf \
1045 test/data/ovfdata/ganeti.ovf \
1046 test/data/ovfdata/gzip_disk.ovf \
1047 test/data/ovfdata/new_disk.vmdk \
1048 test/data/ovfdata/no_disk.ini \
1049 test/data/ovfdata/no_disk_in_ref.ovf \
1050 test/data/ovfdata/no_os.ini \
1051 test/data/ovfdata/no_ovf.ova \
1052 test/data/ovfdata/other/rawdisk.raw \
1053 test/data/ovfdata/ova.ova \
1054 test/data/ovfdata/rawdisk.raw \
1055 test/data/ovfdata/second_disk.vmdk \
1056 test/data/ovfdata/unsafe_path.ini \
1057 test/data/ovfdata/virtualbox.ovf \
1058 test/data/ovfdata/wrong_config.ini \
1059 test/data/ovfdata/wrong_extension.ovd \
1060 test/data/ovfdata/wrong_manifest.mf \
1061 test/data/ovfdata/wrong_manifest.ovf \
1062 test/data/ovfdata/wrong_ova.ova \
1063 test/data/ovfdata/wrong_xml.ovf \
1064 test/data/proc_drbd8.txt \
1065 test/data/proc_drbd80-emptyline.txt \
1066 test/data/proc_drbd83.txt \
1067 test/data/proc_drbd83_sync.txt \
1068 test/data/proc_drbd83_sync_want.txt \
1069 test/data/proc_drbd83_sync_krnl2.6.39.txt \
1070 test/data/qa-minimal-nodes-instances-only.json \
1071 test/data/sys_drbd_usermode_helper.txt \
1072 test/data/vgreduce-removemissing-2.02.02.txt \
1073 test/data/vgreduce-removemissing-2.02.66-fail.txt \
1074 test/data/vgreduce-removemissing-2.02.66-ok.txt \
1075 test/data/vgs-missing-pvs-2.02.02.txt \
1076 test/data/vgs-missing-pvs-2.02.66.txt \
1077 test/data/xen-xm-info-4.0.1.txt \
1078 test/data/xen-xm-list-4.0.1-dom0-only.txt \
1079 test/data/xen-xm-list-4.0.1-four-instances.txt \
1080 test/data/xen-xm-list-long-4.0.1.txt \
1081 test/data/xen-xm-uptime-4.0.1.txt \
1082 test/py/ganeti-cli.test \
1083 test/py/gnt-cli.test \
1084 test/py/import-export_unittest-helper
1087 doc/examples/rapi_testutils.py \
1088 test/py/cfgupgrade_unittest.py \
1089 test/py/docs_unittest.py \
1090 test/py/ganeti.asyncnotifier_unittest.py \
1091 test/py/ganeti.backend_unittest-runasroot.py \
1092 test/py/ganeti.backend_unittest.py \
1093 test/py/ganeti.bdev_unittest.py \
1094 test/py/ganeti.cli_unittest.py \
1095 test/py/ganeti.client.gnt_cluster_unittest.py \
1096 test/py/ganeti.client.gnt_instance_unittest.py \
1097 test/py/ganeti.client.gnt_job_unittest.py \
1098 test/py/ganeti.cmdlib_unittest.py \
1099 test/py/ganeti.compat_unittest.py \
1100 test/py/ganeti.confd.client_unittest.py \
1101 test/py/ganeti.config_unittest.py \
1102 test/py/ganeti.constants_unittest.py \
1103 test/py/ganeti.daemon_unittest.py \
1104 test/py/ganeti.errors_unittest.py \
1105 test/py/ganeti.hooks_unittest.py \
1106 test/py/ganeti.ht_unittest.py \
1107 test/py/ganeti.http_unittest.py \
1108 test/py/ganeti.hypervisor.hv_chroot_unittest.py \
1109 test/py/ganeti.hypervisor.hv_fake_unittest.py \
1110 test/py/ganeti.hypervisor.hv_kvm_unittest.py \
1111 test/py/ganeti.hypervisor.hv_lxc_unittest.py \
1112 test/py/ganeti.hypervisor.hv_xen_unittest.py \
1113 test/py/ganeti.hypervisor_unittest.py \
1114 test/py/ganeti.impexpd_unittest.py \
1115 test/py/ganeti.jqueue_unittest.py \
1116 test/py/ganeti.jstore_unittest.py \
1117 test/py/ganeti.locking_unittest.py \
1118 test/py/ganeti.luxi_unittest.py \
1119 test/py/ganeti.masterd.iallocator_unittest.py \
1120 test/py/ganeti.masterd.instance_unittest.py \
1121 test/py/ganeti.mcpu_unittest.py \
1122 test/py/ganeti.netutils_unittest.py \
1123 test/py/ganeti.objects_unittest.py \
1124 test/py/ganeti.opcodes_unittest.py \
1125 test/py/ganeti.outils_unittest.py \
1126 test/py/ganeti.ovf_unittest.py \
1127 test/py/ganeti.qlang_unittest.py \
1128 test/py/ganeti.query_unittest.py \
1129 test/py/ganeti.rapi.baserlib_unittest.py \
1130 test/py/ganeti.rapi.client_unittest.py \
1131 test/py/ganeti.rapi.resources_unittest.py \
1132 test/py/ganeti.rapi.rlib2_unittest.py \
1133 test/py/ganeti.rapi.testutils_unittest.py \
1134 test/py/ganeti.rpc_unittest.py \
1135 test/py/ganeti.runtime_unittest.py \
1136 test/py/ganeti.serializer_unittest.py \
1137 test/py/ganeti.server.rapi_unittest.py \
1138 test/py/ganeti.ssconf_unittest.py \
1139 test/py/ganeti.ssh_unittest.py \
1140 test/py/ganeti.storage_unittest.py \
1141 test/py/ganeti.tools.burnin_unittest.py \
1142 test/py/ganeti.tools.ensure_dirs_unittest.py \
1143 test/py/ganeti.tools.node_daemon_setup_unittest.py \
1144 test/py/ganeti.tools.prepare_node_join_unittest.py \
1145 test/py/ganeti.uidpool_unittest.py \
1146 test/py/ganeti.utils.algo_unittest.py \
1147 test/py/ganeti.utils.filelock_unittest.py \
1148 test/py/ganeti.utils.hash_unittest.py \
1149 test/py/ganeti.utils.io_unittest-runasroot.py \
1150 test/py/ganeti.utils.io_unittest.py \
1151 test/py/ganeti.utils.log_unittest.py \
1152 test/py/ganeti.utils.lvm_unittest.py \
1153 test/py/ganeti.utils.mlock_unittest.py \
1154 test/py/ganeti.utils.nodesetup_unittest.py \
1155 test/py/ganeti.utils.process_unittest.py \
1156 test/py/ganeti.utils.retry_unittest.py \
1157 test/py/ganeti.utils.text_unittest.py \
1158 test/py/ganeti.utils.wrapper_unittest.py \
1159 test/py/ganeti.utils.x509_unittest.py \
1160 test/py/ganeti.utils_unittest.py \
1161 test/py/ganeti.vcluster_unittest.py \
1162 test/py/ganeti.workerpool_unittest.py \
1163 test/py/pycurl_reset_unittest.py \
1164 test/py/qa.qa_config_unittest.py \
1165 test/py/tempfile_fork_unittest.py
1167 haskell_tests = test/hs/htest
1170 test/py/check-cert-expired_unittest.bash \
1171 test/py/daemon-util_unittest.bash \
1172 test/py/ganeti-cleaner_unittest.bash \
1173 test/py/import-export_unittest.bash \
1174 test/py/cli-test.bash \
1175 test/py/bash_completion.bash \
1182 nodist_TESTS += $(haskell_tests)
1183 dist_TESTS += test/hs/offline-test.sh
1185 test/hs/hpc-htools \
1186 test/hs/hpc-mon-collector \
1187 $(HS_BUILT_TEST_HELPERS)
1190 TESTS = $(dist_TESTS) $(nodist_TESTS)
1192 # Environment for all tests
1193 PLAIN_TESTS_ENVIRONMENT = \
1195 TOP_SRCDIR=$(abs_top_srcdir) TOP_BUILDDIR=$(abs_top_builddir) \
1196 PYTHON=$(PYTHON) FAKEROOT=$(FAKEROOT_PATH) \
1199 # Environment for tests run by automake
1200 TESTS_ENVIRONMENT = \
1201 $(PLAIN_TESTS_ENVIRONMENT) $(abs_top_srcdir)/autotools/testrunner
1204 $(dist_sbin_SCRIPTS) \
1206 $(pkglib_python_scripts) \
1207 $(nodist_pkglib_python_scripts) \
1208 $(nodist_tools_python_scripts) \
1210 $(pkgpython_PYTHON) \
1212 $(hypervisor_PYTHON) \
1227 test/py/check-cert-expired_unittest.bash \
1228 test/py/daemon-util_unittest.bash \
1229 test/py/ganeti-cleaner_unittest.bash \
1230 test/py/import-export_unittest.bash \
1231 test/py/cli-test.bash \
1232 test/py/bash_completion.bash \
1233 test/hs/offline-test.sh \
1234 test/hs/cli-tests-defs.sh \
1235 $(all_python_code) \
1236 $(HS_LIBTEST_SRCS) $(HS_PROG_SRCS) \
1239 check_python_code = \
1240 $(BUILD_BASH_COMPLETION) \
1246 lint_python_code = \
1248 ganeti/http/server.py \
1249 $(dist_sbin_SCRIPTS) \
1251 $(pkglib_python_scripts) \
1252 $(BUILD_BASH_COMPLETION) \
1258 standalone_python_modules = \
1259 lib/rapi/client.py \
1260 tools/ganeti-listrunner
1262 pep8_python_code = \
1264 ganeti/http/server.py \
1265 $(dist_sbin_SCRIPTS) \
1267 $(pkglib_python_scripts) \
1268 $(BUILD_BASH_COMPLETION) \
1271 $(PYTHON_BOOTSTRAP) \
1274 test/py/daemon-util_unittest.bash: daemons/daemon-util
1276 test/py/ganeti-cleaner_unittest.bash: daemons/ganeti-cleaner
1278 test/py/bash_completion.bash: doc/examples/bash_completion-debug
1280 tools/kvm-ifup: tools/kvm-ifup.in $(REPLACE_VARS_SED)
1281 sed -f $(REPLACE_VARS_SED) < $< > $@
1284 tools/vcluster-setup: tools/vcluster-setup.in $(REPLACE_VARS_SED)
1285 sed -f $(REPLACE_VARS_SED) < $< > $@
1288 daemons/%:: daemons/%.in $(REPLACE_VARS_SED)
1289 sed -f $(REPLACE_VARS_SED) < $< > $@
1292 doc/examples/%:: doc/examples/%.in $(REPLACE_VARS_SED)
1293 sed -f $(REPLACE_VARS_SED) < $< > $@
1295 doc/examples/bash_completion: BC_ARGS = --compact
1296 doc/examples/bash_completion-debug: BC_ARGS =
1298 doc/examples/bash_completion doc/examples/bash_completion-debug: \
1299 $(BUILD_BASH_COMPLETION) $(RUN_IN_TEMPDIR) \
1300 lib/cli.py $(gnt_scripts) $(client_PYTHON) tools/burnin \
1301 daemons/ganeti-cleaner \
1302 $(GENERATED_FILES) $(HS_GENERATED_FILES)
1303 PYTHONPATH=. $(RUN_IN_TEMPDIR) \
1304 $(CURDIR)/$(BUILD_BASH_COMPLETION) $(BC_ARGS) > $@
1306 man/%.gen: man/%.rst lib/query.py lib/build/sphinx_ext.py \
1307 lib/build/shell_example_lexer.py \
1308 | $(RUN_IN_TEMPDIR) $(BUILT_PYTHON_SOURCES)
1309 @echo "Checking $< for hardcoded paths..."
1310 @if grep -nEf autotools/wrong-hardcoded-paths $<; then \
1311 echo "Man page $< has hardcoded paths (see above)!" 1>&2 ; \
1315 trap 'echo auto-removing $@; rm $@' EXIT; \
1316 PYTHONPATH=. $(RUN_IN_TEMPDIR) $(CURDIR)/$(DOCPP) < $< > $@ ;\
1317 $(CHECK_MAN_REFERENCES) $@; \
1320 man/%.7.in man/%.8.in man/%.1.in: man/%.gen man/footer.rst
1321 @test -n "$(PANDOC)" || \
1322 { echo 'pandoc' not found during configure; exit 1; }
1324 trap 'echo auto-removing $@; rm $@' EXIT; \
1325 $(PANDOC) -s -f rst -t man $< man/footer.rst | \
1326 sed -e 's/\\@/@/g' > $@; \
1327 if test -n "$(MAN_HAS_WARNINGS)"; then $(CHECK_MAN_WARNINGS) $@; fi; \
1328 $(CHECK_MAN_DASHES) $@; \
1331 man/%.html.in: man/%.gen man/footer.rst
1332 @test -n "$(PANDOC)" || \
1333 { echo 'pandoc' not found during configure; exit 1; }
1335 $(PANDOC) --toc -s -f rst -t html $< man/footer.rst | \
1336 sed -e 's/\\@/@/g' > $@
1338 man/%: man/%.in $(REPLACE_VARS_SED)
1339 sed -f $(REPLACE_VARS_SED) < $< > $@
1341 epydoc.conf: epydoc.conf.in $(REPLACE_VARS_SED)
1342 sed -f $(REPLACE_VARS_SED) < $< > $@
1345 if test -d .git; then \
1346 git describe > $@; \
1347 elif test ! -f $@ ; then \
1348 echo "Cannot auto-generate $@ file"; exit 1; \
1351 .PHONY: clean-vcs-version
1355 .PHONY: regen-vcs-version
1359 if test -d .git; then \
1360 T=`mktemp` ; trap 'rm -f $$T' EXIT; \
1361 git describe > $$T; \
1362 if ! cmp --quiet $$T vcs-version; then \
1363 mv $$T vcs-version; \
1367 src/Ganeti/Version.hs: src/Ganeti/Version.hs.in \
1368 vcs-version $(built_base_sources)
1370 VCSVER=`cat $(abs_top_srcdir)/vcs-version`; \
1371 sed -e "s/%ver%/$$VCSVER/" < $< > $@
1373 src/Ganeti/Constants.hs: src/Ganeti/Constants.hs.in \
1374 lib/constants.py lib/_autoconf.py lib/luxi.py lib/errors.py \
1375 lib/jstore.py $(RUN_IN_TEMPDIR) \
1376 $(CONVERT_CONSTANTS) $(built_base_sources) \
1377 | lib/_vcsversion.py
1380 PYTHONPATH=. $(RUN_IN_TEMPDIR) $(CURDIR)/$(CONVERT_CONSTANTS); \
1383 src/Ganeti/Curl/Internal.hs: src/Ganeti/Curl/Internal.hsc | stamp-directories
1386 test/hs/Test/Ganeti/TestImports.hs: test/hs/Test/Ganeti/TestImports.hs.in \
1387 $(built_base_sources)
1391 for name in $(filter-out Ganeti.THH,$(subst /,.,$(patsubst %.hs,%,$(patsubst src/%,%,$(HS_LIB_SRCS))))) ; do \
1392 echo "import $$name ()" ; \
1396 lib/_autoconf.py: Makefile | stamp-directories
1398 { echo '# This file is automatically generated, do not edit!'; \
1401 echo '"""Build-time configuration for Ganeti.'; \
1403 echo 'This file is autogenerated by the build process.'; \
1404 echo 'For any changes you need to re-run ./configure (and'; \
1405 echo 'not edit by hand).'; \
1409 echo '# pylint: disable=C0301,C0324'; \
1410 echo '# because this is autogenerated, we do not want'; \
1411 echo '# style warnings' ; \
1413 echo "PACKAGE_VERSION = '$(PACKAGE_VERSION)'"; \
1414 echo "VERSION_MAJOR = '$(VERSION_MAJOR)'"; \
1415 echo "VERSION_MINOR = '$(VERSION_MINOR)'"; \
1416 echo "VERSION_REVISION = '$(VERSION_REVISION)'"; \
1417 echo "VERSION_SUFFIX = '$(VERSION_SUFFIX)'"; \
1418 echo "VERSION_FULL = '$(VERSION_FULL)'"; \
1419 echo "LOCALSTATEDIR = '$(localstatedir)'"; \
1420 echo "SYSCONFDIR = '$(sysconfdir)'"; \
1421 echo "SSH_CONFIG_DIR = '$(SSH_CONFIG_DIR)'"; \
1422 echo "SSH_LOGIN_USER = '$(SSH_LOGIN_USER)'"; \
1423 echo "SSH_CONSOLE_USER = '$(SSH_CONSOLE_USER)'"; \
1424 echo "EXPORT_DIR = '$(EXPORT_DIR)'"; \
1425 echo "OS_SEARCH_PATH = [$(OS_SEARCH_PATH)]"; \
1426 echo "ES_SEARCH_PATH = [$(ES_SEARCH_PATH)]"; \
1427 echo "XEN_BOOTLOADER = '$(XEN_BOOTLOADER)'"; \
1428 echo "XEN_CONFIG_DIR = '$(XEN_CONFIG_DIR)'"; \
1429 echo "XEN_KERNEL = '$(XEN_KERNEL)'"; \
1430 echo "XEN_INITRD = '$(XEN_INITRD)'"; \
1431 echo "KVM_KERNEL = '$(KVM_KERNEL)'"; \
1432 echo "FILE_STORAGE_DIR = '$(FILE_STORAGE_DIR)'"; \
1433 echo "ENABLE_FILE_STORAGE = $(ENABLE_FILE_STORAGE)"; \
1434 echo "SHARED_FILE_STORAGE_DIR = '$(SHARED_FILE_STORAGE_DIR)'"; \
1435 echo "ENABLE_SHARED_FILE_STORAGE = $(ENABLE_SHARED_FILE_STORAGE)"; \
1436 echo "IALLOCATOR_SEARCH_PATH = [$(IALLOCATOR_SEARCH_PATH)]"; \
1437 echo "KVM_PATH = '$(KVM_PATH)'"; \
1438 echo "IP_PATH = '$(IP_PATH)'"; \
1439 echo "SOCAT_PATH = '$(SOCAT)'"; \
1440 echo "SOCAT_USE_ESCAPE = $(SOCAT_USE_ESCAPE)"; \
1441 echo "SOCAT_USE_COMPRESS = $(SOCAT_USE_COMPRESS)"; \
1442 echo "LVM_STRIPECOUNT = $(LVM_STRIPECOUNT)"; \
1443 echo "TOOLSDIR = '$(toolsdir)'"; \
1444 echo "GNT_SCRIPTS = [$(foreach i,$(notdir $(gnt_scripts)),'$(i)',)]"; \
1445 echo "HTOOLS_PROGS = [$(foreach i,$(HS_HTOOLS_PROGS),'$(i)',)]"; \
1446 echo "PKGLIBDIR = '$(pkglibdir)'"; \
1447 echo "DRBD_BARRIERS = '$(DRBD_BARRIERS)'"; \
1448 echo "DRBD_NO_META_FLUSH = $(DRBD_NO_META_FLUSH)"; \
1449 echo "SYSLOG_USAGE = '$(SYSLOG_USAGE)'"; \
1450 echo "DAEMONS_GROUP = '$(DAEMONS_GROUP)'"; \
1451 echo "ADMIN_GROUP = '$(ADMIN_GROUP)'"; \
1452 echo "MASTERD_USER = '$(MASTERD_USER)'"; \
1453 echo "MASTERD_GROUP = '$(MASTERD_GROUP)'"; \
1454 echo "RAPI_USER = '$(RAPI_USER)'"; \
1455 echo "RAPI_GROUP = '$(RAPI_GROUP)'"; \
1456 echo "CONFD_USER = '$(CONFD_USER)'"; \
1457 echo "CONFD_GROUP = '$(CONFD_GROUP)'"; \
1458 echo "NODED_USER = '$(NODED_USER)'"; \
1459 echo "NODED_GROUP = '$(NODED_GROUP)'"; \
1460 echo "DISK_SEPARATOR = '$(DISK_SEPARATOR)'"; \
1461 echo "QEMUIMG_PATH = '$(QEMUIMG_PATH)'"; \
1462 echo "HTOOLS = True"; \
1463 echo "ENABLE_CONFD = $(ENABLE_CONFD)"; \
1464 echo "XEN_CMD = '$(XEN_CMD)'"; \
1465 echo "ENABLE_SPLIT_QUERY = $(ENABLE_SPLIT_QUERY)"; \
1466 echo "ENABLE_RESTRICTED_COMMANDS = $(ENABLE_RESTRICTED_COMMANDS)"; \
1467 echo "ENABLE_MONITORING = $(ENABLE_MONITORING)"; \
1468 ## Write dictionary with man page name as the key and the section number as the
1470 echo "MAN_PAGES = {"; \
1471 for i in $(notdir $(man_MANS)); do \
1472 echo "$$i" | sed -re 's/^(.*)\.([0-9]+)$$/ "\1": \2,/g'; \
1477 lib/_vcsversion.py: Makefile vcs-version | stamp-directories
1479 VCSVER=`cat $(abs_top_srcdir)/vcs-version`; \
1480 { echo '# This file is automatically generated, do not edit!'; \
1483 echo '"""Build-time VCS version number for Ganeti.'; \
1485 echo 'This file is autogenerated by the build process.'; \
1486 echo 'For any changes you need to re-run ./configure (and'; \
1487 echo 'not edit by hand).'; \
1491 echo '# pylint: disable=C0301,C0324'; \
1492 echo '# because this is autogenerated, we do not want'; \
1493 echo '# style warnings' ; \
1495 echo "VCS_VERSION = '$$VCSVER'"; \
1498 lib/_generated_rpc.py: lib/rpc_defs.py $(BUILD_RPC)
1499 PYTHONPATH=. $(RUN_IN_TEMPDIR) $(CURDIR)/$(BUILD_RPC) lib/rpc_defs.py > $@
1501 $(SHELL_ENV_INIT): Makefile stamp-directories
1503 { echo '# Allow overriding for tests'; \
1504 echo 'readonly LOCALSTATEDIR=$${LOCALSTATEDIR:-$${GANETI_ROOTDIR:-}$(localstatedir)}'; \
1505 echo 'readonly SYSCONFDIR=$${SYSCONFDIR:-$${GANETI_ROOTDIR:-}$(sysconfdir)}'; \
1507 echo 'readonly PKGLIBDIR=$(pkglibdir)'; \
1508 echo 'readonly LOG_DIR="$$LOCALSTATEDIR/log/ganeti"'; \
1509 echo 'readonly RUN_DIR="$$LOCALSTATEDIR/run/ganeti"'; \
1510 echo 'readonly DATA_DIR="$$LOCALSTATEDIR/lib/ganeti"'; \
1511 echo 'readonly CONF_DIR="$$SYSCONFDIR/ganeti"'; \
1514 ## Writes sed script to replace placeholders with build-time values. The
1515 ## additional quotes after the first @ sign are necessary to stop configure
1516 ## from replacing those values as well.
1517 $(REPLACE_VARS_SED): $(SHELL_ENV_INIT) Makefile stamp-directories
1519 { echo 's#@''PREFIX@#$(prefix)#g'; \
1520 echo 's#@''SYSCONFDIR@#$(sysconfdir)#g'; \
1521 echo 's#@''LOCALSTATEDIR@#$(localstatedir)#g'; \
1522 echo 's#@''BINDIR@#$(bindir)#g'; \
1523 echo 's#@''SBINDIR@#$(sbindir)#g'; \
1524 echo 's#@''LIBDIR@#$(libdir)#g'; \
1525 echo 's#@''GANETI_VERSION@#$(PACKAGE_VERSION)#g'; \
1526 echo 's#@''CUSTOM_XEN_BOOTLOADER@#$(XEN_BOOTLOADER)#g'; \
1527 echo 's#@''CUSTOM_XEN_KERNEL@#$(XEN_KERNEL)#g'; \
1528 echo 's#@''CUSTOM_XEN_INITRD@#$(XEN_INITRD)#g'; \
1529 echo 's#@''CUSTOM_IALLOCATOR_SEARCH_PATH@#$(IALLOCATOR_SEARCH_PATH)#g'; \
1530 echo 's#@''CUSTOM_EXPORT_DIR@#$(EXPORT_DIR)#g'; \
1531 echo 's#@''RPL_FILE_STORAGE_DIR@#$(FILE_STORAGE_DIR)#g'; \
1532 echo 's#@''RPL_SSH_INITD_SCRIPT@#$(SSH_INITD_SCRIPT)#g'; \
1533 echo 's#@''PKGLIBDIR@#$(pkglibdir)#g'; \
1534 echo 's#@''GNTMASTERUSER@#$(MASTERD_USER)#g'; \
1535 echo 's#@''GNTRAPIUSER@#$(RAPI_USER)#g'; \
1536 echo 's#@''GNTCONFDUSER@#$(CONFD_USER)#g'; \
1537 echo 's#@''GNTNODEDUSER@#$(NODED_USER)#g'; \
1538 echo 's#@''GNTRAPIGROUP@#$(RAPI_GROUP)#g'; \
1539 echo 's#@''GNTADMINGROUP@#$(ADMIN_GROUP)#g'; \
1540 echo 's#@''GNTCONFDGROUP@#$(CONFD_GROUP)#g'; \
1541 echo 's#@''GNTMASTERDGROUP@#$(MASTERD_GROUP)#g'; \
1542 echo 's#@''GNTDAEMONSGROUP@#$(DAEMONS_GROUP)#g'; \
1543 echo 's#@''CUSTOM_ENABLE_CONFD@#$(ENABLE_CONFD)#g'; \
1544 echo 's#@''MODULES@#$(strip $(lint_python_code))#g'; \
1545 echo 's#@''XEN_CONFIG_DIR@#$(XEN_CONFIG_DIR)#g'; \
1547 echo '/^@SHELL_ENV_INIT@$$/ {'; \
1548 echo ' r $(SHELL_ENV_INIT)'; \
1553 # Using deferred evaluation
1554 daemons/ganeti-%: MODULE = ganeti.server.$(patsubst ganeti-%,%,$(notdir $@))
1555 daemons/ganeti-watcher: MODULE = ganeti.watcher
1556 scripts/%: MODULE = ganeti.client.$(subst -,_,$(notdir $@))
1557 tools/burnin: MODULE = ganeti.tools.burnin
1558 tools/ensure-dirs: MODULE = ganeti.tools.ensure_dirs
1559 tools/node-daemon-setup: MODULE = ganeti.tools.node_daemon_setup
1560 tools/prepare-node-join: MODULE = ganeti.tools.prepare_node_join
1561 tools/node-cleanup: MODULE = ganeti.tools.node_cleanup
1562 $(HS_BUILT_TEST_HELPERS): TESTROLE = $(patsubst test/hs/%,%,$@)
1564 $(PYTHON_BOOTSTRAP): Makefile | stamp-directories
1565 test -n "$(MODULE)" || { echo Missing module; exit 1; }
1567 { echo '#!/usr/bin/python'; \
1568 echo '# This file is automatically generated, do not edit!'; \
1569 echo "# Edit $(MODULE) instead."; \
1571 echo '"""Bootstrap script for L{$(MODULE)}"""'; \
1573 echo '# pylint: disable=C0103'; \
1574 echo '# C0103: Invalid name'; \
1576 echo 'import sys'; \
1577 echo 'import $(MODULE) as main'; \
1579 echo '# Temporarily alias commands until bash completion'; \
1580 echo '# generator is changed'; \
1581 echo 'if hasattr(main, "commands"):'; \
1582 echo ' commands = main.commands # pylint: disable=E1101'; \
1583 echo 'if hasattr(main, "aliases"):'; \
1584 echo ' aliases = main.aliases # pylint: disable=E1101'; \
1586 echo 'if __name__ == "__main__":'; \
1587 echo ' sys.exit(main.Main())'; \
1591 $(HS_BUILT_TEST_HELPERS): Makefile
1592 @test -n "$(TESTROLE)" || { echo Missing TESTROLE; exit 1; }
1594 { echo '#!/bin/sh'; \
1595 echo '# This file is automatically generated, do not edit!'; \
1596 echo "# Edit Makefile.am instead."; \
1598 echo "HTOOLS=$(TESTROLE) exec ./test/hs/hpc-htools \"\$$@\""; \
1602 stamp-directories: Makefile
1603 $(MAKE) $(AM_MAKEFLAGS) ganeti
1604 @mkdir_p@ $(DIRS) $(BUILDTIME_DIR_AUTOCREATE)
1607 # We need to create symlinks because "make distcheck" will not install Python
1608 # files when building.
1609 stamp-srclinks: Makefile | stamp-directories
1611 for i in $(srclink_files); do \
1612 if test ! -f $$i -a -f $(abs_top_srcdir)/$$i; then \
1613 $(LN_S) $(abs_top_srcdir)/$$i $$i; \
1620 cd $(top_builddir) && test -h "$@" || { rm -f $@ && $(LN_S) lib $@; }
1623 check-dirs: $(GENERATED_FILES)
1625 find . -type d \( -name . -o -name .git -prune -o -print \) | { \
1627 while read dir; do \
1629 $(strip $(patsubst %,(./%) ;;,$(DIRCHECK_EXCLUDE) $(DIRS))) \
1630 *) error=1; echo "Directory $$dir not listed in Makefile" >&2 ;; \
1633 for dir in $(DIRS); do \
1634 if ! test -d "$$dir"; then \
1635 echo "Directory $$dir listed in DIRS does not exist" >&2; \
1639 test -z "$$error"; \
1643 check-local: check-dirs $(GENERATED_FILES)
1644 $(CHECK_PYTHON_CODE) $(check_python_code)
1645 PYTHONPATH=. $(CHECK_HEADER) $(check_python_code)
1646 $(CHECK_VERSION) $(VERSION) $(top_srcdir)/NEWS
1647 $(CHECK_NEWS) < $(top_srcdir)/NEWS
1648 PYTHONPATH=. $(RUN_IN_TEMPDIR) $(CURDIR)/$(CHECK_IMPORTS) . $(standalone_python_modules)
1649 @expver=$(VERSION_MAJOR).$(VERSION_MINOR); \
1651 if test "`head -n 1 $(top_srcdir)/README`" != "Ganeti $$expver"; then \
1652 echo "Incorrect version in README, expected $$expver" >&2; \
1655 for file in doc/iallocator.rst doc/hooks.rst doc/virtual-cluster.rst \
1656 doc/security.rst; do \
1657 if test "`sed -ne '4 p' $(top_srcdir)/$$file`" != \
1658 "Documents Ganeti version $$expver"; then \
1659 echo "Incorrect version in $$file, expected $$expver" >&2; \
1663 if ! test -f $(top_srcdir)/doc/design-$$expver.rst; then \
1664 echo "File $(top_srcdir)/doc/design-$$expver.rst not found" >&2; \
1667 if test "`sed -ne '5 p' $(top_srcdir)/doc/design-draft.rst`" != \
1668 ".. Last updated for Ganeti $$expver"; then \
1669 echo "doc/design-draft.rst was not updated for version $$expver" >&2; \
1672 for file in configure.ac $(HS_LIBTEST_SRCS) $(HS_PROG_SRCS); do \
1673 if test $$(wc --max-line-length < $(top_srcdir)/$$file) -gt 80; then \
1674 echo "Longest line in $$file is longer than 80 characters" >&2; \
1681 hs-tests: test/hs/htest | $(BUILT_PYTHON_SOURCES)
1686 hs-shell: test/hs/hpc-htools test/hs/hpc-mon-collector $(HS_BUILT_TEST_HELPERS)
1687 @rm -f hpc-htools.tix hpc-mon-collector.tix
1688 HBINARY="./test/hs/hpc-htools" ./test/hs/offline-test.sh
1691 hs-check: hs-tests hs-shell
1693 # E111: indentation is not a multiple of four
1694 # E121: continuation line indentation is not a multiple of four
1695 # (since our indent level is not 4)
1696 # E125: continuation line does not distinguish itself from next logical line
1697 # (since our indent level is not 4)
1698 # E127: continuation line over-indented for visual indent
1699 # (since our indent level is not 4)
1700 # note: do NOT add E128 here; it's a valid style error in most cases!
1701 # I've seen real errors, but also some cases were we indent wrongly
1702 # due to line length; try to rework the cases where it is triggered,
1703 # instead of silencing it
1704 # E261: at least two spaces before inline comment
1705 # E501: line too long (80 characters)
1706 PEP8_IGNORE = E111,E121,E125,E127,E261,E501
1708 # For excluding pep8 expects filenames only, not whole paths
1709 PEP8_EXCLUDE = $(subst $(space),$(comma),$(strip $(notdir $(BUILT_PYTHON_SOURCES))))
1711 LINT_TARGETS = pylint pylint-qa
1713 LINT_TARGETS += pep8
1716 LINT_TARGETS += hlint
1720 lint: $(LINT_TARGETS)
1723 pylint: $(GENERATED_FILES)
1724 @test -n "$(PYLINT)" || { echo 'pylint' not found during configure; exit 1; }
1725 $(PYLINT) $(LINT_OPTS) $(lint_python_code)
1728 pylint-qa: $(GENERATED_FILES)
1729 @test -n "$(PYLINT)" || { echo 'pylint' not found during configure; exit 1; }
1730 cd $(top_srcdir)/qa && \
1731 PYTHONPATH=$(abs_top_srcdir) $(PYLINT) $(LINT_OPTS) \
1732 --rcfile ../pylintrc $(patsubst qa/%.py,%,$(qa_scripts))
1735 pep8: $(GENERATED_FILES)
1736 @test -n "$(PEP8)" || { echo 'pep8' not found during configure; exit 1; }
1737 $(PEP8) --ignore='$(PEP8_IGNORE)' --exclude='$(PEP8_EXCLUDE)' \
1738 --repeat $(pep8_python_code)
1740 # FIXME: remove ignore "Use void" when GHC 6.x is deprecated
1741 HLINT_EXCLUDES = src/Ganeti/THH.hs test/hs/hpc-htools.hs
1743 hlint: $(HS_BUILT_SRCS) src/lint-hints.hs
1744 @test -n "$(HLINT)" || { echo 'hlint' not found during configure; exit 1; }
1745 @rm -f doc/hs-lint.html
1746 if tty -s; then C="-c"; else C=""; fi; \
1747 $(HLINT) --utf8 --report=doc/hs-lint.html --cross $$C \
1748 --ignore "Use first" \
1749 --ignore "Use &&&" \
1750 --ignore "Use void" \
1751 --ignore "Reduce duplication" \
1752 --hint src/lint-hints \
1753 $(filter-out $(HLINT_EXCLUDES),$(HS_LIBTEST_SRCS) $(HS_PROG_SRCS))
1754 @if [ ! -f doc/hs-lint.html ]; then \
1755 echo "All good" > doc/hs-lint.html; \
1758 # a dist hook rule for updating the vcs-version file; this is
1759 # hardcoded due to where it needs to build the file...
1761 $(MAKE) $(AM_MAKEFLAGS) regen-vcs-version
1762 rm -f $(top_distdir)/vcs-version
1763 cp -p $(srcdir)/vcs-version $(top_distdir)
1765 # a distcheck hook rule for catching revision control directories
1767 if find $(top_distdir) -name .svn -or -name .git | grep .; then \
1768 echo "Found revision control files in final archive." 1>&2; \
1771 if find $(top_distdir) -name '*.py[co]' | grep .; then \
1772 echo "Found Python byte code in final archive." 1>&2; \
1775 if find $(top_distdir) -name '*~' | grep .; then \
1776 echo "Found backup files in final archive." 1>&2; \
1779 # Empty files or directories should not be distributed. They can cause
1780 # unnecessary warnings for packagers. Directories used by automake during
1781 # distcheck must be excluded.
1782 if find $(top_distdir) -empty -and -not \( \
1783 -path $(top_distdir)/_build -or \
1784 -path $(top_distdir)/_inst \) | grep .; then \
1785 echo "Found empty files or directories in final archive." 1>&2; \
1788 if test -n "$(BUILD_RELEASE)" && \
1789 grep -n -H -E '^\*.*unreleased' $(top_distdir)/NEWS; then \
1790 echo "Found unreleased version in NEWS." >&2; \
1793 if test -e $(top_distdir)/doc/man-html; then \
1794 echo "Found documentation including man pages in final archive" >&2; \
1798 # When building a release, stricter checks should be used
1799 distcheck-release dist-release: export BUILD_RELEASE = 1
1800 distcheck-release: distcheck
1802 distrebuildcheck: dist
1804 builddir=$$(mktemp -d $(abs_srcdir)/distrebuildcheck.XXXXXXX); \
1805 trap "echo Removing $$builddir; cd $(abs_srcdir); rm -rf $$builddir" EXIT; \
1807 tar xzf $(abs_srcdir)/$(distdir).tar.gz; \
1810 $(MAKE) maintainer-clean; \
1811 cp $(abs_srcdir)/vcs-version .; \
1813 $(MAKE) $(AM_MAKEFLAGS)
1817 for i in $(DIST_ARCHIVES); do \
1818 echo -n "Checking $$i ... "; \
1819 autotools/check-tar < $$i; \
1824 @mkdir_p@ "$(DESTDIR)${localstatedir}/lib/ganeti" \
1825 "$(DESTDIR)${localstatedir}/log/ganeti" \
1826 "$(DESTDIR)${localstatedir}/run/ganeti"
1830 apidoc: py-apidoc hs-apidoc
1836 py-apidoc: epydoc.conf $(RUN_IN_TEMPDIR) $(GENERATED_FILES)
1837 env - PATH="$$PATH" PYTHONPATH="$$PYTHONPATH" \
1838 $(RUN_IN_TEMPDIR) epydoc -v \
1839 --conf $(CURDIR)/epydoc.conf \
1840 --output $(CURDIR)/$(APIDOC_PY_DIR)
1843 hs-apidoc: $(HS_BUILT_SRCS)
1844 @test -n "$(HSCOLOUR)" || \
1845 { echo 'HsColour' not found during configure; exit 1; }
1846 @test -n "$(HADDOCK)" || \
1847 { echo 'haddock' not found during configure; exit 1; }
1848 rm -rf $(APIDOC_HS_DIR)/*
1849 for i in $(ALL_APIDOC_HS_DIRS); do \
1852 $(HSCOLOUR) -print-css > $(APIDOC_HS_DIR)/Ganeti/hscolour.css
1853 $(LN_S) ../hscolour.css $(APIDOC_HS_DIR)/Ganeti/HTools/hscolour.css
1854 $(LN_S) ../hscolour.css $(APIDOC_HS_DIR)/Ganeti/Confd/hscolour.css
1858 if [ "$(HS_PARALLEL3)" ]; \
1859 then OPTGHC="$$OPTGHC --optghc=$(HS_PARALLEL3)"; \
1861 if [ "$(HS_REGEX_PCRE)" ]; \
1862 then OPTGHC="$$OPTGHC --optghc=$(HS_REGEX_PCRE)"; \
1864 RELSRCS="$(HS_LIB_SRCS:src/%=%) $(patsubst src/%,%,$(filter src/%,$(HS_BUILT_SRCS)))"; \
1865 for file in $$RELSRCS; do \
1866 hfile=`echo $$file|sed 's/\\.hs$$//'`.html; \
1867 $(HSCOLOUR) -css -anchor $$file > ../$(APIDOC_HS_DIR)/$$hfile ; \
1869 $(HADDOCK) --odir ../$(APIDOC_HS_DIR) --html --ignore-all-exports -w \
1870 -t ganeti -p haddock-prologue \
1871 --source-module="%{MODULE/.//}.html" \
1872 --source-entity="%{MODULE/.//}.html#%{NAME}" \
1874 $(filter-out Ganeti/HTools/ExtLoader.hs,$(HS_LIB_SRCS:src/%=%))
1877 TAGS: $(GENERATED_FILES)
1879 $(GHC) -e ":etags" -v0 \
1880 $(filter-out -O -Werror,$(HFLAGS)) \
1881 $(HS_PARALLEL3) $(HS_REGEX_PCRE) \
1883 find . -path './lib/*.py' -o -path './scripts/gnt-*' -o \
1884 -path './daemons/ganeti-*' -o -path './tools/*' -o \
1885 -path './qa/*.py' | \
1886 etags -l python -a -
1890 coverage: py-coverage hs-coverage
1892 coverage: py-coverage
1896 py-coverage: $(GENERATED_FILES) $(python_tests)
1897 @test -n "$(PYCOVERAGE)" || \
1898 { echo 'python-coverage' not found during configure; exit 1; }
1900 COVERAGE=$(PYCOVERAGE) \
1901 COVERAGE_FILE=$(CURDIR)/$(COVERAGE_PY_DIR)/data \
1902 TEXT_COVERAGE=$(CURDIR)/$(COVERAGE_PY_DIR)/report.txt \
1903 HTML_COVERAGE=$(CURDIR)/$(COVERAGE_PY_DIR) \
1904 $(PLAIN_TESTS_ENVIRONMENT) \
1905 $(abs_top_srcdir)/autotools/gen-py-coverage \
1909 hs-coverage: $(haskell_tests) test/hs/hpc-htools test/hs/hpc-mon-collector
1911 $(MAKE) $(AM_MAKEFLAGS) hs-check
1912 @mkdir_p@ $(COVERAGE_HS_DIR)
1913 hpc sum --union $(HPCEXCL) \
1914 htest.tix hpc-htools.tix hpc-mon-collector.tix > coverage-hs.tix
1915 hpc markup --destdir=$(COVERAGE_HS_DIR) coverage-hs.tix
1916 hpc report coverage-hs.tix
1917 $(LN_S) -f hpc_index.html $(COVERAGE_HS_DIR)/index.html
1919 # Special "kind-of-QA" target for htools, needs special setup (all
1920 # tools compiled with -fhpc)
1925 rm -f .hpc; $(LN_S) ../.hpc .hpc; \
1926 rm -f *.tix *.mix; \
1928 hpc sum --union $(HPCEXCL) $(addsuffix .tix,$(HS_PROGS:src/%=%)) \
1929 --output=live-test.tix ; \
1930 @mkdir_p@ ../$(COVERAGE_HS_DIR) ; \
1931 hpc markup --destdir=../$(COVERAGE_HS_DIR) live-test \
1932 --srcdir=.. $(HPCEXCL) ; \
1933 hpc report --srcdir=.. live-test $(HPCEXCL)
1935 commit-check: distcheck lint apidoc
1937 .PHONY: gitignore-check
1939 @if [ -n "`git status --short`" ]; then \
1940 echo "Git status is not clean!" 1>&2 ; \
1941 git status --short; \
1945 # target to rebuild all man pages (both groff and html output)
1947 man: $(man_MANS) $(manhtml)
1949 # Target that builds all binaries (including those that are not
1950 # rebuilt except when running the tests)
1952 really-all: all $(check_SCRIPTS) $(haskell_tests) $(HS_ALL_PROGS)
1954 # we don't need the ancient implicit rules:
1961 -include ./Makefile.local