diff options
| author | Ben Pfaff <blp@ovn.org> | 2019-09-20 08:30:42 -0700 |
|---|---|---|
| committer | Ben Pfaff <blp@ovn.org> | 2019-09-27 09:23:50 -0700 |
| commit | 1ca0323e7c29dc7ef5a615c265df0460208f92de (patch) | |
| tree | 377630fee2130b269cfe2fd348c9e8c6bc5a814a /debian | |
| parent | 187bb41fbf447acf9fb6ac117dc923bbe649e78c (diff) | |
| download | openvswitch-1ca0323e7c29dc7ef5a615c265df0460208f92de.tar.gz | |
Require Python 3 and remove support for Python 2.
Python 2 reaches end-of-life on January 1, 2020, which is only
a few months away. This means that OVS needs to stop depending
on in the next release that should occur roughly that same time.
Therefore, this commit removes all support for Python 2. It
also makes Python 3 a mandatory build dependency.
Some of the interesting consequences:
- HAVE_PYTHON, HAVE_PYTHON2, and HAVE_PYTHON3 conditionals have
been removed, since we now know that Python3 is available.
- $PYTHON and $PYTHON2 are removed, and $PYTHON3 is always
available.
- Many tests for Python 2 support have been removed, and the ones
that depended on Python 3 now run unconditionally. This allowed
several macros in the testsuite to be removed, making the code
clearer. This does make some of the changes to the testsuite
files large due to indentation level changes.
- #! lines for Python now use /usr/bin/python3 instead of
/usr/bin/python.
- Packaging depends on Python 3 packages.
Acked-by: Numan Siddique <nusiddiq@redhat.com>
Tested-by: Numan Siddique <nusiddiq@redhat.com>
Signed-off-by: Ben Pfaff <blp@ovn.org>
Diffstat (limited to 'debian')
| -rw-r--r-- | debian/.gitignore | 1 | ||||
| -rw-r--r-- | debian/automake.mk | 4 | ||||
| -rw-r--r-- | debian/control | 35 | ||||
| -rw-r--r-- | debian/openvswitch-test.install | 2 | ||||
| -rw-r--r-- | debian/python-openvswitch.install | 1 | ||||
| -rw-r--r-- | debian/python3-openvswitch.dirs (renamed from debian/python-openvswitch.dirs) | 0 | ||||
| -rw-r--r-- | debian/python3-openvswitch.install | 1 | ||||
| -rwxr-xr-x | debian/rules | 2 |
8 files changed, 23 insertions, 23 deletions
diff --git a/debian/.gitignore b/debian/.gitignore index 441a8ffb7..d02526b21 100644 --- a/debian/.gitignore +++ b/debian/.gitignore @@ -23,4 +23,5 @@ /openvswitch-testcontroller /openvswitch-vtep /python-openvswitch +/python3-openvswitch /tmp diff --git a/debian/automake.mk b/debian/automake.mk index 03a1d68c2..37b1a2433 100644 --- a/debian/automake.mk +++ b/debian/automake.mk @@ -52,8 +52,8 @@ EXTRA_DIST += \ debian/openvswitch-vtep.init \ debian/openvswitch-vtep.install \ debian/openvswitch-vtep.manpages \ - debian/python-openvswitch.dirs \ - debian/python-openvswitch.install \ + debian/python3-openvswitch.dirs \ + debian/python3-openvswitch.install \ debian/rules \ debian/rules.modules \ debian/ifupdown.sh \ diff --git a/debian/control b/debian/control index 2ad35f2ce..ad4b18786 100644 --- a/debian/control +++ b/debian/control @@ -13,10 +13,10 @@ Build-Depends: graphviz, libtool, openssl, procps, - python-all (>= 2.7), - python-twisted-conch, - python-zopeinterface, - python-six, + python3-all, + python3-twisted-conch, + python3-zopeinterface, + python3-six, libunbound-dev Standards-Version: 3.9.3 Homepage: http://openvswitch.org/ @@ -41,7 +41,7 @@ Description: Open vSwitch datapath module source - module-assistant version Package: openvswitch-datapath-dkms Architecture: all -Depends: dkms (>= 1.95), libc6-dev, libelf-dev, make, ${misc:Depends}, ${python:Depends} +Depends: dkms (>= 1.95), libc6-dev, libelf-dev, make, ${misc:Depends}, ${python3:Depends} Description: Open vSwitch datapath module source - DKMS version Open vSwitch is a production quality, multilayer, software-based, Ethernet virtual switch. It is designed to enable massive network @@ -58,8 +58,8 @@ Description: Open vSwitch datapath module source - DKMS version Package: openvswitch-common Architecture: linux-any Multi-Arch: foreign -Depends: python (>= 2.7), - python-six, +Depends: python3, + python3-six, libopenvswitch (= ${binary:Version}), ${misc:Depends}, ${shlibs:Depends} @@ -102,10 +102,9 @@ Depends: kmod | module-init-tools, netbase, openvswitch-common (= ${binary:Version}), procps, - python-argparse, uuid-runtime, ${misc:Depends}, - ${python:Depends}, + ${python3:Depends}, ${shlibs:Depends} Description: Open vSwitch switch implementations Open vSwitch is a production quality, multilayer, software-based, @@ -171,10 +170,10 @@ Description: Debug symbols for Open vSwitch packages packages. Install it to debug one of them or to examine a core dump produced by one of them. -Package: python-openvswitch +Package: python3-openvswitch Architecture: all Section: python -Depends: ${misc:Depends}, ${python:Depends}, python-six +Depends: ${misc:Depends}, ${python3:Depends}, python3-six Description: Python bindings for Open vSwitch Open vSwitch is a production quality, multilayer, software-based, Ethernet virtual switch. It is designed to enable massive network @@ -188,10 +187,10 @@ Description: Python bindings for Open vSwitch Package: openvswitch-test Architecture: all -Depends: python (>= 2.7) | python-argparse, - python-twisted-web, +Depends: python3, + python3-twisted-web, ${misc:Depends}, - ${python:Depends} + ${python3:Depends} Description: Open vSwitch test package Open vSwitch is a production quality, multilayer, software-based, Ethernet virtual switch. It is designed to enable massive network @@ -208,8 +207,8 @@ Package: openvswitch-vtep Architecture: linux-any Depends: openvswitch-common (>= ${binary:Version}), openvswitch-switch (>= ${binary:Version}), - python, - python-openvswitch (>= ${source:Version}), + python3, + python3-openvswitch (>= ${source:Version}), ${misc:Depends}, ${shlibs:Depends} Description: Open vSwitch VTEP utilities @@ -250,8 +249,8 @@ Architecture: linux-any Depends: iproute2, openvswitch-common (= ${binary:Version}), openvswitch-switch (= ${binary:Version}), - python, - python-openvswitch (= ${source:Version}), + python3, + python3-openvswitch (= ${source:Version}), strongswan, ${misc:Depends}, ${shlibs:Depends} diff --git a/debian/openvswitch-test.install b/debian/openvswitch-test.install index 8a01a5125..cb371c906 100644 --- a/debian/openvswitch-test.install +++ b/debian/openvswitch-test.install @@ -1,3 +1,3 @@ usr/bin/ovs-l3ping usr/bin/ovs-test -usr/share/openvswitch/python/ovstest usr/lib/python2.7/dist-packages/ +usr/share/openvswitch/python/ovstest usr/lib/python3.7/dist-packages/ diff --git a/debian/python-openvswitch.install b/debian/python-openvswitch.install deleted file mode 100644 index 0472d413f..000000000 --- a/debian/python-openvswitch.install +++ /dev/null @@ -1 +0,0 @@ -usr/share/openvswitch/python/ovs usr/lib/python2.7/dist-packages/ diff --git a/debian/python-openvswitch.dirs b/debian/python3-openvswitch.dirs index cbf0de33d..cbf0de33d 100644 --- a/debian/python-openvswitch.dirs +++ b/debian/python3-openvswitch.dirs diff --git a/debian/python3-openvswitch.install b/debian/python3-openvswitch.install new file mode 100644 index 000000000..7ba956e3b --- /dev/null +++ b/debian/python3-openvswitch.install @@ -0,0 +1 @@ +usr/share/openvswitch/python/ovs usr/lib/python3.7/dist-packages/ diff --git a/debian/rules b/debian/rules index 77f3a1984..4dc05c39b 100755 --- a/debian/rules +++ b/debian/rules @@ -22,7 +22,7 @@ PARALLEL = endif %: - dh $@ --with autoreconf,python2 --parallel + dh $@ --with autoreconf,python3 --parallel # use --as-needed only if supported by dh-autoreconf (to simplify backporting) DH_AS_NEEDED=$(shell dpkg --compare-versions $$(dpkg --status dh-autoreconf | grep Version | cut -d' ' -f2) ge 6 && echo --as-needed) |
