xeus-cling
xeus-cling copied to clipboard
Issue to make Xeus-Cling work with macOS 11.3 (11.2 was fine)
Hi,
I was working on a C++ formation using Xeus-cling, and everything was working fine... until I updated my OS to the latest versions (11.3, it was 11.2.something before that).
With this version, no cell worked properly; the terminal indicated that C symbols were not found:
In file included from input_line_1:1:
In file included from /Users/sebastien/opt/miniconda3/envs/formation_cpp/include/c++/v1/new:90:
In file included from /Users/sebastien/opt/miniconda3/envs/formation_cpp/include/c++/v1/exception:81:
In file included from /Users/sebastien/opt/miniconda3/envs/formation_cpp/include/c++/v1/cstdlib:85:
/Users/sebastien/opt/miniconda3/envs/formation_cpp/include/c++/v1/stdlib.h:142:34: error: unknown type name 'ldiv_t'
inline _LIBCPP_INLINE_VISIBILITY ldiv_t div(long __x, long __y) _NOEXCEPT {
^
/Users/sebastien/opt/miniconda3/envs/formation_cpp/include/c++/v1/stdlib.h:143:12: error: no member named 'ldiv' in the global namespace
return ::ldiv(__x, __y);
I tried to:
- Reinstall the conda environment
- Reinstall completely XCode
and it didn't help.
I then tried to install from the sources, following the instructions on the README here, and I didn't get far either:
[ 5%] Building CXX object CMakeFiles/xeus-cling.dir/src/xinput.cpp.o
In file included from /Users/sebastien/Codes/XeusCling/src/xinput.cpp:10:
In file included from /Users/sebastien/opt/miniconda3/envs/formation_cpp_manual/include/c++/v1/iostream:37:
In file included from /Users/sebastien/opt/miniconda3/envs/formation_cpp_manual/include/c++/v1/ios:214:
In file included from /Users/sebastien/opt/miniconda3/envs/formation_cpp_manual/include/c++/v1/iosfwd:95:
/Users/sebastien/opt/miniconda3/envs/formation_cpp_manual/include/c++/v1/wchar.h:137:77: error: use of undeclared identifier
'wcschr'
wchar_t* __libcpp_wcschr(const wchar_t* __s, wchar_t __c) {return (wchar_t*)wcschr(__s, __c);}
I gather it is not much (a macro with the wrong value or a path that is now incorrect) but I do not know enough the plumbery of either conda or Xeus-cling to figure it out.
Thanks!
Related directly to cling: if cling -v
is run in the Conda environment I get the error messages.
I manage to compile Xeus-cling code manually using gcc/g++, but it doesn't solve the issue at hand.
Same problem here, fresh install of macOS 11.3 and Xcode.
Thanks for reporting. It is probably an issue with the sysroot detection in clang. I will investigate this week.
Thanks!
I'm having the same problem. After fresh install of anaconda, xeus didn't install just with: conda install -c conda-forge xeus-cling but creating a new Environment called "xeus" it worked: conda create -n xeus xeus-cling -c conda-forge conda activate xeus But now I'm stuck with the error in include/c++/v1/... files
After fresh install of anaconda, xeus didn't install just with:
Quick note: I don't recommend using the anaconda distribution, which is not fully compatible with conda-forge.
We will be investigating this sysroot issue.
Best,
Hello @SylvainCorlay , All,
I have the same problem here. I am on macOS Big Sur 11.2.3 with Xcode 12.4. I installed the latest Miniconda3 on my Mac, and created a new conda environment called cling. Followed the steps below:
conda create -n cling
conda activate cling
conda install xeus-cling -c conda-forge
conda install jupyterlab -c conda-forge
Everything was OK during the installation. Then, when I create a new notebook using C++, I have:
(cling) andrewssobral@macbookpro tmp % jupyter lab
[I 2021-07-11 15:21:25.046 ServerApp] jupyterlab | extension was successfully linked.
[I 2021-07-11 15:21:25.341 ServerApp] nbclassic | extension was successfully linked.
[I 2021-07-11 15:21:25.390 ServerApp] nbclassic | extension was successfully loaded.
[I 2021-07-11 15:21:25.391 LabApp] JupyterLab extension loaded from /Users/andrewssobral/opt/miniconda3/envs/cling/lib/python3.9/site-packages/jupyterlab
[I 2021-07-11 15:21:25.391 LabApp] JupyterLab application directory is /Users/andrewssobral/opt/miniconda3/envs/cling/share/jupyter/lab
[I 2021-07-11 15:21:25.395 ServerApp] jupyterlab | extension was successfully loaded.
[I 2021-07-11 15:21:25.396 ServerApp] Serving notebooks from local directory: /Users/andrewssobral/Desktop/tmp
[I 2021-07-11 15:21:25.396 ServerApp] Jupyter Server 1.9.0 is running at:
[I 2021-07-11 15:21:25.396 ServerApp] http://localhost:8888/lab?token=30b150fc20c6e552c8fd18492f8f84b09bade59d0df7ebd8
[I 2021-07-11 15:21:25.396 ServerApp] or http://127.0.0.1:8888/lab?token=30b150fc20c6e552c8fd18492f8f84b09bade59d0df7ebd8
[I 2021-07-11 15:21:25.396 ServerApp] Use Control-C to stop this server and shut down all kernels (twice to skip confirmation).
[C 2021-07-11 15:21:25.414 ServerApp]
To access the server, open this file in a browser:
file:///Users/andrewssobral/Library/Jupyter/runtime/jpserver-95422-open.html
Or copy and paste one of these URLs:
http://localhost:8888/lab?token=30b150fc20c6e552c8fd18492f8f84b09bade59d0df7ebd8
or http://127.0.0.1:8888/lab?token=30b150fc20c6e552c8fd18492f8f84b09bade59d0df7ebd8
[W 2021-07-11 15:21:29.152 LabApp] Could not determine jupyterlab build status without nodejs
[I 2021-07-11 15:21:43.818 ServerApp] Kernel started: 9c409177-ac1b-4516-8861-7deff345328c
In file included from input_line_1:1:
In file included from /Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/new:90:
In file included from /Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/exception:81:
In file included from /Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/cstdlib:85:
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/stdlib.h:142:34: error: unknown type name 'ldiv_t'
inline _LIBCPP_INLINE_VISIBILITY ldiv_t div(long __x, long __y) _NOEXCEPT {
^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/stdlib.h:143:12: error: no member named 'ldiv' in the global namespace
return ::ldiv(__x, __y);
~~^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/stdlib.h:146:34: error: unknown type name 'lldiv_t'
inline _LIBCPP_INLINE_VISIBILITY lldiv_t div(long long __x,
^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/stdlib.h:148:12: error: no member named 'lldiv' in the global namespace
return ::lldiv(__x, __y);
~~^
In file included from input_line_1:1:
In file included from /Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/new:90:
In file included from /Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/exception:81:
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/cstdlib:100:9: error: no member named 'div_t' in the global namespace
using ::div_t;
~~^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/cstdlib:101:9: error: no member named 'ldiv_t' in the global namespace
using ::ldiv_t;
~~^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/cstdlib:103:9: error: no member named 'lldiv_t' in the global namespace
using ::lldiv_t;
~~^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/cstdlib:105:9: error: no member named 'atof' in the global namespace
using ::atof;
~~^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/cstdlib:106:9: error: no member named 'atoi' in the global namespace
using ::atoi;
~~^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/cstdlib:107:9: error: no member named 'atol' in the global namespace
using ::atol;
~~^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/cstdlib:109:9: error: no member named 'atoll' in the global namespace
using ::atoll;
~~^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/cstdlib:111:9: error: no member named 'strtod' in the global namespace
using ::strtod;
~~^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/cstdlib:112:9: error: no member named 'strtof' in the global namespace
using ::strtof;
~~^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/cstdlib:113:9: error: no member named 'strtold' in the global namespace
using ::strtold;
~~^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/cstdlib:114:9: error: no member named 'strtol' in the global namespace
using ::strtol;
~~^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/cstdlib:116:9: error: no member named 'strtoll' in the global namespace
using ::strtoll;
~~^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/cstdlib:118:9: error: no member named 'strtoul' in the global namespace
using ::strtoul;
~~^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/cstdlib:120:9: error: no member named 'strtoull' in the global namespace
using ::strtoull;
~~^
/Users/andrewssobral/opt/miniconda3/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=]
[I 2021-07-11 15:21:46.814 ServerApp] AsyncIOLoopKernelRestarter: restarting kernel (1/5), new random ports
In file included from input_line_1:1:
In file included from /Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/new:90:
In file included from /Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/exception:81:
In file included from /Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/cstdlib:85:
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/stdlib.h:142:34: error: unknown type name 'ldiv_t'
inline _LIBCPP_INLINE_VISIBILITY ldiv_t div(long __x, long __y) _NOEXCEPT {
^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/stdlib.h:143:12: error: no member named 'ldiv' in the global namespace
return ::ldiv(__x, __y);
~~^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/stdlib.h:146:34: error: unknown type name 'lldiv_t'
inline _LIBCPP_INLINE_VISIBILITY lldiv_t div(long long __x,
^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/stdlib.h:148:12: error: no member named 'lldiv' in the global namespace
return ::lldiv(__x, __y);
~~^
In file included from input_line_1:1:
In file included from /Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/new:90:
In file included from /Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/exception:81:
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/cstdlib:100:9: error: no member named 'div_t' in the global namespace
using ::div_t;
~~^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/cstdlib:101:9: error: no member named 'ldiv_t' in the global namespace
using ::ldiv_t;
~~^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/cstdlib:103:9: error: no member named 'lldiv_t' in the global namespace
using ::lldiv_t;
~~^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/cstdlib:105:9: error: no member named 'atof' in the global namespace
using ::atof;
~~^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/cstdlib:106:9: error: no member named 'atoi' in the global namespace
using ::atoi;
~~^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/cstdlib:107:9: error: no member named 'atol' in the global namespace
using ::atol;
~~^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/cstdlib:109:9: error: no member named 'atoll' in the global namespace
using ::atoll;
~~^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/cstdlib:111:9: error: no member named 'strtod' in the global namespace
using ::strtod;
~~^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/cstdlib:112:9: error: no member named 'strtof' in the global namespace
using ::strtof;
~~^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/cstdlib:113:9: error: no member named 'strtold' in the global namespace
using ::strtold;
~~^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/cstdlib:114:9: error: no member named 'strtol' in the global namespace
using ::strtol;
~~^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/cstdlib:116:9: error: no member named 'strtoll' in the global namespace
using ::strtoll;
~~^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/cstdlib:118:9: error: no member named 'strtoul' in the global namespace
using ::strtoul;
~~^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/cstdlib:120:9: error: no member named 'strtoull' in the global namespace
using ::strtoull;
~~^
/Users/andrewssobral/opt/miniconda3/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=]
[I 2021-07-11 15:21:49.823 ServerApp] AsyncIOLoopKernelRestarter: restarting kernel (2/5), new random ports
In file included from input_line_1:1:
In file included from /Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/new:90:
In file included from /Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/exception:81:
In file included from /Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/cstdlib:85:
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/stdlib.h:142:34: error: unknown type name 'ldiv_t'
inline _LIBCPP_INLINE_VISIBILITY ldiv_t div(long __x, long __y) _NOEXCEPT {
^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/stdlib.h:143:12: error: no member named 'ldiv' in the global namespace
return ::ldiv(__x, __y);
~~^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/stdlib.h:146:34: error: unknown type name 'lldiv_t'
inline _LIBCPP_INLINE_VISIBILITY lldiv_t div(long long __x,
^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/stdlib.h:148:12: error: no member named 'lldiv' in the global namespace
return ::lldiv(__x, __y);
~~^
In file included from input_line_1:1:
In file included from /Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/new:90:
In file included from /Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/exception:81:
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/cstdlib:100:9: error: no member named 'div_t' in the global namespace
using ::div_t;
~~^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/cstdlib:101:9: error: no member named 'ldiv_t' in the global namespace
using ::ldiv_t;
~~^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/cstdlib:103:9: error: no member named 'lldiv_t' in the global namespace
using ::lldiv_t;
~~^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/cstdlib:105:9: error: no member named 'atof' in the global namespace
using ::atof;
~~^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/cstdlib:106:9: error: no member named 'atoi' in the global namespace
using ::atoi;
~~^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/cstdlib:107:9: error: no member named 'atol' in the global namespace
using ::atol;
~~^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/cstdlib:109:9: error: no member named 'atoll' in the global namespace
using ::atoll;
~~^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/cstdlib:111:9: error: no member named 'strtod' in the global namespace
using ::strtod;
~~^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/cstdlib:112:9: error: no member named 'strtof' in the global namespace
using ::strtof;
~~^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/cstdlib:113:9: error: no member named 'strtold' in the global namespace
using ::strtold;
~~^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/cstdlib:114:9: error: no member named 'strtol' in the global namespace
using ::strtol;
~~^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/cstdlib:116:9: error: no member named 'strtoll' in the global namespace
using ::strtoll;
~~^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/cstdlib:118:9: error: no member named 'strtoul' in the global namespace
using ::strtoul;
~~^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/cstdlib:120:9: error: no member named 'strtoull' in the global namespace
using ::strtoull;
~~^
/Users/andrewssobral/opt/miniconda3/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=]
[I 2021-07-11 15:21:52.831 ServerApp] AsyncIOLoopKernelRestarter: restarting kernel (3/5), new random ports
In file included from input_line_1:1:
In file included from /Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/new:90:
In file included from /Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/exception:81:
In file included from /Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/cstdlib:85:
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/stdlib.h:142:34: error: unknown type name 'ldiv_t'
inline _LIBCPP_INLINE_VISIBILITY ldiv_t div(long __x, long __y) _NOEXCEPT {
^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/stdlib.h:143:12: error: no member named 'ldiv' in the global namespace
return ::ldiv(__x, __y);
~~^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/stdlib.h:146:34: error: unknown type name 'lldiv_t'
inline _LIBCPP_INLINE_VISIBILITY lldiv_t div(long long __x,
^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/stdlib.h:148:12: error: no member named 'lldiv' in the global namespace
return ::lldiv(__x, __y);
~~^
In file included from input_line_1:1:
In file included from /Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/new:90:
In file included from /Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/exception:81:
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/cstdlib:100:9: error: no member named 'div_t' in the global namespace
using ::div_t;
~~^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/cstdlib:101:9: error: no member named 'ldiv_t' in the global namespace
using ::ldiv_t;
~~^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/cstdlib:103:9: error: no member named 'lldiv_t' in the global namespace
using ::lldiv_t;
~~^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/cstdlib:105:9: error: no member named 'atof' in the global namespace
using ::atof;
~~^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/cstdlib:106:9: error: no member named 'atoi' in the global namespace
using ::atoi;
~~^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/cstdlib:107:9: error: no member named 'atol' in the global namespace
using ::atol;
~~^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/cstdlib:109:9: error: no member named 'atoll' in the global namespace
using ::atoll;
~~^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/cstdlib:111:9: error: no member named 'strtod' in the global namespace
using ::strtod;
~~^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/cstdlib:112:9: error: no member named 'strtof' in the global namespace
using ::strtof;
~~^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/cstdlib:113:9: error: no member named 'strtold' in the global namespace
using ::strtold;
~~^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/cstdlib:114:9: error: no member named 'strtol' in the global namespace
using ::strtol;
~~^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/cstdlib:116:9: error: no member named 'strtoll' in the global namespace
using ::strtoll;
~~^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/cstdlib:118:9: error: no member named 'strtoul' in the global namespace
using ::strtoul;
~~^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/cstdlib:120:9: error: no member named 'strtoull' in the global namespace
using ::strtoull;
~~^
/Users/andrewssobral/opt/miniconda3/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=]
This is what I have by calling cling -v:
(cling) andrewssobral@macbookpro tmp % cling -v
Adding library paths from 'LD_LIBRARY_PATH':
Adding library paths from 'DYLD_LIBRARY_PATH':
Adding library paths from 'DYLD_FALLBACK_LIBRARY_PATH':
cling version 0.8
Looking for C++ headers with:
LC_ALL=C /Users/andrewssobral/opt/miniconda3/envs/cling/bin/clang -stdlib=libc++ -xc++ -E -v /dev/null 2>&1 | sed -n -e '/^.include/,${' -e '/^ \/.*++/p' -e '}'
Found:
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1
/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/c++/v1
clang version 5.0.0
Target: x86_64-apple-darwin20.3.0
Thread model: posix
InstalledDir:
ignoring nonexistent directory "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/local/include"
ignoring nonexistent directory "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/Library/Frameworks"
#include "..." search starts here:
#include <...> search starts here:
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1
/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/c++/v1
/Users/andrewssobral/opt/miniconda3/envs/cling/bin/../lib/clang/5.0.0/include
/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include
/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/System/Library/Frameworks (framework directory)
End of search list.
Adding runtime include paths:
""
Added include paths:
Added include paths:
/Users/andrewssobral/opt/miniconda3/envs/cling/include
Setting up system headers with clang:
ignoring nonexistent directory "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/local/include"
ignoring nonexistent directory "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/Library/Frameworks"
#include "..." search starts here:
#include <...> search starts here:
/Users/andrewssobral/opt/miniconda3/envs/cling/include
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1
/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/c++/v1
/Users/andrewssobral/opt/miniconda3/envs/cling/bin/../lib/clang/5.0.0/include
/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include
/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/System/Library/Frameworks (framework directory)
End of search list.
In file included from input_line_1:1:
In file included from /Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/new:90:
In file included from /Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/exception:81:
In file included from /Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/cstdlib:85:
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/stdlib.h:142:34: error: unknown type name 'ldiv_t'
inline _LIBCPP_INLINE_VISIBILITY ldiv_t div(long __x, long __y) _NOEXCEPT {
^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/stdlib.h:143:12: error: no member named 'ldiv' in the global namespace
return ::ldiv(__x, __y);
~~^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/stdlib.h:146:34: error: unknown type name 'lldiv_t'
inline _LIBCPP_INLINE_VISIBILITY lldiv_t div(long long __x,
^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/stdlib.h:148:12: error: no member named 'lldiv' in the global namespace
return ::lldiv(__x, __y);
~~^
In file included from input_line_1:1:
In file included from /Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/new:90:
In file included from /Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/exception:81:
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/cstdlib:100:9: error: no member named 'div_t' in the global namespace
using ::div_t;
~~^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/cstdlib:101:9: error: no member named 'ldiv_t' in the global namespace
using ::ldiv_t;
~~^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/cstdlib:103:9: error: no member named 'lldiv_t' in the global namespace
using ::lldiv_t;
~~^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/cstdlib:105:9: error: no member named 'atof' in the global namespace
using ::atof;
~~^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/cstdlib:106:9: error: no member named 'atoi' in the global namespace
using ::atoi;
~~^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/cstdlib:107:9: error: no member named 'atol' in the global namespace
using ::atol;
~~^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/cstdlib:109:9: error: no member named 'atoll' in the global namespace
using ::atoll;
~~^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/cstdlib:111:9: error: no member named 'strtod' in the global namespace
using ::strtod;
~~^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/cstdlib:112:9: error: no member named 'strtof' in the global namespace
using ::strtof;
~~^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/cstdlib:113:9: error: no member named 'strtold' in the global namespace
using ::strtold;
~~^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/cstdlib:114:9: error: no member named 'strtol' in the global namespace
using ::strtol;
~~^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/cstdlib:116:9: error: no member named 'strtoll' in the global namespace
using ::strtoll;
~~^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/cstdlib:118:9: error: no member named 'strtoul' in the global namespace
using ::strtoul;
~~^
/Users/andrewssobral/opt/miniconda3/envs/cling/include/c++/v1/cstdlib:120:9: error: no member named 'strtoull' in the global namespace
using ::strtoull;
~~^
/Users/andrewssobral/opt/miniconda3/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=]
#include "cling/Interpreter/RuntimeUniverse.h"
namespace cling { class Interpreter; namespace runtime { Interpreter* gCling=(Interpreter*)0x7ffee64e1450;
RuntimeOptions* gClingOpts=(RuntimeOptions*)0x7ffee64e15ac;}}
extern "C" int __cxa_atexit(void (*f)(void*), void*, void*) ;
#define __dso_handle ((void*)0x7ffee64e1450)
extern "C" int atexit(void(*f)()) { return __cxa_atexit((void(*)(void*))f, 0, __dso_handle); }
extern "C" int at_quick_exit(void(*f)()) { return __cxa_atexit((void(*)(void*))f, 0, __dso_handle); }
Added include paths:
.
****************** CLING ******************
* Type C++ code and press enter to run it *
* Type .q to exit *
*******************************************
[cling]$
Same issue, with Xeus-cling freshly installed with min-conda. Kernel wan't start in the Jupiter notebook.
Isn't this the same issue as https://github.com/jupyter-xeus/xeus-cling/issues/412?
Not entirely sure: as mentioned in the description the issue mentioned here appeared with the upgrade to macOS 11.3, and the other issue is for an older version of macOS (but conda version may have evolved as well since then).
same here
Hi everyone,
same issue for me. (macOS 12.01, Xcode 13.1).
No problems raised during the installation process:
brew install miniforge conda install mamba -n base -c conda-forge mamba create -n cling source activate cling mamba install xeus-cling -c conda-forge mamba install jupyterlab -c conda-forge
But I got this:
In file included from input_line_1:1: In file included from /usr/local/Caskroom/miniforge/base/envs/cling/include/c++/v1/new:92: In file included from /usr/local/Caskroom/miniforge/base/envs/cling/include/c++/v1/cstdlib:85: /usr/local/Caskroom/miniforge/base/envs/cling/include/c++/v1/stdlib.h:142:34: error: unknown type name 'ldiv_t' inline _LIBCPP_INLINE_VISIBILITY ldiv_t div(long __x, long __y) _NOEXCEPT { ^ /usr/local/Caskroom/miniforge/base/envs/cling/include/c++/v1/stdlib.h:143:12: error: no member named 'ldiv' in the global namespace return ::ldiv(__x, __y); ~~^ /usr/local/Caskroom/miniforge/base/envs/cling/include/c++/v1/stdlib.h:146:34: error: unknown type name 'lldiv_t' inline _LIBCPP_INLINE_VISIBILITY lldiv_t div(long long __x, ^ /usr/local/Caskroom/miniforge/base/envs/cling/include/c++/v1/stdlib.h:148:12: error: no member named 'lldiv' in the global namespace return ::lldiv(__x, __y); ~~^ In file included from input_line_1:1: In file included from /usr/local/Caskroom/miniforge/base/envs/cling/include/c++/v1/new:92: /usr/local/Caskroom/miniforge/base/envs/cling/include/c++/v1/cstdlib:100:9: error: no member named 'div_t' in the global namespace using ::div_t _LIBCPP_USING_IF_EXISTS; ~~^ /usr/local/Caskroom/miniforge/base/envs/cling/include/c++/v1/cstdlib:101:9: error: no member named 'ldiv_t' in the global namespace using ::ldiv_t _LIBCPP_USING_IF_EXISTS; ~~^ /usr/local/Caskroom/miniforge/base/envs/cling/include/c++/v1/cstdlib:103:9: error: no member named 'lldiv_t' in the global namespace using ::lldiv_t _LIBCPP_USING_IF_EXISTS; ~~^ /usr/local/Caskroom/miniforge/base/envs/cling/include/c++/v1/cstdlib:105:9: error: no member named 'atof' in the global namespace using ::atof _LIBCPP_USING_IF_EXISTS; ~~^ /usr/local/Caskroom/miniforge/base/envs/cling/include/c++/v1/cstdlib:106:9: error: no member named 'atoi' in the global namespace using ::atoi _LIBCPP_USING_IF_EXISTS; ~~^ /usr/local/Caskroom/miniforge/base/envs/cling/include/c++/v1/cstdlib:107:9: error: no member named 'atol' in the global namespace using ::atol _LIBCPP_USING_IF_EXISTS; ~~^ /usr/local/Caskroom/miniforge/base/envs/cling/include/c++/v1/cstdlib:109:9: error: no member named 'atoll' in the global namespace using ::atoll _LIBCPP_USING_IF_EXISTS; ~~^ /usr/local/Caskroom/miniforge/base/envs/cling/include/c++/v1/cstdlib:111:9: error: no member named 'strtod' in the global namespace using ::strtod _LIBCPP_USING_IF_EXISTS; ~~^ /usr/local/Caskroom/miniforge/base/envs/cling/include/c++/v1/cstdlib:112:9: error: no member named 'strtof' in the global namespace using ::strtof _LIBCPP_USING_IF_EXISTS; ~~^ /usr/local/Caskroom/miniforge/base/envs/cling/include/c++/v1/cstdlib:113:9: error: no member named 'strtold' in the global namespace using ::strtold _LIBCPP_USING_IF_EXISTS; ~~^ /usr/local/Caskroom/miniforge/base/envs/cling/include/c++/v1/cstdlib:114:9: error: no member named 'strtol' in the global namespace using ::strtol _LIBCPP_USING_IF_EXISTS; ~~^ /usr/local/Caskroom/miniforge/base/envs/cling/include/c++/v1/cstdlib:116:9: error: no member named 'strtoll' in the global namespace using ::strtoll _LIBCPP_USING_IF_EXISTS; ~~^ /usr/local/Caskroom/miniforge/base/envs/cling/include/c++/v1/cstdlib:118:9: error: no member named 'strtoul' in the global namespace using ::strtoul _LIBCPP_USING_IF_EXISTS; ~~^ /usr/local/Caskroom/miniforge/base/envs/cling/include/c++/v1/cstdlib:120:9: error: no member named 'strtoull' in the global namespace using ::strtoull _LIBCPP_USING_IF_EXISTS; ~~^ /usr/local/Caskroom/miniforge/base/envs/cling/include/c++/v1/cstdlib:122:9: error: no member named 'rand' in the global namespace using ::rand _LIBCPP_USING_IF_EXISTS; ~~^ fatal error: too many errors emitted, stopping now [-ferror-limit=]
I would like to know if this issue was resolved. Thx.
$ sudo ln -s /Library/Developer/CommandLineTools/SDKs/MacOSX10.15.sdk /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk
temporary fix, cling looks 10.15..
Hi, thanks for your suggestions. I tried this command while it didn't work in my case. Best regards.
@XuShuqi7 yeah this is xues-cling.. thought u guys were literally running cling as a CLI REPL. APologies.
@horribleCCguru Never mind. In any case, thank you for your advice^_^.
Hello everyone, I have spent some time investigating this issue, and found the root cause. I provided the long form description in an issue on the clangdev conda-forge package: https://github.com/conda-forge/clangdev-feedstock/issues/188.
I am working on a clean fix for this. In the mean time, a workaround for OS X users of cling 0.8 who experience this issue is to forcibly remove libcxx from their conda environment, with conda remove libcxx --force
. Note: if you don't have the xcode command line tools installed, you should not have this issue, and removing libcxx will break cling.
Any progress on a clean solution?
@AngryMaciek I did the force removal of libcxx
(version 16.0.6) and then when it didn't help, reinstalled libcxx
(14.0.6). The package manager chose me a different version for some reason (14.0.6) and lo and behold, it works perfectly.
So maybe just changing the version of libcxx could do it? (I wonder what other thing is broken now though.)
I'm on a different macOS version though. Still, changing the libcxx version is worth a try?