commit: 4fe3143d1649f711e34257b235c6c32567ec903a Author: Michał Górny <mgorny <AT> gentoo <DOT> org> AuthorDate: Sun Jun 5 07:16:52 2016 +0000 Commit: Michał Górny <mgorny <AT> gentoo <DOT> org> CommitDate: Mon Jun 6 19:40:30 2016 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=4fe3143d
python-utils-r1.eclass: Add additional .opt-1 compilation for py3.5+ eclass/python-utils-r1.eclass | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/eclass/python-utils-r1.eclass b/eclass/python-utils-r1.eclass index 0f9b58f..717123c 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}" ;; *)