File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -76,10 +76,8 @@ elif [ "$cxx_type" = "clang" ]; then
7676 inc=" $inc -I/usr/include/x86_64-linux-gnu"
7777 fi
7878elif [ " $cxx_type " = " Apple" ]; then
79- clang_ver=$( $CXX -dumpversion)
80- echo $clang_ver
81- clang_ver=${clang_ver%% .* }
82- echo $clang_ver
79+ appleclang_ver=$( $CXX -dumpversion)
80+ appleclang_ver=${clang_ver%% .* }
8381 xcode_path=" /Applications/Xcode_16.4.app"
8482 if [ ! -d " $xcode_path " ]; then
8583 xcode_path=" /Applications/Xcode_15.2.app"
@@ -107,7 +105,9 @@ elif [ "$cxx_type" = "Apple" ]; then
107105 inc=" $inc -I$sdk_path /usr/include/c++/v1"
108106 inc=" $inc -I$sdk_path /usr/include"
109107 inc=" $inc -I$sdk_path /usr/include/i386"
110- inc=" $inc -I$xcode_path /Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/clang/$clang_ver /include/"
108+ if [ -d " $xcode_path /Contents/Developer/Toolchains/XcodeDefault.xctoolchain" ]; then
109+ inc=" $inc -I$xcode_path /Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/clang/$appleclang_ver /include/"
110+ fi
111111else
112112 echo " unknown compiler '$cxx_type '"
113113 exit 1
You can’t perform that action at this time.
0 commit comments