PyQt编译源代码时出错

发布于 2024-12-11 07:36:10 字数 1047 浏览 0 评论 0原文

我想为 Qt 4.7.4 安装 PyQt,并且下载了软件包 SIP 和 PyQt 来自 Riverbankcomputing.co.uk。

我成功配置并安装了SIP,并成功配置了PyQt。但是当我在终端中运行 make 时,我收到此错误:

/home/user/Desktop/PyQt-x11-gpl-4.8.5/QtCore/sipQtCoreQThread.cpp: In function ‘PyObject* meth_QThread_currentThreadId(PyObject*, PyObject*)’:

/home/user/Desktop/PyQt-x11-gpl-4.8.5/QtCore/sipQtCoreQThread.cpp:325:50: error: invalid conversion from ‘void*’ to ‘long unsigned int’

/home/user/Desktop/PyQt-x11-gpl-4.8.5/QtCore/sipQtCoreQThread.cpp:325:50: error: initializing argument 1 of ‘PyObject* PyLong_FromUnsignedLong(long unsigned int)’

make[1]: *** [sipQtCoreQThread.o] Error 1

make[1]: Leaving directory `/home/user/Desktop/PyQt-x11-gpl-4.8.5/QtCore'

make: *** [all] Error 2 

完整的日志在这里:http://www.text-upload.com/read.php?id=176672&c=5376703

你能帮我解决这个问题吗错误,请问?谢谢你!

I want to install PyQt for Qt 4.7.4 and i downloaded the packages SIP and PyQt from riverbankcomputing.co.uk.

I configured and installed SIP successfully and configured PyQt successfully. But when i ran make in the terminal i got this error:

/home/user/Desktop/PyQt-x11-gpl-4.8.5/QtCore/sipQtCoreQThread.cpp: In function ‘PyObject* meth_QThread_currentThreadId(PyObject*, PyObject*)’:

/home/user/Desktop/PyQt-x11-gpl-4.8.5/QtCore/sipQtCoreQThread.cpp:325:50: error: invalid conversion from ‘void*’ to ‘long unsigned int’

/home/user/Desktop/PyQt-x11-gpl-4.8.5/QtCore/sipQtCoreQThread.cpp:325:50: error: initializing argument 1 of ‘PyObject* PyLong_FromUnsignedLong(long unsigned int)’

make[1]: *** [sipQtCoreQThread.o] Error 1

make[1]: Leaving directory `/home/user/Desktop/PyQt-x11-gpl-4.8.5/QtCore'

make: *** [all] Error 2 

The full log is here: http://www.text-upload.com/read.php?id=176672&c=5376703

Can you help me fix this error, please? Thank you!

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

错々过的事 2024-12-18 07:36:10

根据构建日志,PyQt 的配置脚本已找到并正在使用 Qt 的模拟器/嵌入式变体,而不是桌面变体。

尝试将 Desktop 变体的 qmake 路径传递给配置脚本:

python ./configure.py -q /home/user/.QtSDK/Desktop/Qt/4.7.4/gcc/bin/qmake

According to the build log, PyQt's configure script has found and is using the Simulator/embedded variant of Qt, and not the Desktop variant.

Try passing the path to qmake of the Desktop variant to the configure script:

python ./configure.py -q /home/user/.QtSDK/Desktop/Qt/4.7.4/gcc/bin/qmake
眼眸里的快感 2024-12-18 07:36:10

有两种选择

python ./configure.py -q /home/user/.QtSDK/Desktop/Qt/4.7.4/gcc/bin/qmake

python ./configure.py -q /home/user/.QtSDK/Simulator/Qt/gcc/bin/qmake

第二种将退出并显示一些错误代码。

我现在正在尝试第一根弦。

There are two choices

python ./configure.py -q /home/user/.QtSDK/Desktop/Qt/4.7.4/gcc/bin/qmake

or

python ./configure.py -q /home/user/.QtSDK/Simulator/Qt/gcc/bin/qmake

second will exit with some error code.

I'm trying first string right now.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文