Skip to content

Commit 0e9fd65

Browse files
committed
Indent the code and add set -x.
1 parent dab0095 commit 0e9fd65

File tree

1 file changed

+15
-12
lines changed

1 file changed

+15
-12
lines changed

utils/build-script-impl

Lines changed: 15 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -2068,21 +2068,24 @@ for deployment_target in "${HOST_TARGET}" "${CROSS_TOOLS_DEPLOYMENT_TARGETS[@]}"
20682068

20692069
# When we are building LLVM create symlinks to the c++ headers.
20702070
if [[ "${product}" == "llvm" ]]; then
2071+
set -x
2072+
2073+
# Find the location of the c++ header dir.
2074+
if [[ "$(uname -s)" == "Darwin" ]] ; then
2075+
HOST_CXX_DIR=$(dirname ${HOST_CXX})
2076+
HOST_CXX_HEADERS_DIR="$HOST_CXX_DIR/../../usr/include/c++"
2077+
else # Linux
2078+
HOST_CXX_HEADERS_DIR="/usr/include/c++"
2079+
fi
20712080

2072-
# Find the location of the c++ header dir.
2073-
if [[ "$(uname -s)" == "Darwin" ]] ; then
2074-
HOST_CXX_DIR=$(dirname ${HOST_CXX})
2075-
HOST_CXX_HEADERS_DIR="$HOST_CXX_DIR/../../usr/include/c++"
2076-
else # Linux
2077-
HOST_CXX_HEADERS_DIR="/usr/include/c++"
2078-
fi
2081+
# Find the path in which the local clang build is expecting to find
2082+
# the c++ header files.
2083+
BUILT_CXX_INCLUDE_DIR="$llvm_build_dir/include"
20792084

2080-
# Find the path in which the local clang build is expecting to find
2081-
# the c++ header files.
2082-
BUILT_CXX_INCLUDE_DIR="$llvm_build_dir/include"
2085+
echo "symlinking the system headers ($HOST_CXX_HEADERS_DIR) into the local clang build directory ($BUILT_CXX_INCLUDE_DIR)."
2086+
ln -s -f "$HOST_CXX_HEADERS_DIR" "$BUILT_CXX_INCLUDE_DIR/c++"
20832087

2084-
echo "symlinking the system headers ($HOST_CXX_HEADERS_DIR) into the local clang build directory ($BUILT_CXX_INCLUDE_DIR)."
2085-
ln -s -f "$HOST_CXX_HEADERS_DIR" "$BUILT_CXX_INCLUDE_DIR/c++"
2088+
{ set +x; } 2>/dev/null
20862089
fi
20872090
done
20882091
done

0 commit comments

Comments
 (0)