Skip to content

Commit

Permalink
Add hint for missing web viewer when building re_web_viewer_server (#…
Browse files Browse the repository at this point in the history
  • Loading branch information
oxkitsune authored Jan 27, 2025
1 parent 06976a3 commit 6270501
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions crates/viewer/re_web_viewer_server/build.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,14 @@
use std::path::Path;

fn main() {
// https://blog.rust-lang.org/2024/05/06/check-cfg.html
println!("cargo::rustc-check-cfg=cfg(disable_web_viewer_server)");

let viewer_js_path = Path::new("./web_viewer/re_viewer.js");
let viewer_wasm_path = Path::new("./web_viewer/re_viewer_bg.wasm");

assert!(
viewer_js_path.exists() && viewer_wasm_path.exists(),
"Web viewer not found, run `pixi run rerun-build-web` to build it!"
);
}

0 comments on commit 6270501

Please sign in to comment.