python: better Python compilation portability.
commit13fb472cd02d86bf33c092609ac00506465d2df1
authorZack Weinberg <zackw@panix.com>
Wed, 28 Sep 2022 17:12:24 +0000 (28 10:12 -0700)
committerKarl Berry <karl@freefriends.org>
Wed, 28 Sep 2022 17:12:24 +0000 (28 10:12 -0700)
treeac70171d70022002b559486bb6354e0ef73e809f
parent8a4ecd4f2f1ffa2ef12b6946cf3aea989ff70cfd
python: better Python compilation portability.

This change is per automake thread:
https://lists.gnu.org/archive/html/automake/2022-09/msg00002.html

* lib/py-compile: Test directly for availability of
importlib.util.cache_from_source.  Untangle logic for when
to generate -O and -OO bytecode.  Reformat embedded Python fragments.
lib/py-compile