diff options
author | thakis@chromium.org <thakis@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-02-10 20:07:32 +0000 |
---|---|---|
committer | thakis@chromium.org <thakis@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-02-10 20:07:32 +0000 |
commit | abd17cacb223837c7b3a51b164ac6c2813c8e01c (patch) | |
tree | b56e381114558746e7ae5da7196dea8116b4cf78 /tools/clang/scripts | |
parent | 64021049338a2785682dec1a9222fb027c5b0852 (diff) | |
download | chromium_src-abd17cacb223837c7b3a51b164ac6c2813c8e01c.zip chromium_src-abd17cacb223837c7b3a51b164ac6c2813c8e01c.tar.gz chromium_src-abd17cacb223837c7b3a51b164ac6c2813c8e01c.tar.bz2 |
clang: Clobber all .o files after a clang roll.
This has the advantage that after a bad clang roll, try slaves don't
have to be manually clobbered once the roll has been reverted. I also
no longer have to remember to pass --clobber to clang roll tryjobs.
It's a bit annoying that a clang roll now requires a full rebuild for
devs, but so do header changes in base/, and we no longer need to send
"please clobber your build directory" emails after reverting a bad clang
roll.
BUG=113653
TEST=`rm third_party/llvm-bulid/cr_build-revision; tools/clang/scripts/update.sh`
clobbers .o files with all build systems.
Review URL: https://chromiumcodereview.appspot.com/9378012
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@121503 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'tools/clang/scripts')
-rwxr-xr-x | tools/clang/scripts/update.sh | 18 |
1 files changed, 14 insertions, 4 deletions
diff --git a/tools/clang/scripts/update.sh b/tools/clang/scripts/update.sh index b8839ee..1296ac3 100755 --- a/tools/clang/scripts/update.sh +++ b/tools/clang/scripts/update.sh @@ -105,7 +105,8 @@ fi rm -f "${STAMP_FILE}" # Clobber pch files, since they only work with the compiler version that -# created them. +# created them. Also clobber .o files, to make sure everything will be built +# with the new compiler. if [[ "${OS}" = "Darwin" ]]; then XCODEBUILD_DIR="${THIS_DIR}/../../../xcodebuild" if [ -f "${THIS_DIR}/../../../WebKit.gyp" ]; then @@ -118,15 +119,19 @@ if [[ "${OS}" = "Darwin" ]]; then MAKE_DIR="${THIS_DIR}/../../../out" fi for CONFIG in Debug Release; do - if [[ -d "${MAKE_DIR}/${CONFIG}/obj.target" ]]; then - echo "Clobbering ${CONFIG} PCH files for make build" + if [[ -d "${MAKE_DIR}/${CONFIG}/obj.target" || + -d "${MAKE_DIR}/${CONFIG}/obj.host" ]]; then + echo "Clobbering ${CONFIG} PCH and .o files for make build" find "${MAKE_DIR}/${CONFIG}/obj.target" -name '*.gch' -exec rm {} + + find "${MAKE_DIR}/${CONFIG}/obj.host" -name '*.o' -exec rm {} + + find "${MAKE_DIR}/${CONFIG}/obj.target" -name '*.o' -exec rm {} + fi # ninja puts its output below ${MAKE_DIR} as well. if [[ -d "${MAKE_DIR}/${CONFIG}/obj" ]]; then - echo "Clobbering ${CONFIG} PCH files for ninja build" + echo "Clobbering ${CONFIG} PCH and .o files for ninja build" find "${MAKE_DIR}/${CONFIG}/obj" -name '*.gch' -exec rm {} + + find "${MAKE_DIR}/${CONFIG}/obj" -name '*.o' -exec rm {} + fi if [[ -d "${XCODEBUILD_DIR}/${CONFIG}/SharedPrecompiledHeaders" ]]; then @@ -134,6 +139,11 @@ if [[ "${OS}" = "Darwin" ]]; then rm -rf "${XCODEBUILD_DIR}/${CONFIG}/SharedPrecompiledHeaders" fi done + # Xcode groups .o files by project first, configuration second. + if [[ -d "${XCODEBUILD_DIR}" ]]; then + echo "Clobbering .o files for Xcode build" + find "${XCODEBUILD_DIR}" -name '*.o' -exec rm {} + + fi fi if [[ -z "$force_local_build" ]]; then |