From 4fe3143d1649f711e34257b235c6c32567ec903a Mon Sep 17 00:00:00 2001 From: Michał Górny Date: Sun, 5 Jun 2016 09:16:52 +0200 Subject: python-utils-r1.eclass: Add additional .opt-1 compilation for py3.5+ --- eclass/python-utils-r1.eclass | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'eclass') diff --git a/eclass/python-utils-r1.eclass b/eclass/python-utils-r1.eclass index 0f9b58f6fce5..717123cc5f96 100644 --- a/eclass/python-utils-r1.eclass +++ b/eclass/python-utils-r1.eclass @@ -640,8 +640,14 @@ python_optimize() { instpath=/${instpath##/} case "${EPYTHON}" in + python2.7|python3.[34]) + "${PYTHON}" -m compileall -q -f -d "${instpath}" "${d}" + "${PYTHON}" -OO -m compileall -q -f -d "${instpath}" "${d}" + ;; python*) + # both levels of optimization are separate since 3.5 "${PYTHON}" -m compileall -q -f -d "${instpath}" "${d}" + "${PYTHON}" -O -m compileall -q -f -d "${instpath}" "${d}" "${PYTHON}" -OO -m compileall -q -f -d "${instpath}" "${d}" ;; *) -- cgit v1.2.3-65-gdbad