Bug#931029: lldb-7: Uses Python 2 instead of Python 3

Christian Biesinger cbiesinger at google.com
Wed Aug 7 21:42:04 BST 2019


On Wed, Aug 7, 2019 at 8:42 AM Gianfranco Costamagna
<locutusofborg at debian.org> wrote:
>
> Hello,
> > >
> > > lldb-7 seems to use Python 2 for its scripting support as can
> > > be seen from "print(sys.version_info)" in the script command.
> > > It should use Python 3, like gdb does.
> > >
>
>
> looks like the python3 move for llvm-toolchain-8 broke the testsuite, because some tools, e.g. opt-viewer.py
> are still requiring python2 to work.
>
>
> if test ! -f /usr/lib/llvm-$VERSION/share/opt-viewer/opt-viewer.py; then
>     echo "Install llvm-$VERSION-tools"
>     exit 42
> fi
> /usr/lib/llvm-$VERSION/share/opt-viewer/opt-viewer.py -source-dir .  matmul.opt.yaml -o ./output > /dev/null
> Traceback (most recent call last):
>   File "/usr/lib/llvm-8/share/opt-viewer/opt-viewer.py", line 16, in <module>
>     from pygments import highlight
> ImportError: No module named pygments
> autopkgtest [06:59:33]: test command1: -----------------------]
> command1             FAIL non-zero exit status 1
>
>
> not sure if we should just update all the shebangs and cross fingers...

I did not realize that :( I guess updating the shebangs is certainly
worth a try.

Christian



More information about the Pkg-llvm-team mailing list