在OS X上使用python3安装pyside [英] Installing pyside with python3 on os x

查看:195
本文介绍了在OS X上使用python3安装pyside的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我尝试在osx美洲狮上将pyside和python3一起安装. 我一直都在尝试

I have tried to install pyside together with python3 on osx mountain lion. I have been trying both

brew install pyside

但是那只能在python2中使用.

But then it only works in python2.

我也尝试过使用来自pyside github rep的buildscripts.进行所需的更改

I have also tried using the buildscripts from the pyside github rep. Making the changes needed

./build_and_install

但是失败了,

Linking CXX shared library libpyside.cpython-33m.dylib
[  4%] Built target pyside
[  4%] Running generator for QtCore...
/bin/sh: /Users/einar/devel/pkg/pyside-sandbox-python3/bin/SHIBOKEN_GENERATOR-NOTFOUND: No such file or directory
make[2]: *** [PySide/QtCore/PySide/QtCore/qabstracteventdispatcher_wrapper.cpp] Error 127
make[1]: *** [PySide/QtCore/CMakeFiles/QtCore.dir/all] Error 2
make: *** [all] Error 2

我现在不知道该怎么办.我发现此页面 pyside论坛提示我仅需符号链接一些内容即可使其正常工作brew install pyside之后在python3中运行,但/usr/local/Cellar/pyside/1.1.2/lib仅具有名为2.7的文件.

I don't know what to do now. I found this page pyside forum suggesting that I only have to symlink some stuff to get it working in python3 after doing brew install pyside but /usr/local/Cellar/pyside/1.1.2/lib only has files named 2.7 something.

有人能在osx上使pyside与python3一起工作还是知道一些如何做的指南?我的Google-fu使我失败了.

Has anyone managed to get pyside working with python3 on osx or know of some guide on how to do it? My google-fu is failing me.

推荐答案

此问题已在Homebrew中修复(请参阅Wiki ).使用以下方式安装Pyside

This has been fixed in Homebrew (see wiki). Installing Pyside with

brew install pyside --with-python3

将同时为Python 2和Python 3安装它.为使其正常工作,如果已经为Python 2安装了shibokenpyside,则可能必须先卸载它们.

will install it for both Python 2 and Python 3. For this to work, you may have to uninstall shiboken and pyside first if they were already installed for Python 2.

这篇关于在OS X上使用python3安装pyside的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆