Skip to content

Commit

Permalink
Add Include what you use
Browse files Browse the repository at this point in the history
  • Loading branch information
esigo committed Jul 1, 2023
1 parent 049ab63 commit 6336882
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 5 deletions.
12 changes: 8 additions & 4 deletions ci/do_ci.sh
Original file line number Diff line number Diff line change
Expand Up @@ -109,8 +109,9 @@ elif [[ "$1" == "cmake.maintainer.sync.test" ]]; then
-DWITH_ASYNC_EXPORT_PREVIEW=OFF \
-DOTELCPP_MAINTAINER_MODE=ON \
-DWITH_NO_DEPRECATED_CODE=ON \
-DCMAKE_CXX_INCLUDE_WHAT_YOU_USE="iwyu" \
"${SRC_DIR}"
make -k
make -k CXX=include-what-you-use CXXFLAGS="-Xiwyu --error_always"
make test
exit 0
elif [[ "$1" == "cmake.maintainer.async.test" ]]; then
Expand All @@ -132,8 +133,9 @@ elif [[ "$1" == "cmake.maintainer.async.test" ]]; then
-DWITH_ASYNC_EXPORT_PREVIEW=ON \
-DOTELCPP_MAINTAINER_MODE=ON \
-DWITH_NO_DEPRECATED_CODE=ON \
-DCMAKE_CXX_INCLUDE_WHAT_YOU_USE="iwyu" \
"${SRC_DIR}"
make -k -j $(nproc)
make -k CXX=include-what-you-use CXXFLAGS="-Xiwyu --error_always" -j $(nproc)
make test
exit 0
elif [[ "$1" == "cmake.maintainer.cpp11.async.test" ]]; then
Expand Down Expand Up @@ -206,8 +208,9 @@ elif [[ "$1" == "cmake.c++20.test" ]]; then
-DCMAKE_CXX_FLAGS="-Werror $CXXFLAGS" \
-DWITH_ASYNC_EXPORT_PREVIEW=ON \
-DCMAKE_CXX_STANDARD=20 \
-DCMAKE_CXX_INCLUDE_WHAT_YOU_USE="iwyu" \
"${SRC_DIR}"
make -j $(nproc)
make -k CXX=include-what-you-use CXXFLAGS="-Xiwyu --error_always" -j $(nproc)
make test
exit 0
elif [[ "$1" == "cmake.c++20.stl.test" ]]; then
Expand All @@ -219,8 +222,9 @@ elif [[ "$1" == "cmake.c++20.stl.test" ]]; then
-DCMAKE_CXX_FLAGS="-Werror $CXXFLAGS" \
-DWITH_ASYNC_EXPORT_PREVIEW=ON \
-DWITH_STL=ON \
-DCMAKE_CXX_INCLUDE_WHAT_YOU_USE="iwyu" \
"${SRC_DIR}"
make -j $(nproc)
make -k CXX=include-what-you-use CXXFLAGS="-Xiwyu --error_always" -j $(nproc)
make test
exit 0
elif [[ "$1" == "cmake.legacy.test" ]]; then
Expand Down
3 changes: 2 additions & 1 deletion ci/setup_ci_environment.sh
Original file line number Diff line number Diff line change
Expand Up @@ -11,4 +11,5 @@ apt-get install --no-install-recommends --no-install-suggests -y \
wget \
git \
valgrind \
lcov
lcov \
iwyu

0 comments on commit 6336882

Please sign in to comment.