Move bootstrap-related RPC to generated wrappers
[ganeti-local] / Makefile.am
index 2a513f1..147ab6c 100644 (file)
@@ -28,6 +28,7 @@ CHECK_IMPORTS = $(top_srcdir)/autotools/check-imports
 DOCPP = $(top_srcdir)/autotools/docpp
 REPLACE_VARS_SED = autotools/replace_vars.sed
 CONVERT_CONSTANTS = $(top_srcdir)/autotools/convert-constants
+BUILD_RPC = $(top_srcdir)/autotools/build-rpc
 
 # Note: these are automake-specific variables, and must be named after
 # the directory + 'dir' suffix
@@ -144,6 +145,7 @@ CLEANFILES = \
        doc/examples/ganeti.cron \
        doc/examples/gnt-config-backup \
        doc/examples/hooks/ipsec \
+       lib/_generated_rpc.py \
        $(man_MANS) \
        $(manhtml) \
        tools/kvm-ifup \
@@ -164,13 +166,15 @@ BUILT_SOURCES = \
 
 BUILT_PYTHON_SOURCES = \
        lib/_autoconf.py \
-       lib/_vcsversion.py
+       lib/_vcsversion.py \
+       lib/_generated_rpc.py
 
 nodist_pkgpython_PYTHON = \
        $(BUILT_PYTHON_SOURCES)
 
 noinst_PYTHON = \
        lib/build/__init__.py \
+       lib/build/rpc_definitions.py \
        lib/build/sphinx_ext.py
 
 pkgpython_PYTHON = \
@@ -273,11 +277,11 @@ pytools_PYTHON = \
 utils_PYTHON = \
        lib/utils/__init__.py \
        lib/utils/algo.py \
-       lib/utils/cfunc.py \
        lib/utils/filelock.py \
        lib/utils/hash.py \
        lib/utils/io.py \
        lib/utils/log.py \
+       lib/utils/mlock.py \
        lib/utils/nodesetup.py \
        lib/utils/process.py \
        lib/utils/retry.py \
@@ -555,6 +559,7 @@ EXTRA_DIST = \
        epydoc.conf.in \
        pylintrc \
        autotools/build-bash-completion \
+       autotools/build-rpc \
        autotools/check-python-code \
        autotools/check-imports \
        autotools/check-man \
@@ -724,11 +729,11 @@ python_tests = \
        test/ganeti.tools.ensure_dirs_unittest.py \
        test/ganeti.uidpool_unittest.py \
        test/ganeti.utils.algo_unittest.py \
-       test/ganeti.utils.cfunc_unittest.py \
        test/ganeti.utils.filelock_unittest.py \
        test/ganeti.utils.hash_unittest.py \
        test/ganeti.utils.io_unittest.py \
        test/ganeti.utils.log_unittest.py \
+       test/ganeti.utils.mlock_unittest.py \
        test/ganeti.utils.nodesetup_unittest.py \
        test/ganeti.utils.process_unittest.py \
        test/ganeti.utils.retry_unittest.py \
@@ -739,6 +744,7 @@ python_tests = \
        test/ganeti.workerpool_unittest.py \
        test/cfgupgrade_unittest.py \
        test/docs_unittest.py \
+       test/pycurl_reset_unittest.py \
        test/tempfile_fork_unittest.py
 
 haskell_tests = htools/test
@@ -985,6 +991,7 @@ lib/_autoconf.py: Makefile | lib/.dir
          echo "NODED_USER = '$(NODED_USER)'"; \
          echo "NODED_GROUP = '$(NODED_GROUP)'"; \
          echo "DISK_SEPARATOR = '$(DISK_SEPARATOR)'"; \
+         echo "QEMUIMG_PATH = '$(QEMUIMG_PATH)'"; \
          if [ "$(HTOOLS)" ]; then \
            echo "HTOOLS = True"; \
          else \
@@ -1013,6 +1020,9 @@ lib/_vcsversion.py: Makefile vcs-version | lib/.dir
          echo "VCS_VERSION = '$$VCSVER'"; \
        } > $@
 
+lib/_generated_rpc.py: lib/build/rpc_definitions.py $(BUILD_RPC) | lib/.dir
+       PYTHONPATH=. $(RUN_IN_TEMPDIR) $(CURDIR)/$(BUILD_RPC) $< > $@
+
 $(REPLACE_VARS_SED): Makefile
        set -e; \
        { echo 's#@PREFIX@#$(prefix)#g'; \