Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Compilation failed #1

Open
woodongwong opened this issue Apr 3, 2018 · 2 comments
Open

Compilation failed #1

woodongwong opened this issue Apr 3, 2018 · 2 comments

Comments

@woodongwong
Copy link

woodongwong commented Apr 3, 2018

Someone said it was because of a bug in Ubuntu,I know why!
My system environment is as follows:

Linux woodong-pc 4.13.0-37-generic #42~16.04.1-Ubuntu SMP Wed Mar 7 16:03:28 UTC 2018 x86_64 x86_64 x86_64 GNU/Linux

logs:

...patience...
...found 1368 targets...
...updating 75 targets...
common.mkdir stage
common.mkdir stage/lib
common.mkdir bin.v2/libs/system/build/clang-linux-3.9.1/release
common.mkdir bin.v2/libs/system/build/clang-linux-3.9.1/release/threading-multi
clang-linux.compile.c++.without-pth bin.v2/libs/system/build/clang-linux-3.9.1/release/threading-multi/error_code.o
clang-linux.link.dll bin.v2/libs/system/build/clang-linux-3.9.1/release/threading-multi/libboost_system.so.1.62.0
common.copy stage/lib/libboost_system.so.1.62.0
ln-UNIX stage/lib/libboost_system.so
common.mkdir bin.v2/libs/thread/build/clang-linux-3.9.1/release
common.mkdir bin.v2/libs/thread/build/clang-linux-3.9.1/release/threading-multi
common.mkdir bin.v2/libs/thread/build/clang-linux-3.9.1/release/threading-multi/pthread
clang-linux.compile.c++.without-pth bin.v2/libs/thread/build/clang-linux-3.9.1/release/threading-multi/pthread/thread.o
In file included from libs/thread/src/pthread/thread.cpp:11:
In file included from ./boost/thread/thread_only.hpp:17:
In file included from ./boost/thread/pthread/thread_data.hpp:12:
In file included from ./boost/thread/lock_types.hpp:18:
In file included from ./boost/thread/thread_time.hpp:9:
In file included from ./boost/date_time/time_clock.hpp:17:
In file included from ./boost/shared_ptr.hpp:17:
In file included from ./boost/smart_ptr/shared_ptr.hpp:28:
In file included from ./boost/smart_ptr/detail/shared_count.hpp:29:
In file included from ./boost/smart_ptr/detail/sp_counted_base.hpp:45:
In file included from ./boost/smart_ptr/detail/sp_counted_base_clang.hpp:18:
In file included from ./boost/detail/sp_typeinfo.hpp:20:
In file included from ./boost/core/typeinfo.hpp:119:
In file included from ./boost/core/demangle.hpp:32:
/usr/include/c++/v1/cxxabi.h:21:10: fatal error: '__cxxabi_config.h' file not found
#include <__cxxabi_config.h>
         ^
1 error generated.

  "clang++" -c -x c++ "-stdlib=libc++" -Wextra -Wno-long-long -Wno-unused-parameter -Wno-variadic-macros -Wunused-function -O3 -Wno-inline -Wall -pthread -fPIC -m64 "-stdlib=libc++" -Wextra -Wno-long-long -Wno-unused-parameter -Wno-variadic-macros -Wunused-function -DBOOST_ALL_NO_LIB=1 -DBOOST_SYSTEM_DYN_LINK=1 -DBOOST_THREAD_BUILD_DLL=1 -DBOOST_THREAD_DONT_USE_CHRONO -DBOOST_THREAD_POSIX -DNDEBUG -I"." -o "bin.v2/libs/thread/build/clang-linux-3.9.1/release/threading-multi/pthread/thread.o" "libs/thread/src/pthread/thread.cpp"

...failed clang-linux.compile.c++.without-pth bin.v2/libs/thread/build/clang-linux-3.9.1/release/threading-multi/pthread/thread.o...
clang-linux.compile.c++.without-pth bin.v2/libs/thread/build/clang-linux-3.9.1/release/threading-multi/pthread/once.o
clang-linux.compile.c++.without-pth bin.v2/libs/thread/build/clang-linux-3.9.1/release/threading-multi/future.o
...skipped <pbin.v2/libs/thread/build/clang-linux-3.9.1/release/threading-multi>libboost_thread.so.1.62.0 for lack of <pbin.v2/libs/thread/build/clang-linux-3.9.1/release/threading-multi>pthread/thread.o...
...skipped <pstage/lib>libboost_thread.so.1.62.0 for lack of <pbin.v2/libs/thread/build/clang-linux-3.9.1/release/threading-multi>libboost_thread.so.1.62.0...
...skipped <pstage/lib>libboost_thread.so for lack of <pstage/lib>libboost_thread.so.1.62.0...
common.mkdir bin.v2/libs/chrono
common.mkdir bin.v2/libs/chrono/build
common.mkdir bin.v2/libs/chrono/build/clang-linux-3.9.1
common.mkdir bin.v2/libs/chrono/build/clang-linux-3.9.1/release
common.mkdir bin.v2/libs/chrono/build/clang-linux-3.9.1/release/threading-multi
clang-linux.compile.c++.without-pth bin.v2/libs/chrono/build/clang-linux-3.9.1/release/threading-multi/chrono.o
clang-linux.compile.c++.without-pth bin.v2/libs/chrono/build/clang-linux-3.9.1/release/threading-multi/thread_clock.o
clang-linux.compile.c++.without-pth bin.v2/libs/chrono/build/clang-linux-3.9.1/release/threading-multi/process_cpu_clocks.o
clang-linux.link.dll bin.v2/libs/chrono/build/clang-linux-3.9.1/release/threading-multi/libboost_chrono.so.1.62.0
common.copy stage/lib/libboost_chrono.so.1.62.0
ln-UNIX stage/lib/libboost_chrono.so
common.mkdir bin.v2/libs/context/build/clang-linux-3.9.1/release
common.mkdir bin.v2/libs/context/build/clang-linux-3.9.1/release/threading-multi
common.mkdir bin.v2/libs/context/build/clang-linux-3.9.1/release/threading-multi/asm
clang-linux.compile.asm bin.v2/libs/context/build/clang-linux-3.9.1/release/threading-multi/asm/make_x86_64_sysv_elf_gas.o
clang-linux.compile.asm bin.v2/libs/context/build/clang-linux-3.9.1/release/threading-multi/asm/jump_x86_64_sysv_elf_gas.o
clang-linux.compile.asm bin.v2/libs/context/build/clang-linux-3.9.1/release/threading-multi/asm/ontop_x86_64_sysv_elf_gas.o
common.mkdir bin.v2/libs/context/build/clang-linux-3.9.1/release/threading-multi/posix
clang-linux.compile.c++.without-pth bin.v2/libs/context/build/clang-linux-3.9.1/release/threading-multi/posix/stack_traits.o
In file included from libs/context/src/posix/stack_traits.cpp:24:
In file included from ./boost/thread.hpp:13:
In file included from ./boost/thread/thread.hpp:12:
In file included from ./boost/thread/thread_only.hpp:17:
In file included from ./boost/thread/pthread/thread_data.hpp:12:
In file included from ./boost/thread/lock_types.hpp:18:
In file included from ./boost/thread/thread_time.hpp:9:
In file included from ./boost/date_time/time_clock.hpp:17:
In file included from ./boost/shared_ptr.hpp:17:
In file included from ./boost/smart_ptr/shared_ptr.hpp:28:
In file included from ./boost/smart_ptr/detail/shared_count.hpp:29:
In file included from ./boost/smart_ptr/detail/sp_counted_base.hpp:45:
In file included from ./boost/smart_ptr/detail/sp_counted_base_clang.hpp:18:
In file included from ./boost/detail/sp_typeinfo.hpp:20:
In file included from ./boost/core/typeinfo.hpp:119:
In file included from ./boost/core/demangle.hpp:32:
/usr/include/c++/v1/cxxabi.h:21:10: fatal error: '__cxxabi_config.h' file not found
#include <__cxxabi_config.h>
         ^
1 error generated.

  "clang++" -c -x c++ "-stdlib=libc++" -O3 -Wno-inline -Wall -pthread -fPIC -m64 "-stdlib=libc++" -DBOOST_ALL_NO_LIB=1 -DBOOST_CHRONO_DYN_LINK=1 -DBOOST_CONTEXT_DYN_LINK=1 -DBOOST_CONTEXT_SOURCE -DBOOST_DISABLE_ASSERTS -DBOOST_SYSTEM_DYN_LINK=1 -DBOOST_SYSTEM_NO_DEPRECATED -DBOOST_THREAD_BUILD_DLL=1 -DBOOST_THREAD_POSIX -DBOOST_THREAD_USE_DLL=1 -DNDEBUG -I"." -o "bin.v2/libs/context/build/clang-linux-3.9.1/release/threading-multi/posix/stack_traits.o" "libs/context/src/posix/stack_traits.cpp"

...failed clang-linux.compile.c++.without-pth bin.v2/libs/context/build/clang-linux-3.9.1/release/threading-multi/posix/stack_traits.o...
clang-linux.compile.c++.without-pth bin.v2/libs/context/build/clang-linux-3.9.1/release/threading-multi/execution_context.o
...skipped <pbin.v2/libs/context/build/clang-linux-3.9.1/release/threading-multi>libboost_context.so.1.62.0 for lack of <pbin.v2/libs/context/build/clang-linux-3.9.1/release/threading-multi>posix/stack_traits.o...
...skipped <pstage/lib>libboost_context.so.1.62.0 for lack of <pbin.v2/libs/context/build/clang-linux-3.9.1/release/threading-multi>libboost_context.so.1.62.0...
...skipped <pstage/lib>libboost_context.so for lack of <pstage/lib>libboost_context.so.1.62.0...
common.mkdir bin.v2/libs/system/build/clang-linux-3.9.1/release/link-static
common.mkdir bin.v2/libs/system/build/clang-linux-3.9.1/release/link-static/threading-multi
clang-linux.compile.c++.without-pth bin.v2/libs/system/build/clang-linux-3.9.1/release/link-static/threading-multi/error_code.o
clang-linux.archive bin.v2/libs/system/build/clang-linux-3.9.1/release/link-static/threading-multi/libboost_system.a
common.copy stage/lib/libboost_system.a
common.mkdir bin.v2/libs/thread/build/clang-linux-3.9.1/release/link-static
common.mkdir bin.v2/libs/thread/build/clang-linux-3.9.1/release/link-static/threading-multi
common.mkdir bin.v2/libs/thread/build/clang-linux-3.9.1/release/link-static/threading-multi/pthread
clang-linux.compile.c++.without-pth bin.v2/libs/thread/build/clang-linux-3.9.1/release/link-static/threading-multi/pthread/thread.o
In file included from libs/thread/src/pthread/thread.cpp:11:
In file included from ./boost/thread/thread_only.hpp:17:
In file included from ./boost/thread/pthread/thread_data.hpp:12:
In file included from ./boost/thread/lock_types.hpp:18:
In file included from ./boost/thread/thread_time.hpp:9:
In file included from ./boost/date_time/time_clock.hpp:17:
In file included from ./boost/shared_ptr.hpp:17:
In file included from ./boost/smart_ptr/shared_ptr.hpp:28:
In file included from ./boost/smart_ptr/detail/shared_count.hpp:29:
In file included from ./boost/smart_ptr/detail/sp_counted_base.hpp:45:
In file included from ./boost/smart_ptr/detail/sp_counted_base_clang.hpp:18:
In file included from ./boost/detail/sp_typeinfo.hpp:20:
In file included from ./boost/core/typeinfo.hpp:119:
In file included from ./boost/core/demangle.hpp:32:
/usr/include/c++/v1/cxxabi.h:21:10: fatal error: '__cxxabi_config.h' file not found
#include <__cxxabi_config.h>
         ^
1 error generated.

  "clang++" -c -x c++ "-stdlib=libc++" -Wextra -Wno-long-long -Wno-unused-parameter -Wno-variadic-macros -Wunused-function -O3 -Wno-inline -Wall -pthread -m64 "-stdlib=libc++" -Wextra -Wno-long-long -Wno-unused-parameter -Wno-variadic-macros -Wunused-function -DBOOST_ALL_NO_LIB=1 -DBOOST_SYSTEM_STATIC_LINK=1 -DBOOST_THREAD_BUILD_LIB=1 -DBOOST_THREAD_DONT_USE_CHRONO -DBOOST_THREAD_POSIX -DNDEBUG -I"." -o "bin.v2/libs/thread/build/clang-linux-3.9.1/release/link-static/threading-multi/pthread/thread.o" "libs/thread/src/pthread/thread.cpp"

...failed clang-linux.compile.c++.without-pth bin.v2/libs/thread/build/clang-linux-3.9.1/release/link-static/threading-multi/pthread/thread.o...
clang-linux.compile.c++.without-pth bin.v2/libs/thread/build/clang-linux-3.9.1/release/link-static/threading-multi/pthread/once.o
clang-linux.compile.c++.without-pth bin.v2/libs/thread/build/clang-linux-3.9.1/release/link-static/threading-multi/future.o
...skipped <pbin.v2/libs/thread/build/clang-linux-3.9.1/release/link-static/threading-multi>libboost_thread.a(clean) for lack of <pbin.v2/libs/thread/build/clang-linux-3.9.1/release/link-static/threading-multi>pthread/thread.o...
...skipped <pbin.v2/libs/thread/build/clang-linux-3.9.1/release/link-static/threading-multi>libboost_thread.a for lack of <pbin.v2/libs/thread/build/clang-linux-3.9.1/release/link-static/threading-multi>pthread/thread.o...
...skipped <pstage/lib>libboost_thread.a for lack of <pbin.v2/libs/thread/build/clang-linux-3.9.1/release/link-static/threading-multi>libboost_thread.a...
common.mkdir bin.v2/libs/chrono/build/clang-linux-3.9.1/release/link-static
common.mkdir bin.v2/libs/chrono/build/clang-linux-3.9.1/release/link-static/threading-multi
clang-linux.compile.c++.without-pth bin.v2/libs/chrono/build/clang-linux-3.9.1/release/link-static/threading-multi/chrono.o
clang-linux.compile.c++.without-pth bin.v2/libs/chrono/build/clang-linux-3.9.1/release/link-static/threading-multi/thread_clock.o
clang-linux.compile.c++.without-pth bin.v2/libs/chrono/build/clang-linux-3.9.1/release/link-static/threading-multi/process_cpu_clocks.o
clang-linux.archive bin.v2/libs/chrono/build/clang-linux-3.9.1/release/link-static/threading-multi/libboost_chrono.a
common.copy stage/lib/libboost_chrono.a
common.mkdir bin.v2/libs/context/build/clang-linux-3.9.1/release/link-static
common.mkdir bin.v2/libs/context/build/clang-linux-3.9.1/release/link-static/threading-multi
common.mkdir bin.v2/libs/context/build/clang-linux-3.9.1/release/link-static/threading-multi/asm
clang-linux.compile.asm bin.v2/libs/context/build/clang-linux-3.9.1/release/link-static/threading-multi/asm/make_x86_64_sysv_elf_gas.o
clang-linux.compile.asm bin.v2/libs/context/build/clang-linux-3.9.1/release/link-static/threading-multi/asm/jump_x86_64_sysv_elf_gas.o
clang-linux.compile.asm bin.v2/libs/context/build/clang-linux-3.9.1/release/link-static/threading-multi/asm/ontop_x86_64_sysv_elf_gas.o
common.mkdir bin.v2/libs/context/build/clang-linux-3.9.1/release/link-static/threading-multi/posix
clang-linux.compile.c++.without-pth bin.v2/libs/context/build/clang-linux-3.9.1/release/link-static/threading-multi/posix/stack_traits.o
In file included from libs/context/src/posix/stack_traits.cpp:24:
In file included from ./boost/thread.hpp:13:
In file included from ./boost/thread/thread.hpp:12:
In file included from ./boost/thread/thread_only.hpp:17:
In file included from ./boost/thread/pthread/thread_data.hpp:12:
In file included from ./boost/thread/lock_types.hpp:18:
In file included from ./boost/thread/thread_time.hpp:9:
In file included from ./boost/date_time/time_clock.hpp:17:
In file included from ./boost/shared_ptr.hpp:17:
In file included from ./boost/smart_ptr/shared_ptr.hpp:28:
In file included from ./boost/smart_ptr/detail/shared_count.hpp:29:
In file included from ./boost/smart_ptr/detail/sp_counted_base.hpp:45:
In file included from ./boost/smart_ptr/detail/sp_counted_base_clang.hpp:18:
In file included from ./boost/detail/sp_typeinfo.hpp:20:
In file included from ./boost/core/typeinfo.hpp:119:
In file included from ./boost/core/demangle.hpp:32:
/usr/include/c++/v1/cxxabi.h:21:10: fatal error: '__cxxabi_config.h' file not found
#include <__cxxabi_config.h>
         ^
1 error generated.

  "clang++" -c -x c++ "-stdlib=libc++" -O3 -Wno-inline -Wall -pthread -m64 "-stdlib=libc++" -DBOOST_ALL_NO_LIB=1 -DBOOST_CHRONO_STATIC_LINK=1 -DBOOST_CONTEXT_SOURCE -DBOOST_DISABLE_ASSERTS -DBOOST_SYSTEM_NO_DEPRECATED -DBOOST_SYSTEM_STATIC_LINK=1 -DBOOST_THREAD_BUILD_LIB=1 -DBOOST_THREAD_POSIX -DBOOST_THREAD_USE_LIB=1 -DNDEBUG -I"." -o "bin.v2/libs/context/build/clang-linux-3.9.1/release/link-static/threading-multi/posix/stack_traits.o" "libs/context/src/posix/stack_traits.cpp"

...failed clang-linux.compile.c++.without-pth bin.v2/libs/context/build/clang-linux-3.9.1/release/link-static/threading-multi/posix/stack_traits.o...
clang-linux.compile.c++.without-pth bin.v2/libs/context/build/clang-linux-3.9.1/release/link-static/threading-multi/execution_context.o
...skipped <pbin.v2/libs/context/build/clang-linux-3.9.1/release/link-static/threading-multi>libboost_context.a(clean) for lack of <pbin.v2/libs/context/build/clang-linux-3.9.1/release/link-static/threading-multi>posix/stack_traits.o...
...skipped <pbin.v2/libs/context/build/clang-linux-3.9.1/release/link-static/threading-multi>libboost_context.a for lack of <pbin.v2/libs/context/build/clang-linux-3.9.1/release/link-static/threading-multi>posix/stack_traits.o...
...skipped <pstage/lib>libboost_context.a for lack of <pbin.v2/libs/context/build/clang-linux-3.9.1/release/link-static/threading-multi>libboost_context.a...
...failed updating 4 targets...
...skipped 12 targets...
...updated 59 targets...
vendor/boost/CMakeFiles/boost.dir/build.make:113: recipe for target 'vendor/boost/src/boost-stamp/boost-build' failed
make[2]: *** [vendor/boost/src/boost-stamp/boost-build] Error 1
CMakeFiles/Makefile2:140: recipe for target 'vendor/boost/CMakeFiles/boost.dir/all' failed
make[1]: *** [vendor/boost/CMakeFiles/boost.dir/all] Error 2
Makefile:83: recipe for target 'all' failed
make: *** [all] Error 2
@zhijunfu
Copy link

add /usr/include/libcxxabi/ to include path environment viable would fix this.

@fsgeek
Copy link

fsgeek commented Apr 11, 2018

Apparently, this is a known Ubuntu issue. The fix for me was to just to create a symlink:

ln -s /usr/include/libcxxabi/__cxxabi_config.h /usr/include/c++/v1/__cxxabi_config.h

There are various discussions about this; the idea to use the symlink to fix it came from here: https://stackoverflow.com/questions/37096062/get-a-basic-c-program-to-compile-using-clang-on-ubuntu-16/38385967#38385967

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants