首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >如何使用MacPorts运行Webots示例?

如何使用MacPorts运行Webots示例?
EN

Stack Overflow用户
提问于 2019-08-21 16:30:40
回答 1查看 417关注 0票数 2

当我尝试运行示例/robotbenchmark/squar_path示例时,我首先得到消息:

代码语言:javascript
复制
DEPRECATION: Python 2.7 will reach the end of its life on January 1st, 2020. Please upgrade your Python as Python 2.7 won't be maintained after that date. A future version of Webots will drop support for Python 2.7.
[square_path_supervisor] DEPRECATION: Python 2.7 will reach the end of its life on January 1st, 2020. Please upgrade your Python as Python 2.7 won't be maintained after that date. A future version of Webots will drop support for Python 2.7.

而Python 3.7版本

代码语言:javascript
复制
python --version
Python 3.7.4

是通过我的Macports环境获得的。

代码语言:javascript
复制
port version
Version: 2.5.4

所以我认为Webots不使用我的macports配置文件中的设置--我怎么能做到这一点呢?我尝试将python路径设置为

代码语言:javascript
复制
/opt/local/bin/python

在一般情况下,但后来我收到了一份投诉:

代码语言:javascript
复制
ImportError: dlopen(/Applications/Webots.app/lib/python37/_controller.so, 2): Library not loaded: /Library/Frameworks/Python.framework/Versions/3.7/Python

我还没有看到指定库路径的选项..。

EN

回答 1

Stack Overflow用户

回答已采纳

发布于 2019-08-21 16:32:02

库路径不被识别,/Library/Frameworks/Python.framework/Versions/3.7/Python不存在,但/opt/local//Library/Frameworks/Python.framework/Versions/3.7/Python路径不存在。

因此,作为/Library/Framework中的一个解决方案,我做了一个

代码语言:javascript
复制
sudo ln -s /opt/local/Library/Frameworks/Python.framework . 

现在机器人开始..。

票数 2
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/57595884

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档