Daniel P. Berrangé <berra...@redhat.com> writes: > On Tue, Feb 27, 2018 at 09:53:22AM -0600, Eric Blake wrote: >> On 02/11/2018 03:35 AM, Markus Armbruster wrote: >> > The next commit will introduce a common driver program for all >> > generators. The generators need to be modules for that. qapi2texi.py >> > already is. Make the other generators follow suit. >> > >> > The changes are actually trivial. Obvious in the diffs once you view >> > them with whitespace changes ignored. >> > >> > Signed-off-by: Markus Armbruster <arm...@redhat.com> >> > Reviewed-by: Eric Blake <ebl...@redhat.com> >> > Reviewed-by: Marc-André Lureau <marcandre.lur...@redhat.com> >> > --- >> > scripts/qapi-commands.py | 43 ++++++++++++++++++-------------- >> > scripts/qapi-event.py | 43 ++++++++++++++++++-------------- >> > scripts/qapi-introspect.py | 54 ++++++++++++++++++++++------------------ >> > scripts/qapi-types.py | 56 ++++++++++++++++++++++------------------- >> > scripts/qapi-visit.py | 62 >> > +++++++++++++++++++++++++--------------------- >> > 5 files changed, 143 insertions(+), 115 deletions(-) >> >> Urgh. One annoyance of this patch is that if you switch to another branch >> without the patch, leftover .pyc files in the source tree can cause weird >> errors until you 'rm -f scripts/qapi/*.pyc': > > Pehaps make our build system set PYTHONDONTWRITEBYTECODE=1 env variable > > https://docs.python.org/3/using/cmdline.html#envvar-PYTHONDONTWRITEBYTECODE
We already have configure put PYTHON=python -B into config-host.mak. I still manage to litter my tree with .pyc files...