File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -20,7 +20,19 @@ cxx_type=$($CXX --version | head -1 | cut -d' ' -f1)
2020if [ " $cxx_type " = " Ubuntu" ]; then
2121 cxx_type=$( $CXX --version | head -1 | cut -d' ' -f2)
2222fi
23- # TODO: how to get built-in include paths from compiler?
23+ # TODO: get built-in include paths from compiler
24+ # $CXX -x c++ -v -c - < /dev/null
25+ # ...
26+ # include <...> search starts here:
27+ # /usr/include/c++/14
28+ # /usr/include/x86_64-linux-gnu/c++/14
29+ # /usr/include/c++/14/backward
30+ # /usr/lib/gcc/x86_64-linux-gnu/14/include
31+ # /usr/local/include
32+ # /usr/include/x86_64-linux-gnu
33+ # /usr/include
34+ # End of search list.
35+ #
2436if [ " $cxx_type " = " g++" ] || [ " $cxx_type " = " g++.exe" ]; then
2537 gcc_ver=$( $CXX -dumpversion)
2638 gcc_target=$( $CXX -v 2>&1 | grep Target: | cut -d' ' -f2)
@@ -39,7 +51,7 @@ if [ "$cxx_type" = "g++" ] || [ "$cxx_type" = "g++.exe" ]; then
3951 find /usr -name stddef.h
4052 find /usr/include -name stddef.h
4153 find /usr -name c++config.h
42- cat /usr/lib/gcc/x86_64-pc-cygwin/15.2.0/ include/c++/bits/requires_hosted .h
54+ cat /usr/include/sys/_intsup .h
4355 # some required include paths might differ per distro
4456 inc=
4557 inc=" $inc -I/usr/include"
You can’t perform that action at this time.
0 commit comments