qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [PULL 0/2] Require Python >= 3.5 to build QEMU
@ 2019-12-20 16:51 Eduardo Habkost
  2019-12-20 16:51 ` [PULL 1/2] travis: Replace Python 3.4 build with 3.5 Eduardo Habkost
                   ` (3 more replies)
  0 siblings, 4 replies; 8+ messages in thread
From: Eduardo Habkost @ 2019-12-20 16:51 UTC (permalink / raw)
  To: qemu-devel, Cleber Rosa, Peter Maydell
  Cc: Fam Zheng, Eduardo Habkost, Juan Quintela,
	Philippe Mathieu-Daudé, Markus Armbruster,
	Dr. David Alan Gilbert, Alex Bennée

Differences from the previous Python 3.5 pull request
that was rejected:

* Now tests/vm/netbsd was fixed
* .travis.yml is being updated to replace Python 3.4 job with 3.5

The following changes since commit f59b31e6d0c69792b5d817c5aa0a6ed64fba42e0:

  Merge remote-tracking branch 'remotes/stsquad/tags/pull-tesing-and-misc-191219-1' into staging (2019-12-20 14:00:49 +0000)

are available in the Git repository at:

  git://github.com/ehabkost/qemu.git tags/python-next-pull-request

for you to fetch changes up to ddf90699631db53c981b6a5a63d31c08e0eaeec7:

  configure: Require Python >= 3.5 (2019-12-20 13:45:59 -0300)

----------------------------------------------------------------
Require Python >= 3.5 to build QEMU

Python 2 EOL is 11 days away, we will stop supporting
it in QEMU 5.0.

----------------------------------------------------------------

Eduardo Habkost (2):
  travis: Replace Python 3.4 build with 3.5
  configure: Require Python >= 3.5

 .travis.yml            |  2 +-
 configure              | 18 ++++--------------
 tests/Makefile.include |  5 -----
 3 files changed, 5 insertions(+), 20 deletions(-)

-- 
2.23.0



^ permalink raw reply	[flat|nested] 8+ messages in thread

* [PULL 1/2] travis: Replace Python 3.4 build with 3.5
  2019-12-20 16:51 [PULL 0/2] Require Python >= 3.5 to build QEMU Eduardo Habkost
@ 2019-12-20 16:51 ` Eduardo Habkost
  2019-12-20 16:51 ` [PULL 2/2] configure: Require Python >= 3.5 Eduardo Habkost
                   ` (2 subsequent siblings)
  3 siblings, 0 replies; 8+ messages in thread
From: Eduardo Habkost @ 2019-12-20 16:51 UTC (permalink / raw)
  To: qemu-devel, Cleber Rosa, Peter Maydell
  Cc: Fam Zheng, Eduardo Habkost, Juan Quintela,
	Philippe Mathieu-Daudé, Markus Armbruster,
	Dr. David Alan Gilbert, Alex Bennée

We'll start requiring Python 3.5 to build QEMU.

Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>
---
 .travis.yml | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/.travis.yml b/.travis.yml
index 376b7d6dfa..638fba4799 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -247,7 +247,7 @@ matrix:
         - CACHE_NAME="${TRAVIS_BRANCH}-linux-gcc-default"
       language: python
       python:
-        - "3.4"
+        - "3.5"
 
 
     - env:
-- 
2.23.0



^ permalink raw reply related	[flat|nested] 8+ messages in thread

* [PULL 2/2] configure: Require Python >= 3.5
  2019-12-20 16:51 [PULL 0/2] Require Python >= 3.5 to build QEMU Eduardo Habkost
  2019-12-20 16:51 ` [PULL 1/2] travis: Replace Python 3.4 build with 3.5 Eduardo Habkost
@ 2019-12-20 16:51 ` Eduardo Habkost
  2019-12-20 18:59   ` Juan Quintela
  2019-12-20 16:53 ` [PULL 0/2] Require Python >= 3.5 to build QEMU Philippe Mathieu-Daudé
  2020-01-06 14:07 ` Peter Maydell
  3 siblings, 1 reply; 8+ messages in thread
From: Eduardo Habkost @ 2019-12-20 16:51 UTC (permalink / raw)
  To: qemu-devel, Cleber Rosa, Peter Maydell
  Cc: Fam Zheng, Eduardo Habkost, Juan Quintela,
	Philippe Mathieu-Daudé, Markus Armbruster,
	Dr. David Alan Gilbert, John Snow, Alex Bennée

Python 3.5 is the oldest Python version available on our
supported build platforms, and Python 2 end of life will be 3
weeks after the planned release date of QEMU 4.2.0.  Drop Python
2 support from configure completely, and require Python 3.5 or
newer.

Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>
Message-Id: <20191016224237.26180-1-ehabkost@redhat.com>
Reviewed-by: John Snow <jsnow@redhat.com>
Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>
---
 configure              | 18 ++++--------------
 tests/Makefile.include |  5 -----
 2 files changed, 4 insertions(+), 19 deletions(-)

diff --git a/configure b/configure
index 940bf9e87a..747d3b4120 100755
--- a/configure
+++ b/configure
@@ -903,9 +903,9 @@ fi
 : ${install=${INSTALL-install}}
 # We prefer python 3.x. A bare 'python' is traditionally
 # python 2.x, but some distros have it as python 3.x, so
-# we check that before python2
+# we check that too
 python=
-for binary in "${PYTHON-python3}" python python2
+for binary in "${PYTHON-python3}" python
 do
     if has "$binary"
     then
@@ -1842,8 +1842,8 @@ fi
 
 # Note that if the Python conditional here evaluates True we will exit
 # with status 1 which is a shell 'false' value.
-if ! $python -c 'import sys; sys.exit(sys.version_info < (2,7))'; then
-  error_exit "Cannot use '$python', Python 2 >= 2.7 or Python 3 is required." \
+if ! $python -c 'import sys; sys.exit(sys.version_info < (3,5))'; then
+  error_exit "Cannot use '$python', Python >= 3.5 is required." \
       "Use --python=/path/to/python to specify a supported Python."
 fi
 
@@ -6594,15 +6594,6 @@ if test "$supported_os" = "no"; then
     echo "us upstream at qemu-devel@nongnu.org."
 fi
 
-# Note that if the Python conditional here evaluates True we will exit
-# with status 1 which is a shell 'false' value.
-if ! $python -c 'import sys; sys.exit(sys.version_info < (3,0))'; then
-  echo
-  echo "warning: Python 2 support is deprecated" >&2
-  echo "warning: Python 3 will be required for building future versions of QEMU" >&2
-  python2="y"
-fi
-
 config_host_mak="config-host.mak"
 
 echo "# Automatically generated by configure - do not modify" >config-all-disas.mak
@@ -7447,7 +7438,6 @@ echo "INSTALL_DATA=$install -c -m 0644" >> $config_host_mak
 echo "INSTALL_PROG=$install -c -m 0755" >> $config_host_mak
 echo "INSTALL_LIB=$install -c -m 0644" >> $config_host_mak
 echo "PYTHON=$python" >> $config_host_mak
-echo "PYTHON2=$python2" >> $config_host_mak
 echo "CC=$cc" >> $config_host_mak
 if $iasl -h > /dev/null 2>&1; then
   echo "IASL=$iasl" >> $config_host_mak
diff --git a/tests/Makefile.include b/tests/Makefile.include
index 31b86674e5..9146e1bdee 100644
--- a/tests/Makefile.include
+++ b/tests/Makefile.include
@@ -1157,7 +1157,6 @@ TESTS_RESULTS_DIR=$(BUILD_DIR)/tests/results
 AVOCADO_SHOW=app
 AVOCADO_TAGS=$(patsubst %-softmmu,-t arch:%, $(filter %-softmmu,$(TARGET_DIRS)))
 
-ifneq ($(PYTHON2),y)
 $(TESTS_VENV_DIR): $(TESTS_VENV_REQ)
 	$(call quiet-command, \
             $(PYTHON) -m venv --system-site-packages $@, \
@@ -1166,10 +1165,6 @@ $(TESTS_VENV_DIR): $(TESTS_VENV_REQ)
             $(TESTS_VENV_DIR)/bin/python -m pip -q install -r $(TESTS_VENV_REQ), \
             PIP, $(TESTS_VENV_REQ))
 	$(call quiet-command, touch $@)
-else
-$(TESTS_VENV_DIR):
-	$(error "venv directory for tests requires Python 3")
-endif
 
 $(TESTS_RESULTS_DIR):
 	$(call quiet-command, mkdir -p $@, \
-- 
2.23.0



^ permalink raw reply related	[flat|nested] 8+ messages in thread

* Re: [PULL 0/2] Require Python >= 3.5 to build QEMU
  2019-12-20 16:51 [PULL 0/2] Require Python >= 3.5 to build QEMU Eduardo Habkost
  2019-12-20 16:51 ` [PULL 1/2] travis: Replace Python 3.4 build with 3.5 Eduardo Habkost
  2019-12-20 16:51 ` [PULL 2/2] configure: Require Python >= 3.5 Eduardo Habkost
@ 2019-12-20 16:53 ` Philippe Mathieu-Daudé
  2020-01-06 14:07 ` Peter Maydell
  3 siblings, 0 replies; 8+ messages in thread
From: Philippe Mathieu-Daudé @ 2019-12-20 16:53 UTC (permalink / raw)
  To: Eduardo Habkost, qemu-devel, Cleber Rosa, Peter Maydell
  Cc: Fam Zheng, Markus Armbruster, Alex Bennée,
	Dr. David Alan Gilbert, Juan Quintela

On 12/20/19 5:51 PM, Eduardo Habkost wrote:
> Differences from the previous Python 3.5 pull request
> that was rejected:
> 
> * Now tests/vm/netbsd was fixed
> * .travis.yml is being updated to replace Python 3.4 job with 3.5
> 
> The following changes since commit f59b31e6d0c69792b5d817c5aa0a6ed64fba42e0:
> 
>    Merge remote-tracking branch 'remotes/stsquad/tags/pull-tesing-and-misc-191219-1' into staging (2019-12-20 14:00:49 +0000)
> 
> are available in the Git repository at:
> 
>    git://github.com/ehabkost/qemu.git tags/python-next-pull-request
> 
> for you to fetch changes up to ddf90699631db53c981b6a5a63d31c08e0eaeec7:
> 
>    configure: Require Python >= 3.5 (2019-12-20 13:45:59 -0300)
> 
> ----------------------------------------------------------------
> Require Python >= 3.5 to build QEMU
> 
> Python 2 EOL is 11 days away, we will stop supporting
> it in QEMU 5.0.

That was quick! Thanks for sending it again today :)

> ----------------------------------------------------------------
> 
> Eduardo Habkost (2):
>    travis: Replace Python 3.4 build with 3.5
>    configure: Require Python >= 3.5
> 
>   .travis.yml            |  2 +-
>   configure              | 18 ++++--------------
>   tests/Makefile.include |  5 -----
>   3 files changed, 5 insertions(+), 20 deletions(-)
> 



^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [PULL 2/2] configure: Require Python >= 3.5
  2019-12-20 16:51 ` [PULL 2/2] configure: Require Python >= 3.5 Eduardo Habkost
@ 2019-12-20 18:59   ` Juan Quintela
  2019-12-20 20:12     ` Eduardo Habkost
  0 siblings, 1 reply; 8+ messages in thread
From: Juan Quintela @ 2019-12-20 18:59 UTC (permalink / raw)
  To: Eduardo Habkost
  Cc: Fam Zheng, Peter Maydell, Philippe Mathieu-Daudé, qemu-devel,
	Dr. David Alan Gilbert, John Snow, Cleber Rosa, Alex Bennée,
	Markus Armbruster

Eduardo Habkost <ehabkost@redhat.com> wrote:
> Python 3.5 is the oldest Python version available on our
> supported build platforms, and Python 2 end of life will be 3
> weeks after the planned release date of QEMU 4.2.0.  Drop Python
> 2 support from configure completely, and require Python 3.5 or
> newer.
>
> Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>
> Message-Id: <20191016224237.26180-1-ehabkost@redhat.com>
> Reviewed-by: John Snow <jsnow@redhat.com>
> Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>

Reviewed-by: Juan Quintela <quintela@redhat.com>

But once here, a comment telling why we want 3.5, not 3.4 or 3.6 will
have been helpful.

Later, Juan.



^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [PULL 2/2] configure: Require Python >= 3.5
  2019-12-20 18:59   ` Juan Quintela
@ 2019-12-20 20:12     ` Eduardo Habkost
  2019-12-23 10:24       ` Juan Quintela
  0 siblings, 1 reply; 8+ messages in thread
From: Eduardo Habkost @ 2019-12-20 20:12 UTC (permalink / raw)
  To: Juan Quintela
  Cc: Fam Zheng, Peter Maydell, Philippe Mathieu-Daudé, qemu-devel,
	Dr. David Alan Gilbert, John Snow, Cleber Rosa, Alex Bennée,
	Markus Armbruster

On Fri, Dec 20, 2019 at 07:59:28PM +0100, Juan Quintela wrote:
> Eduardo Habkost <ehabkost@redhat.com> wrote:
> > Python 3.5 is the oldest Python version available on our
> > supported build platforms, and Python 2 end of life will be 3
> > weeks after the planned release date of QEMU 4.2.0.  Drop Python
> > 2 support from configure completely, and require Python 3.5 or
> > newer.
> >
> > Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>
> > Message-Id: <20191016224237.26180-1-ehabkost@redhat.com>
> > Reviewed-by: John Snow <jsnow@redhat.com>
> > Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>
> 
> Reviewed-by: Juan Quintela <quintela@redhat.com>

Thanks!

> 
> But once here, a comment telling why we want 3.5, not 3.4 or 3.6 will
> have been helpful.

Is "Python 3.5 is the oldest Python version available on our
supported build platforms" a good explanation why we want 3.5?

-- 
Eduardo



^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [PULL 2/2] configure: Require Python >= 3.5
  2019-12-20 20:12     ` Eduardo Habkost
@ 2019-12-23 10:24       ` Juan Quintela
  0 siblings, 0 replies; 8+ messages in thread
From: Juan Quintela @ 2019-12-23 10:24 UTC (permalink / raw)
  To: Eduardo Habkost
  Cc: Fam Zheng, Peter Maydell, Philippe Mathieu-Daudé, qemu-devel,
	Dr. David Alan Gilbert, John Snow, Cleber Rosa, Alex Bennée,
	Markus Armbruster

Eduardo Habkost <ehabkost@redhat.com> wrote:
> On Fri, Dec 20, 2019 at 07:59:28PM +0100, Juan Quintela wrote:
>> Eduardo Habkost <ehabkost@redhat.com> wrote:
>> > Python 3.5 is the oldest Python version available on our
>> > supported build platforms, and Python 2 end of life will be 3
>> > weeks after the planned release date of QEMU 4.2.0.  Drop Python
>> > 2 support from configure completely, and require Python 3.5 or
>> > newer.
>> >
>> > Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>
>> > Message-Id: <20191016224237.26180-1-ehabkost@redhat.com>
>> > Reviewed-by: John Snow <jsnow@redhat.com>
>> > Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>
>> 
>> Reviewed-by: Juan Quintela <quintela@redhat.com>
>
> Thanks!
>
>> 
>> But once here, a comment telling why we want 3.5, not 3.4 or 3.6 will
>> have been helpful.
>
> Is "Python 3.5 is the oldest Python version available on our
> supported build platforms" a good explanation why we want 3.5?

You have a point here O:-)

Later, Juan.



^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [PULL 0/2] Require Python >= 3.5 to build QEMU
  2019-12-20 16:51 [PULL 0/2] Require Python >= 3.5 to build QEMU Eduardo Habkost
                   ` (2 preceding siblings ...)
  2019-12-20 16:53 ` [PULL 0/2] Require Python >= 3.5 to build QEMU Philippe Mathieu-Daudé
@ 2020-01-06 14:07 ` Peter Maydell
  3 siblings, 0 replies; 8+ messages in thread
From: Peter Maydell @ 2020-01-06 14:07 UTC (permalink / raw)
  To: Eduardo Habkost
  Cc: Fam Zheng, Juan Quintela, Philippe Mathieu-Daudé,
	QEMU Developers, Dr. David Alan Gilbert, Cleber Rosa,
	Alex Bennée, Markus Armbruster

On Fri, 20 Dec 2019 at 16:51, Eduardo Habkost <ehabkost@redhat.com> wrote:
>
> Differences from the previous Python 3.5 pull request
> that was rejected:
>
> * Now tests/vm/netbsd was fixed
> * .travis.yml is being updated to replace Python 3.4 job with 3.5
>
> The following changes since commit f59b31e6d0c69792b5d817c5aa0a6ed64fba42e0:
>
>   Merge remote-tracking branch 'remotes/stsquad/tags/pull-tesing-and-misc-191219-1' into staging (2019-12-20 14:00:49 +0000)
>
> are available in the Git repository at:
>
>   git://github.com/ehabkost/qemu.git tags/python-next-pull-request
>
> for you to fetch changes up to ddf90699631db53c981b6a5a63d31c08e0eaeec7:
>
>   configure: Require Python >= 3.5 (2019-12-20 13:45:59 -0300)
>
> ----------------------------------------------------------------
> Require Python >= 3.5 to build QEMU
>
> Python 2 EOL is 11 days away, we will stop supporting
> it in QEMU 5.0.
>
> ---------------------------------------------------------------



Applied, thanks.

Please update the changelog at https://wiki.qemu.org/ChangeLog/5.0
for any user-visible changes.

-- PMM


^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2020-01-06 14:08 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-12-20 16:51 [PULL 0/2] Require Python >= 3.5 to build QEMU Eduardo Habkost
2019-12-20 16:51 ` [PULL 1/2] travis: Replace Python 3.4 build with 3.5 Eduardo Habkost
2019-12-20 16:51 ` [PULL 2/2] configure: Require Python >= 3.5 Eduardo Habkost
2019-12-20 18:59   ` Juan Quintela
2019-12-20 20:12     ` Eduardo Habkost
2019-12-23 10:24       ` Juan Quintela
2019-12-20 16:53 ` [PULL 0/2] Require Python >= 3.5 to build QEMU Philippe Mathieu-Daudé
2020-01-06 14:07 ` Peter Maydell

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).