Subject: Re: bug#32088: Python >=3.5 test suite failures

From: "Andreas K. Huettel" <[email-masked]>
Date: Tue, 21 Jan 2020 01:42:02 +0100

>     2) The fix/patch of bug #38043 (Incorrect Python byte-compiling for
>     Python 3 and PyPy3), which we also carry, interferes with
>     t/py-compile-basedir.sh; the number of generated files (line 47
>     there) is then (only for recent Python 3) 6, not 4.
> 
> People will surely be running make check on older machines.
> 
> Maybe the simplest way is just to accept either 4 or 6 in the stated
>  test $(echo "$files" | wc -l) -eq 4
> as long as those are the only results ... so far ...

Yep, precisely. This is what I've used:
https://gitweb.gentoo.org/repo/gentoo.git/tree/sys-devel/automake/files/
automake-1.16.1-py3-compile-test.patch

diff -ruN automake-1.16.1.orig/t/py-compile-basedir.sh automake-1.16.1/t/
py-compile-basedir.sh
--- automake-1.16.1.orig/t/py-compile-basedir.sh        2020-01-20 
05:07:12.915260159 +0100
+++ automake-1.16.1/t/py-compile-basedir.sh     2020-01-20 
05:07:45.827074984 +0100
@@ -42,7 +42,7 @@
   py_installed "$d2/$f.pyc"
   py_installed "$d2/sub/$f.pyc"
   files=$(find "$d2" | grep '\.py[co]$')
-  test $(echo "$files" | wc -l) -eq 4
+  test $(echo "$files" | wc -l) -eq 4 -o $(echo "$files" | wc -l) -eq 6
   case $d2 in
     .|..) rm -f $files;;
        *) rm -rf "$d2";;

-- 
Andreas K. Hüttel
[email-masked]
Gentoo Linux developer 
(council, toolchain, base-system, perl, libreoffice)