mirror of
https://github.com/denoland/rusty_v8.git
synced 2024-12-25 00:29:14 -05:00
Move clang download to target/debug/clang (#210)
To prevent rebuilds due to the compiler being in random directories.
This commit is contained in:
parent
03cab59c5c
commit
9d24f58765
1 changed files with 10 additions and 1 deletions
11
build.rs
11
build.rs
|
@ -180,8 +180,17 @@ fn find_compatible_system_clang() -> Option<PathBuf> {
|
||||||
// modify the source directory.
|
// modify the source directory.
|
||||||
fn clang_download() -> PathBuf {
|
fn clang_download() -> PathBuf {
|
||||||
let root = env::current_dir().unwrap();
|
let root = env::current_dir().unwrap();
|
||||||
|
// target/debug//build/rusty_v8-d9e5a424d4f96994/out/
|
||||||
let out_dir = env::var_os("OUT_DIR").unwrap();
|
let out_dir = env::var_os("OUT_DIR").unwrap();
|
||||||
let clang_base_path = root.join(out_dir).join("clang");
|
let clang_base_path = root
|
||||||
|
.join(out_dir)
|
||||||
|
.parent()
|
||||||
|
.unwrap()
|
||||||
|
.parent()
|
||||||
|
.unwrap()
|
||||||
|
.parent()
|
||||||
|
.unwrap()
|
||||||
|
.join("clang");
|
||||||
println!("clang_base_path {}", clang_base_path.display());
|
println!("clang_base_path {}", clang_base_path.display());
|
||||||
let status = Command::new("python")
|
let status = Command::new("python")
|
||||||
.arg("./tools/clang/scripts/update.py")
|
.arg("./tools/clang/scripts/update.py")
|
||||||
|
|
Loading…
Reference in a new issue