如何修复Mac OS上的' xeus-cling '内核运行时错误(c++ Jupyter内核标准库错误)



我用通常的conda install xeus-cling安装了xeus-cling,当我在Jupyter笔记本中启动c++内核(11,14和17版本)时,得到以下运行时错误:

/opt/anaconda3/envs/cling/include/c++/v1/stdlib.h:143:12: error: no member named 'ldiv' in the global namespace
return ::ldiv(__x, __y);
< many such errors, eventually >
/opt/anaconda3/envs/cling/include/c++/v1/cstdlib:122:9: error: no member named 'rand' in the global namespace
using ::rand;
~~^
fatal error: too many errors emitted, stopping now [-ferror-limit=]

我试着重新安装XCode命令行工具-不去。同样的设置在我的Linux机器上运行良好。

如何修复这些错误并使内核启动?

我在这里提交了一个问题,最近的XCode版本12.5.1 (12E507) -看起来要么xeus-clingconda包使用不兼容的工具链,要么XCode配置错误-无论哪种方式,c++内核都不会启动。Conda 4.10.1与Python 3.9.6(如果这很重要)。提前感谢!

查看这里(GitHub)

SylvainCorlay建议试试:

conda remove libcxx --force

它为我工作(MacOS Monterey, Mambaforge)

最新更新