mirror of
https://github.com/servo/servo.git
synced 2025-08-06 14:10:11 +01:00
style: Switch stylo function signature checking to use generated bindings.
Bug: 1451956 Reviewed-by: xidorn MozReview-Commit-ID: A7sWaD2PInN
This commit is contained in:
parent
593e4e4c9e
commit
76a14d6a64
1 changed files with 4 additions and 4 deletions
|
@ -11,8 +11,11 @@ use std::io::{BufRead, BufReader, Write};
|
||||||
use std::path::Path;
|
use std::path::Path;
|
||||||
|
|
||||||
fn main() {
|
fn main() {
|
||||||
|
// https://github.com/rust-lang/cargo/issues/3544
|
||||||
|
let style_out_dir = env::var_os("DEP_FOR SOME REASON THE LINKS KEY IS REQUIRED \
|
||||||
|
TO PASS DATA AROUND BETWEEN BUILD SCRIPTS_OUT_DIR").unwrap();
|
||||||
let root_path = Path::new("../../../");
|
let root_path = Path::new("../../../");
|
||||||
let bindings_file = root_path.join("components/style/gecko/generated/bindings.rs");
|
let bindings_file = Path::new(&style_out_dir).join("gecko/bindings.rs");
|
||||||
let glue_file = root_path.join("ports/geckolib/glue.rs");
|
let glue_file = root_path.join("ports/geckolib/glue.rs");
|
||||||
|
|
||||||
println!("cargo:rerun-if-changed=build.rs");
|
println!("cargo:rerun-if-changed=build.rs");
|
||||||
|
@ -70,9 +73,6 @@ fn main() {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// https://github.com/rust-lang/cargo/issues/3544
|
|
||||||
let style_out_dir = env::var_os("DEP_FOR SOME REASON THE LINKS KEY IS REQUIRED \
|
|
||||||
TO PASS DATA AROUND BETWEEN BUILD SCRIPTS_OUT_DIR").unwrap();
|
|
||||||
File::create(out_dir.join("bindings.rs"))
|
File::create(out_dir.join("bindings.rs"))
|
||||||
.unwrap()
|
.unwrap()
|
||||||
.write_all(format!("include!(concat!({:?}, \"/gecko/structs.rs\"));",
|
.write_all(format!("include!(concat!({:?}, \"/gecko/structs.rs\"));",
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue