diff mbox series

build: prereq: drop support for Python 3.5

Message ID 20210216072108.26107-1-a.heider@gmail.com
State Accepted
Delegated to: Petr Štetiar
Headers show
Series build: prereq: drop support for Python 3.5 | expand

Commit Message

Andre Heider Feb. 16, 2021, 7:21 a.m. UTC
The final Python 3.5 release was 3.5.10 in September 2020 [0].
This release series is now End-of-Life (EOL).

The only LTS distribution that still only ships Python 3.5 is Ubuntu 16.04,
which will be EOL in April 2021 [1].

The meson build system bumped their python requirement to 3.6 for the 0.57.0
release. This patch ensures that OpenWrt can update meson while still
relying on the host python.

[0] https://www.python.org/dev/peps/pep-0478/#id4
[1] https://ubuntu.com/about/release-cycle
[2] https://mesonbuild.com/Release-notes-for-0-57-0.html#minimum-required-python-version-updated-to-36

Signed-off-by: Andre Heider <a.heider@gmail.com>
---
 include/prereq-build.mk | 10 ++++------
 1 file changed, 4 insertions(+), 6 deletions(-)

Comments

Petr Štetiar Feb. 16, 2021, 4:17 p.m. UTC | #1
Andre Heider <a.heider@gmail.com> [2021-02-16 08:21:08]:

Hi,

> The meson build system bumped their python requirement to 3.6 for the 0.57.0
> release. This patch ensures that OpenWrt can update meson while still
> relying on the host python.

Current buildbot images are based on Debian 9, which uses Python 3.5 so merging this
would result in broken buildbots.

Cheers,

Petr
Andre Heider Feb. 16, 2021, 4:38 p.m. UTC | #2
Hi,

On 16/02/2021 17:17, Petr Štetiar wrote:
> Andre Heider <a.heider@gmail.com> [2021-02-16 08:21:08]:
> 
> Hi,
> 
>> The meson build system bumped their python requirement to 3.6 for the 0.57.0
>> release. This patch ensures that OpenWrt can update meson while still
>> relying on the host python.
> 
> Current buildbot images are based on Debian 9, which uses Python 3.5 so merging this
> would result in broken buildbots.

that's unfortunate.

Are there plans to update from oldstable to stable?

Thanks,
Andre
Sven Roederer April 17, 2021, 2:45 p.m. UTC | #3
Hi,


Am Dienstag, 16. Februar 2021, 17:17:17 CEST schrieb Petr Štetiar:
> 
> > The meson build system bumped their python requirement to 3.6 for the
> > 0.57.0 release. This patch ensures that OpenWrt can update meson while
> > still relying on the host python.
> 
> Current buildbot images are based on Debian 9, which uses Python 3.5 so
> merging this would result in broken buildbots.
> 

On my Ubuntu 16.04 based build-system I also have build-failures for meson 
using Python3.5. They are triggered by the "mlog module" . Cherry-picking the 
recent meson updates into the packages feed fixing these errors, not sure if 
this is caused by the meson upgrade or the python-upgrade.

So it's indeed a tricky situation. But having the EOLed Python3.5 as minimum 
requirement for an upcoming release seems non optimal.

Sven
Sven Roederer April 17, 2021, 9:45 p.m. UTC | #4
Am Samstag, 17. April 2021, 16:45:01 CEST schrieb Sven Roederer:
> On my Ubuntu 16.04 based build-system I also have build-failures for meson
> using Python3.5.

Correction: it's a 18.04 LTS ...

Sven
Rosen Penev April 17, 2021, 9:57 p.m. UTC | #5
On Sat, Apr 17, 2021 at 2:49 PM Sven Roederer <devel-sven@geroedel.de> wrote:
>
> Am Samstag, 17. April 2021, 16:45:01 CEST schrieb Sven Roederer:
> > On my Ubuntu 16.04 based build-system I also have build-failures for meson
> > using Python3.5.
>
> Correction: it's a 18.04 LTS ...
GCC6 is now minimum, breaking CentOS 7. That and the make version update.

I tried installing homebrew on CentOS7 but the build system prefers to
use the OS tools...

Speaking of homebrew, you could try that on Ubuntu.
>
> Sven
>
>
>
> _______________________________________________
> openwrt-devel mailing list
> openwrt-devel@lists.openwrt.org
> https://lists.openwrt.org/mailman/listinfo/openwrt-devel
Etienne Champetier April 18, 2021, 6:45 p.m. UTC | #6
Le mar. 16 févr. 2021 à 11:19, Petr Štetiar <ynezz@true.cz> a écrit :
>
> Andre Heider <a.heider@gmail.com> [2021-02-16 08:21:08]:
>
> Hi,
>
> > The meson build system bumped their python requirement to 3.6 for the 0.57.0
> > release. This patch ensures that OpenWrt can update meson while still
> > relying on the host python.
>
> Current buildbot images are based on Debian 9, which uses Python 3.5 so merging this
> would result in broken buildbots.

Debian 9 is EOL, so we should definitely update the buildbot images

>
> Cheers,
>
> Petr
>
> _______________________________________________
> openwrt-devel mailing list
> openwrt-devel@lists.openwrt.org
> https://lists.openwrt.org/mailman/listinfo/openwrt-devel
Etienne Champetier April 18, 2021, 6:51 p.m. UTC | #7
Le sam. 17 avr. 2021 à 17:47, Sven Roederer <devel-sven@geroedel.de> a écrit :
>
> Am Samstag, 17. April 2021, 16:45:01 CEST schrieb Sven Roederer:
> > On my Ubuntu 16.04 based build-system I also have build-failures for meson
> > using Python3.5.
>
> Correction: it's a 18.04 LTS ...

Should we just recommend to people that want to use "old stable" OS to
use the buildbot container images ?

>
> Sven
Alberto Bursi April 18, 2021, 7:33 p.m. UTC | #8
On 18/04/21 20:51, Etienne Champetier wrote:
> Le sam. 17 avr. 2021 à 17:47, Sven Roederer <devel-sven@geroedel.de> a écrit :
>>
>> Am Samstag, 17. April 2021, 16:45:01 CEST schrieb Sven Roederer:
>>> On my Ubuntu 16.04 based build-system I also have build-failures for meson
>>> using Python3.5.
>>
>> Correction: it's a 18.04 LTS ...
> 
> Should we just recommend to people that want to use "old stable" OS to
> use the buildbot container images ?
> 

Maybe. Although what's the point of using "old stable" if you are going 
to use it as a base for a docker setup anyway. If you migrate to a 
docker setup you can use pretty much anything as the base, even OpenWrt 
can run docker containers now.

-Alberto
Hauke Mehrtens April 18, 2021, 8:04 p.m. UTC | #9
On 4/18/21 9:33 PM, Alberto Bursi wrote:
> 
> 
> On 18/04/21 20:51, Etienne Champetier wrote:
>> Le sam. 17 avr. 2021 à 17:47, Sven Roederer <devel-sven@geroedel.de> a 
>> écrit :
>>>
>>> Am Samstag, 17. April 2021, 16:45:01 CEST schrieb Sven Roederer:
>>>> On my Ubuntu 16.04 based build-system I also have build-failures for 
>>>> meson
>>>> using Python3.5.
>>>
>>> Correction: it's a 18.04 LTS ...
>>
>> Should we just recommend to people that want to use "old stable" OS to
>> use the buildbot container images ?
>>
> 
> Maybe. Although what's the point of using "old stable" if you are going 
> to use it as a base for a docker setup anyway. If you migrate to a 
> docker setup you can use pretty much anything as the base, even OpenWrt 
> can run docker containers now.
> 
> -Alberto

Hi,

Many libraries, like glibc, are backwards compatible when we link it 
against an older version, it also works when it runs with a more recent 
version of the library. The OpenWrt SDK is build against an old Debian 
so it can be used with such an old systems, but it also works with a 
recent Arch Linux for example.

Hauke
Andre Heider April 19, 2021, 6:37 a.m. UTC | #10
On 18/04/2021 20:45, Etienne Champetier wrote:
> Le mar. 16 févr. 2021 à 11:19, Petr Štetiar <ynezz@true.cz> a écrit :
>>
>> Andre Heider <a.heider@gmail.com> [2021-02-16 08:21:08]:
>>
>> Hi,
>>
>>> The meson build system bumped their python requirement to 3.6 for the 0.57.0
>>> release. This patch ensures that OpenWrt can update meson while still
>>> relying on the host python.
>>
>> Current buildbot images are based on Debian 9, which uses Python 3.5 so merging this
>> would result in broken buildbots.
> 
> Debian 9 is EOL, so we should definitely update the buildbot images

That was already done >4 weeks ago:
https://lists.infradead.org/pipermail/openwrt-devel/2021-March/034292.html
https://lists.infradead.org/pipermail/openwrt-devel/2021-March/034310.html

And the quoted patch has been merged too:
https://git.openwrt.org/?p=openwrt/openwrt.git;a=commit;h=7379f8bd3e7ee0722faa6ec8b2969081fbdc1e07
Andre Heider April 19, 2021, 6:40 a.m. UTC | #11
On 17/04/2021 23:45, Sven Roederer wrote:
> Am Samstag, 17. April 2021, 16:45:01 CEST schrieb Sven Roederer:
>> On my Ubuntu 16.04 based build-system I also have build-failures for meson
>> using Python3.5.
> 
> Correction: it's a 18.04 LTS ...

But 18.04 ships python3.6?
https://packages.ubuntu.com/bionic/python3
diff mbox series

Patch

diff --git a/include/prereq-build.mk b/include/prereq-build.mk
index f88e853b52..88064abf98 100644
--- a/include/prereq-build.mk
+++ b/include/prereq-build.mk
@@ -141,21 +141,19 @@  $(eval $(call SetupHostCommand,perl,Please install Perl 5.x, \
 
 $(eval $(call CleanupPython2))
 
-$(eval $(call SetupHostCommand,python,Please install Python >= 3.5, \
+$(eval $(call SetupHostCommand,python,Please install Python >= 3.6, \
 	python3.9 -V 2>&1 | grep 'Python 3', \
 	python3.8 -V 2>&1 | grep 'Python 3', \
 	python3.7 -V 2>&1 | grep 'Python 3', \
 	python3.6 -V 2>&1 | grep 'Python 3', \
-	python3.5 -V 2>&1 | grep 'Python 3', \
-	python3 -V 2>&1 | grep -E 'Python 3\.[5-9]\.?'))
+	python3 -V 2>&1 | grep -E 'Python 3\.[6-9]\.?'))
 
-$(eval $(call SetupHostCommand,python3,Please install Python >= 3.5, \
+$(eval $(call SetupHostCommand,python3,Please install Python >= 3.6, \
 	python3.9 -V 2>&1 | grep 'Python 3', \
 	python3.8 -V 2>&1 | grep 'Python 3', \
 	python3.7 -V 2>&1 | grep 'Python 3', \
 	python3.6 -V 2>&1 | grep 'Python 3', \
-	python3.5 -V 2>&1 | grep 'Python 3', \
-	python3 -V 2>&1 | grep -E 'Python 3\.[5-9]\.?'))
+	python3 -V 2>&1 | grep -E 'Python 3\.[6-9]\.?'))
 
 $(eval $(call SetupHostCommand,git,Please install Git (git-core) >= 1.7.12.2, \
 	git --exec-path | xargs -I % -- grep -q -- --recursive %/git-submodule))