尝试仅导入时
from PySide import QtGui
我遇到了以下错误:
ImportError: libpyside-python2.7.so.1.2: 无法打开共享对象文件: 没有那个文件或目录
ls /usr/local/lib/python2.7/dist-packages/PySide/libpyside-python2.7.so.1.2
/usr/local/lib/python2.7/dist-packages/PySide/libpyside-python2.7.so.1.2
所以so文件已经在路径中,为什么PySide还是找不到它呢? 我尝试使用pip安装PySide,但是遇到了某种后处理脚本错误,并通过synaptic安装了包。
附加信息:
ldd /usr/local/lib/python2.7/dist-packages/PySide/libpyside-python2.7.so.1.2
linux-vdso.so.1 => (0x00007ffffd34e000)
libpython2.7.so.1.0 => /usr/lib/x86_64-linux-gnu/libpython2.7.so.1.0 (0x00007fdd5a6ae000)
libshiboken-python2.7.so.1.2 => not found
libQtCore.so.4 => /usr/lib/x86_64-linux-gnu/libQtCore.so.4 (0x00007fdd5a1d6000)
libstdc++.so.6 => /usr/lib/x86_64-linux-gnu/libstdc++.so.6 (0x00007fdd59ed3000)
libgcc_s.so.1 => /lib/x86_64-linux-gnu/libgcc_s.so.1 (0x00007fdd59cbd000)
libc.so.6 => /lib/x86_64-linux-gnu/libc.so.6 (0x00007fdd598f4000)
libz.so.1 => /lib/x86_64-linux-gnu/libz.so.1 (0x00007fdd596dd000)
libpthread.so.0 => /lib/x86_64-linux-gnu/libpthread.so.0 (0x00007fdd594c0000)
libdl.so.2 => /lib/x86_64-linux-gnu/libdl.so.2 (0x00007fdd592bb000)
libutil.so.1 => /lib/x86_64-linux-gnu/libutil.so.1 (0x00007fdd590b8000)
libm.so.6 => /lib/x86_64-linux-gnu/libm.so.6 (0x00007fdd58db3000)
libglib-2.0.so.0 => /lib/x86_64-linux-gnu/libglib-2.0.so.0 (0x00007fdd58ab6000)
librt.so.1 => /lib/x86_64-linux-gnu/librt.so.1 (0x00007fdd588ae000)
/lib64/ld-linux-x86-64.so.2 (0x00007fdd5ae32000)
libpcre.so.3 => /lib/x86_64-linux-gnu/libpcre.so.3 (0x00007fdd5866e000)
ldd /usr/local/lib/python2.7/dist-packages/PySide/libpyside-python2.7.so.1.2
的输出是什么? - mata