boostorg / boostorg/python

`type_id.cpp` incorrectly includes `cxxabi.h` even when compiling under libc++abi

オープン
#188 コメント 0 件 リアクション 0 件 担当者 0 名 GitHub で見る
主要言語
C++
スター
537
フォーク
223
平均マージ
11時間 22分
マージ済み PR(30日)
2

説明

Clang itself defines `__GNUC__` and in case of Clang 5, `__GNUC__` is defined to 4. So when compiling `src/converter/type_id.cpp` using clang 5 and its corresponding libc++ and libc++abi, the src file is processed to included `cxxabi.h` after some detections using macro. However, libc++abi itself [does not install its headers](https://github.com/llvm-mirror/libcxxabi/commit/c20d83676d5f48624bd57c5bd70201455ddc30c8) so there is no `cxxabi.h` in system header include directories. Therefore a compile error occurs:

```shell
clang-linux.compile.c++.without-pth bin.v2/libs/python/build/clang-gnu-linux-5.0.1/release/threadapi-pthread/threading-multi/converter/type_id.o
libs/python/src/converter/type_id.cpp:35:14: fatal error: 'cxxabi.h' file not found
# include
^~~~~~~~~~
1 error generated.

"clang++" -c -x c++ -std=c++14 -stdlib=libc++ -O3 -Wno-inline -Wall -pthread -fPIC -m64 -std=c++14 -stdlib=libc++ -DBOOST_ALL_NO_LIB=1 -DBOOST_PYTHON_SOURCE -DNDEBUG -I"." -I"/usr/include/python3.6m" -o "bin.v2/libs/python/build/clang-gnu-linux-5.0.1/release/threadapi-pthread/threading-multi/converter/type_id.o" "libs/python/src/converter/type_id.cpp"

...failed clang-linux.compile.c++.without-pth bin.v2/libs/python/build/clang-gnu-linux-5.0.1/release/threadapi-pthread/threading-multi/converter/type_id.o...
```

コントリビューションガイド

このリポジトリのコントリビューションガイドは索引されていません

評価

この issue はまだ評価されていません。

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。