Am 11.03.2017 um 00:22 schrieb Andrey Semashev via Boost:
On Sat, Mar 11, 2017 at 1:33 AM, Tom Kent via Boost
wrote: So I tried to add my first linux regression runner using libc++ with clang, and I'm seeing the following error saying it can't find <cstddef>: http://www.boost.org/development/tests/develop/developer/output/teeks99-02-d...
That page currently shows a different error:
/usr/include/c++/v1/string:1938:44: error: 'basic_string<_CharT, _Traits, _Allocator>' is missing exception specification 'noexcept' basic_string<_CharT, _Traits, _Allocator>::basic_string(const allocator_type& __a) ^ /usr/include/c++/v1/string:1326:40: note: previous declaration is here _LIBCPP_INLINE_VISIBILITY explicit basic_string(const allocator_type& __a)
This happens after boost/config.hpp is included, which means that cstddef is found. Indeed, cstddef is in /usr/include/c++/v1 on my system, so the compiler clearly looks there.
The error itself looks like a bug in libc++.
This is a known error on Ubuntu/Debian: https://bugs.launchpad.net/ubuntu/+source/libc++/+bug/1610168 And the fix is simple, presuming one can modify header-files of the libc++ installation: http://stackoverflow.com/a/38385967
/usr/include/c++/v1/cxxabi.h:21:10: fatal error: '__cxxabi_config.h' file not found #include <__cxxabi_config.h>
This error is more interesting. I can see this #include in my local libc++ as well, yet I can't find this file on my system.
On my Ubuntu machine I was able to fix this error by adding the following path to the include-search-path: /usr/include/libcxxabi If you do not have this path on your Ubuntu/Debian machine, you need to install libc++abi, too. (DEB-Package: libc++abi-dev)
Both errors indicate that libc++ is broken on Ubuntu (or Linux in general) - either in upstream or in packaging. If that's the case, we can probably stop this testing effort right here and report the bugs to libc++ devs.
It is at least broken on Ubuntu/Debian regarding the problem with the string header. Regarding the second error, I think the user is expected to have libc++abi installed (and possibly explicit link to it, too): http://libcxx.llvm.org/docs/UsingLibcxx.html#using-libc-on-linux
PS: If you're still having problems with cstddef, you can try seeing if the compiler looks in /usr/include/c++/v1 as described here:
http://stackoverflow.com/questions/11946294/dump-include-paths-from-g
If it doesn't, try adding it as an include path. Although, that path obviously should be used by default when libc++ is enabled.
Hope that helps, Deniz