diff --git a/common/hooks/pre-pkg/03-rewrite-python-shebang.sh b/common/hooks/pre-pkg/03-rewrite-python-shebang.sh index e5fb2157441..6f057cc984b 100644 --- a/common/hooks/pre-pkg/03-rewrite-python-shebang.sh +++ b/common/hooks/pre-pkg/03-rewrite-python-shebang.sh @@ -6,6 +6,10 @@ hook() { : ${pyver:=2} + if [ -n "$py3_ver" ]; then + pyver=3 + fi + if [ -d ${PKGDESTDIR}/usr/lib/python* ]; then pycompile_version="$(find ${PKGDESTDIR}/usr/lib/python* -type d | grep -o '[[:digit:]]\.[[:digit:]]$')" fi