|
@ -7,7 +7,10 @@ |
|
|
|
|
|
|
|
|
use cxx_build::CFG; |
|
|
use cxx_build::CFG; |
|
|
|
|
|
|
|
|
|
|
|
// TODO: assert version info
|
|
|
|
|
|
|
|
|
fn main() { |
|
|
fn main() { |
|
|
|
|
|
if std::env::var("DOCS_RS").is_err() { |
|
|
cmake::Config::new("klotski") |
|
|
cmake::Config::new("klotski") |
|
|
.define("CARGO_BUILD:BOOL", "ON") |
|
|
.define("CARGO_BUILD:BOOL", "ON") |
|
|
.define("KLSK_ENABLE_TESTING:BOOL", "OFF") |
|
|
.define("KLSK_ENABLE_TESTING:BOOL", "OFF") |
|
@ -26,6 +29,7 @@ fn main() { |
|
|
.flag("-fno-rtti") |
|
|
.flag("-fno-rtti") |
|
|
.flag("-fno-exceptions") |
|
|
.flag("-fno-exceptions") |
|
|
.compile("klotski"); |
|
|
.compile("klotski"); |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
println!("cargo:rerun-if-changed=src/bridge.rs"); |
|
|
println!("cargo:rerun-if-changed=src/bridge.rs"); |
|
|
println!("cargo:rerun-if-changed=adapter/short_code.cc"); |
|
|
println!("cargo:rerun-if-changed=adapter/short_code.cc"); |
|
|