]> git.proxmox.com Git - ovs.git/blame - python/automake.mk
python: Fix attempt to use a bool as a function.
[ovs.git] / python / automake.mk
CommitLineData
0be6140a
AA
1ovstest_pyfiles = \
2 python/ovstest/__init__.py \
3 python/ovstest/args.py \
4 python/ovstest/rpcserver.py \
5 python/ovstest/tcp.py \
2d8bdd8f 6 python/ovstest/tests.py \
0be6140a 7 python/ovstest/udp.py \
8d25d9a2
AA
8 python/ovstest/util.py \
9 python/ovstest/vswitch.py
0be6140a 10
99155935
BP
11ovs_pyfiles = \
12 python/ovs/__init__.py \
13 python/ovs/daemon.py \
14 python/ovs/db/__init__.py \
15 python/ovs/db/data.py \
16 python/ovs/db/error.py \
17 python/ovs/db/idl.py \
18 python/ovs/db/parser.py \
19 python/ovs/db/schema.py \
20 python/ovs/db/types.py \
21 python/ovs/fatal_signal.py \
22 python/ovs/json.py \
23 python/ovs/jsonrpc.py \
24 python/ovs/ovsuuid.py \
25 python/ovs/poller.py \
26 python/ovs/process.py \
27 python/ovs/reconnect.py \
28 python/ovs/socket_util.py \
29 python/ovs/stream.py \
30 python/ovs/timeval.py \
53cf9963
BP
31 python/ovs/unixctl/__init__.py \
32 python/ovs/unixctl/client.py \
33 python/ovs/unixctl/server.py \
0a68ffd2 34 python/ovs/util.py \
4fb7d814 35 python/ovs/version.py \
0a68ffd2
EJ
36 python/ovs/vlog.py
37
7b8c46c8
BP
38# These python files are used at build time but not runtime,
39# so they are not installed.
40EXTRA_DIST += \
41 python/build/__init__.py \
42 python/build/nroff.py
43
77e2b031
TW
44# PyPI support.
45EXTRA_DIST += \
46 python/README.rst \
47 python/setup.py
48
79982e90
EJ
49PYFILES = $(ovs_pyfiles) python/ovs/dirs.py $(ovstest_pyfiles)
50EXTRA_DIST += $(PYFILES)
51PYCOV_CLEAN_FILES += $(PYFILES:.py=.py,cover)
99155935
BP
52
53if HAVE_PYTHON
0be6140a 54nobase_pkgdata_DATA = $(ovs_pyfiles) $(ovstest_pyfiles)
99155935
BP
55ovs-install-data-local:
56 $(MKDIR_P) python/ovs
c3bf5498
BP
57 sed \
58 -e '/^##/d' \
59 -e 's,[@]pkgdatadir[@],$(pkgdatadir),g' \
60 -e 's,[@]RUNDIR[@],$(RUNDIR),g' \
61 -e 's,[@]LOGDIR[@],$(LOGDIR),g' \
62 -e 's,[@]bindir[@],$(bindir),g' \
63 -e 's,[@]sysconfdir[@],$(sysconfdir),g' \
64 -e 's,[@]DBDIR[@],$(DBDIR),g' \
65 < $(srcdir)/python/ovs/dirs.py.template \
b43c6fe2 66 > python/ovs/dirs.py.tmp
99155935
BP
67 $(MKDIR_P) $(DESTDIR)$(pkgdatadir)/python/ovs
68 $(INSTALL_DATA) python/ovs/dirs.py.tmp $(DESTDIR)$(pkgdatadir)/python/ovs/dirs.py
69 rm python/ovs/dirs.py.tmp
77e2b031
TW
70
71python-sdist: $(srcdir)/python/ovs/version.py $(ovs_pyfiles) python/ovs/dirs.py
72 (cd python/ && $(PYTHON) setup.py sdist)
73
74pypi-upload: $(srcdir)/python/ovs/version.py $(ovs_pyfiles) python/ovs/dirs.py
75 (cd python/ && $(PYTHON) setup.py sdist upload)
955400fb
BP
76else
77ovs-install-data-local:
78 @:
99155935
BP
79endif
80install-data-local: ovs-install-data-local
81
44852fdf 82UNINSTALL_LOCAL += ovs-uninstall-local
99155935
BP
83ovs-uninstall-local:
84 rm -f $(DESTDIR)$(pkgdatadir)/python/ovs/dirs.py
4fb7d814
EJ
85
86ALL_LOCAL += $(srcdir)/python/ovs/version.py
87$(srcdir)/python/ovs/version.py: config.status
ef44aa50
BP
88 $(AM_V_GEN)$(ro_shell) > $(@F).tmp && \
89 echo 'VERSION = "$(VERSION)"' >> $(@F).tmp && \
c95ca86e 90 if cmp -s $(@F).tmp $@; then touch $@; rm $(@F).tmp; else mv $(@F).tmp $@; fi
c3bf5498
BP
91
92ALL_LOCAL += $(srcdir)/python/ovs/dirs.py
93$(srcdir)/python/ovs/dirs.py: python/ovs/dirs.py.template
ef44aa50 94 $(AM_V_GEN)sed \
c3bf5498
BP
95 -e '/^##/d' \
96 -e 's,[@]pkgdatadir[@],/usr/local/share/openvswitch,g' \
97 -e 's,[@]RUNDIR[@],/var/run,g' \
98 -e 's,[@]LOGDIR[@],/usr/local/var/log,g' \
99 -e 's,[@]bindir[@],/usr/local/bin,g' \
100 -e 's,[@]sysconfdir[@],/usr/local/etc,g' \
101 -e 's,[@]DBDIR[@],/usr/local/etc/openvswitch,g' \
ef44aa50 102 < $? > $@.tmp && \
c3bf5498 103 mv $@.tmp $@
ab70cd30 104EXTRA_DIST += python/ovs/dirs.py.template