Bug 1458897 Fix svn revert in build-clang so one can re-run it successfully r?glandium
svn revert requires a path, and does not take a revision. This isn't an
issue on build machines because we do a fresh checkout every time.
But if you're trying to run build-clang locally, with existing checkouts,
it will:
1) successfully svn update
2) run svn revert, saying "Skipped <rev>"
(except you don't see it because of -q)
3) svn revert returns a successfull eror code
4) patch fails because the file was never reverted and it attempts
to re-apply the patch
Also I think the revert command needs to come first.
MozReview-Commit-ID: 4OfrJNZwJNU
--- a/build/build-clang/build-clang.py
+++ b/build/build-clang/build-clang.py
@@ -134,18 +134,18 @@ def install_import_library(build_dir, cl
os.path.join(clang_dir, "lib"))
def svn_co(source_dir, url, directory, revision):
run_in(source_dir, ["svn", "co", "-q", "-r", revision, url, directory])
def svn_update(directory, revision):
+ run_in(directory, ["svn", "revert", "-q", "-R", "."])
run_in(directory, ["svn", "update", "-q", "-r", revision])
- run_in(directory, ["svn", "revert", "-q", "-R", revision])
def is_darwin():
return platform.system() == "Darwin"
def is_linux():
return platform.system() == "Linux"